From: Bommu Krishnaiah <krishnaiah.bommu@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Bommu Krishnaiah <krishnaiah.bommu@intel.com>,
Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Subject: [igt-dev] [PATCH i-g-t 1/1] lib/i915/gem_ring : set the engine to default context
Date: Mon, 17 Feb 2020 11:20:19 +0530 [thread overview]
Message-ID: <20200217055019.32591-2-krishnaiah.bommu@intel.com> (raw)
In-Reply-To: <20200217055019.32591-1-krishnaiah.bommu@intel.com>
Copy the existing engine map from default context to
newly created default context
Signed-off-by: Bommu Krishnaiah <krishnaiah.bommu@intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
lib/i915/gem_ring.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/lib/i915/gem_ring.c b/lib/i915/gem_ring.c
index 99f4741c..c2eae836 100644
--- a/lib/i915/gem_ring.c
+++ b/lib/i915/gem_ring.c
@@ -143,11 +143,13 @@ __gem_measure_ring_inflight(int fd, unsigned int engine, enum measure_ring_flags
* Number of batches that fit in the ring
*/
unsigned int
-gem_measure_ring_inflight(int fd, unsigned int engine, enum measure_ring_flags flags)
+gem_measure_ring_inflight(int sfd, unsigned int engine, enum measure_ring_flags flags)
{
unsigned int min = ~0u;
+ uint32_t fd;
- fd = gem_reopen_driver(fd);
+ fd = gem_reopen_driver(sfd);
+ gem_context_copy_engines(sfd, 0, fd, 0);
/* When available, disable execbuf throttling */
fcntl(fd, F_SETFD, fcntl(fd, F_GETFD) | O_NONBLOCK);
--
2.25.0.4.g0ad7144999
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
next prev parent reply other threads:[~2020-02-17 6:07 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-17 5:50 [igt-dev] [PATCH i-g-t 0/1] lib/i915/gem_ring : set the engine to default context Bommu Krishnaiah
2020-02-17 5:50 ` Bommu Krishnaiah [this message]
2020-02-17 11:12 ` [igt-dev] [PATCH i-g-t 1/1] " Chris Wilson
2020-02-17 14:12 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200217055019.32591-2-krishnaiah.bommu@intel.com \
--to=krishnaiah.bommu@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=tvrtko.ursulin@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox