All of lore.kernel.org
 help / color / mirror / Atom feed
From: Katarzyna Dec <katarzyna.dec@intel.com>
To: igt-dev@lists.freedesktop.org
Subject: [igt-dev] [PATCH i-g-t 2/4] lib/media_fill: Add media_fillfunc for Gen10
Date: Wed,  9 May 2018 15:03:17 +0200	[thread overview]
Message-ID: <20180509130319.19710-3-katarzyna.dec@intel.com> (raw)
In-Reply-To: <20180509130319.19710-1-katarzyna.dec@intel.com>

Gen10 media_fillfunc so far was the same as for gen9.
Let's add proper gen10 function to make this code more
clear. There are no changes in gen10 code.

Signed-off-by: Katarzyna Dec <katarzyna.dec@intel.com>
Cc: Ewelina Musial <ewelina.musial@intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Antonio Argenziano <antonio.argenziano@intel.com>
---
 lib/intel_batchbuffer.c |  4 +++-
 lib/media_fill.c        | 12 ++++++++++++
 lib/media_fill.h        |  6 ++++++
 3 files changed, 21 insertions(+), 1 deletion(-)

diff --git a/lib/intel_batchbuffer.c b/lib/intel_batchbuffer.c
index f87e6bed..42ec4f35 100644
--- a/lib/intel_batchbuffer.c
+++ b/lib/intel_batchbuffer.c
@@ -858,7 +858,9 @@ igt_fillfunc_t igt_get_media_fillfunc(int devid)
 {
 	igt_fillfunc_t fill = NULL;
 
-	if (IS_GEN9(devid) || IS_GEN10(devid))
+	if (IS_GEN10(devid))
+		fill = gen10_media_fillfunc;
+	else if (IS_GEN9(devid))
 		fill = gen9_media_fillfunc;
 	else if (IS_GEN8(devid))
 		fill = gen8_media_fillfunc;
diff --git a/lib/media_fill.c b/lib/media_fill.c
index 44c892bc..67ee38d5 100644
--- a/lib/media_fill.c
+++ b/lib/media_fill.c
@@ -225,3 +225,15 @@ gen9_media_fillfunc(struct intel_batchbuffer *batch,
 	__gen9_media_fillfunc(batch, dst, x, y, width, height, color,
 			      gen9_media_kernel, sizeof(gen9_media_kernel));
 }
+
+void
+gen10_media_fillfunc(struct intel_batchbuffer *batch,
+		struct igt_buf *dst,
+		unsigned int x, unsigned int y,
+		unsigned int width, unsigned int height,
+		uint8_t color)
+{
+
+	__gen9_media_fillfunc(batch, dst, x, y, width, height, color,
+			      gen9_media_kernel, sizeof(gen9_media_kernel));
+}
diff --git a/lib/media_fill.h b/lib/media_fill.h
index 7ddccb1b..c93bcc37 100644
--- a/lib/media_fill.h
+++ b/lib/media_fill.h
@@ -32,5 +32,11 @@ gen9_media_fillfunc(struct intel_batchbuffer *batch,
 		unsigned int x, unsigned int y,
 		unsigned int width, unsigned int height,
 		uint8_t color);
+void
+gen10_media_fillfunc(struct intel_batchbuffer *batch,
+		struct igt_buf *dst,
+		unsigned int x, unsigned int y,
+		unsigned int width, unsigned int height,
+		uint8_t color);
 
 #endif /* RENDE_MEDIA_FILL_H */
-- 
2.14.3

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

  parent reply	other threads:[~2018-05-09 13:03 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-09 13:03 [igt-dev] [PATCH i-g-t 0/4] *_fill libraries refactoring part2 Katarzyna Dec
2018-05-09 13:03 ` [igt-dev] [PATCH i-g-t 1/4] lib/media_fill: Create common media_fill library for all gens Katarzyna Dec
2018-05-09 13:03 ` Katarzyna Dec [this message]
2018-05-09 13:37   ` [igt-dev] [PATCH i-g-t v2 2/4] lib/media_fill: Add media_fillfunc for Gen10 Katarzyna Dec
2018-05-09 13:03 ` [igt-dev] [PATCH i-g-t 3/4] lib/gpgpu_fill: Create generic __gen9_gpgpu_fillfunc Katarzyna Dec
2018-05-09 13:03 ` [igt-dev] [PATCH i-g-t 4/4] lib/gpgpu_fill: Add gpgpu_fillfunc for Gen10 Katarzyna Dec
2018-05-09 13:15   ` Ewelina Musial
2018-05-09 13:36   ` [igt-dev] [PATCH i-g-t v2 " Katarzyna Dec
2018-05-09 13:45 ` [igt-dev] ✓ Fi.CI.BAT: success for *_fill libraries refactoring part2 Patchwork
2018-05-09 14:07 ` [igt-dev] ✓ Fi.CI.BAT: success for *_fill libraries refactoring part2 (rev3) Patchwork
2018-05-09 15:08 ` [igt-dev] ✓ Fi.CI.IGT: success for *_fill libraries refactoring part2 Patchwork
2018-05-09 15:49 ` [igt-dev] ✓ Fi.CI.IGT: success for *_fill libraries refactoring part2 (rev3) 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=20180509130319.19710-3-katarzyna.dec@intel.com \
    --to=katarzyna.dec@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.