public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Lukasz Kalamarz <lukasz.kalamarz@intel.com>
To: igt-dev@lists.freedesktop.org
Subject: [igt-dev] [PATCH i-g-t 5/6] lib/ tests/: drop usage of __gem_mmap__wc in code
Date: Wed,  9 Jan 2019 18:40:56 +0100	[thread overview]
Message-ID: <20190109174057.16835-5-lukasz.kalamarz@intel.com> (raw)
In-Reply-To: <20190109174057.16835-1-lukasz.kalamarz@intel.com>

With implementation of __gem_mmap we can drop __gem_mmap__wc
and instead use refactored function.

Signed-off-by: Lukasz Kalamarz <lukasz.kalamarz@intel.com>
Cc: Michal Winiarski <michal.winiarski@intel.com>
Cc: Katarzyna Dec <katarzyna.dec@intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
 lib/igt_dummyload.c           | 4 ++--
 tests/i915/gem_exec_big.c     | 2 +-
 tests/i915/gem_exec_gttfill.c | 4 ++--
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/lib/igt_dummyload.c b/lib/igt_dummyload.c
index 982906f2..00f39b94 100644
--- a/lib/igt_dummyload.c
+++ b/lib/igt_dummyload.c
@@ -114,8 +114,8 @@ emit_recursive_batch(igt_spin_t *spin,
 	memset(relocs, 0, sizeof(relocs));
 
 	obj[BATCH].handle = gem_create(fd, BATCH_SIZE);
-	batch = __gem_mmap__wc(fd, obj[BATCH].handle,
-			       0, BATCH_SIZE, PROT_WRITE);
+	batch = __gem_mmap(fd, obj[BATCH].handle, 0, BATCH_SIZE,
+		           PROT_WRITE, true);
 	if (!batch)
 		batch = gem_mmap__gtt(fd, obj[BATCH].handle,
 				       	BATCH_SIZE, PROT_WRITE);
diff --git a/tests/i915/gem_exec_big.c b/tests/i915/gem_exec_big.c
index b57560af..15b1021d 100644
--- a/tests/i915/gem_exec_big.c
+++ b/tests/i915/gem_exec_big.c
@@ -222,7 +222,7 @@ igt_simple_main
 		if (!FORCE_PREAD_PWRITE && gem_has_llc(fd))
 			ptr = __gem_mmap(fd, handle, 0, batch_size, PROT_READ, false);
 		else if (!FORCE_PREAD_PWRITE && gem_mmap__has_wc(fd))
-			ptr = __gem_mmap__wc(fd, handle, 0, batch_size, PROT_READ);
+			ptr = __gem_mmap(fd, handle, 0, batch_size, PROT_READ, true);
 		else
 			ptr = NULL;
 
diff --git a/tests/i915/gem_exec_gttfill.c b/tests/i915/gem_exec_gttfill.c
index efd612bb..c39d2d15 100644
--- a/tests/i915/gem_exec_gttfill.c
+++ b/tests/i915/gem_exec_gttfill.c
@@ -157,8 +157,8 @@ static void fillgtt(int fd, unsigned ring, int timeout)
 	for (unsigned i = 0; i < count; i++) {
 		batches[i].handle = gem_create(fd, BATCH_SIZE);
 		batches[i].ptr =
-			__gem_mmap__wc(fd, batches[i].handle,
-				       0, BATCH_SIZE, PROT_WRITE);
+			__gem_mmap(fd, batches[i].handle,0, BATCH_SIZE,
+				   PROT_WRITE, true);
 		if (!batches[i].ptr) {
 			batches[i].ptr =
 				__gem_mmap__gtt(fd, batches[i].handle,
-- 
2.17.2

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  parent reply	other threads:[~2019-01-09 17:44 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-09 17:40 [igt-dev] [PATCH i-g-t 1/6] lib/ioctl_wrapper: use defines for get_param instead of param number Lukasz Kalamarz
2019-01-09 17:40 ` [igt-dev] [PATCH i-g-t 2/6] lib/ioctl_wrapper: Implement __gem_mmap Lukasz Kalamarz
2019-01-09 18:04   ` Daniele Ceraolo Spurio
2019-01-09 20:40   ` Chris Wilson
2019-01-09 17:40 ` [igt-dev] [PATCH i-g-t 3/6] lib/igt_dummyload: use gem_mmap__cpu and gem_mmap__wc when applicable Lukasz Kalamarz
2019-01-09 17:40 ` [igt-dev] [PATCH i-g-t 4/6] benchmarks/ tests/i915/: drop usage of __gem_mmap__cpu in code Lukasz Kalamarz
2019-01-09 18:57   ` Daniele Ceraolo Spurio
2019-01-09 20:45   ` Chris Wilson
2019-01-09 17:40 ` Lukasz Kalamarz [this message]
2019-01-09 17:40 ` [igt-dev] [PATCH i-g-t 6/6] lib/ioctl_wrapper: remove __gem_mmap__cpu and __gem_mmap__wc Lukasz Kalamarz
2019-01-09 18:14 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/6] lib/ioctl_wrapper: use defines for get_param instead of param number Patchwork
2019-01-09 19:01 ` [igt-dev] ✓ Fi.CI.IGT: " 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=20190109174057.16835-5-lukasz.kalamarz@intel.com \
    --to=lukasz.kalamarz@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    /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