All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Wajdeczko <michal.wajdeczko@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH v4 18/22] drm/i915/guc: Update GuC CTB response definition
Date: Thu, 23 May 2019 23:30:45 +0000	[thread overview]
Message-ID: <20190523233049.28020-19-michal.wajdeczko@intel.com> (raw)
In-Reply-To: <20190523233049.28020-1-michal.wajdeczko@intel.com>

Current GuC firmwares identify response message in a different way.

v2: update comments for other H2G bits (Daniele)

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Kelvin Gardiner <kelvin.gardiner@intel.com>
Cc: John Spotswood <john.a.spotswood@intel.com>
Reviewed-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
 drivers/gpu/drm/i915/intel_guc_ct.c   | 2 +-
 drivers/gpu/drm/i915/intel_guc_fwif.h | 8 +++++---
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_guc_ct.c b/drivers/gpu/drm/i915/intel_guc_ct.c
index dde1dc0d6e69..2d5dc2aa22a7 100644
--- a/drivers/gpu/drm/i915/intel_guc_ct.c
+++ b/drivers/gpu/drm/i915/intel_guc_ct.c
@@ -565,7 +565,7 @@ static inline unsigned int ct_header_get_action(u32 header)
 
 static inline bool ct_header_is_response(u32 header)
 {
-	return ct_header_get_action(header) == INTEL_GUC_ACTION_DEFAULT;
+	return !!(header & GUC_CT_MSG_IS_RESPONSE);
 }
 
 static int ctb_read(struct intel_guc_ct_buffer *ctb, u32 *data)
diff --git a/drivers/gpu/drm/i915/intel_guc_fwif.h b/drivers/gpu/drm/i915/intel_guc_fwif.h
index fa745a58d38d..3d1de288d96c 100644
--- a/drivers/gpu/drm/i915/intel_guc_fwif.h
+++ b/drivers/gpu/drm/i915/intel_guc_fwif.h
@@ -355,14 +355,16 @@ struct guc_ct_buffer_desc {
  *
  * bit[4..0]	message len (in dwords)
  * bit[7..5]	reserved
- * bit[8]	write fence to desc
- * bit[9]	write status to H2G buff
- * bit[10]	send status (via G2H)
+ * bit[8]	response (G2H only)
+ * bit[8]	write fence to desc (H2G only)
+ * bit[9]	write status to H2G buff (H2G only)
+ * bit[10]	send status back via G2H (H2G only)
  * bit[15..11]	reserved
  * bit[31..16]	action code
  */
 #define GUC_CT_MSG_LEN_SHIFT			0
 #define GUC_CT_MSG_LEN_MASK			0x1F
+#define GUC_CT_MSG_IS_RESPONSE			(1 << 8)
 #define GUC_CT_MSG_WRITE_FENCE_TO_DESC		(1 << 8)
 #define GUC_CT_MSG_WRITE_STATUS_TO_BUFF		(1 << 9)
 #define GUC_CT_MSG_SEND_STATUS			(1 << 10)
-- 
2.19.2

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2019-05-23 23:31 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-23 23:30 [PATCH v4 00/22] GuC 32.0.3 Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 01/22] drm/i915/guc: Change platform default GuC mode Michal Wajdeczko
2019-05-27 11:36   ` Joonas Lahtinen
2019-05-23 23:30 ` [PATCH v4 02/22] drm/i915/guc: Don't allow GuC submission Michal Wajdeczko
2019-05-27 11:40   ` Joonas Lahtinen
2019-05-27 11:59     ` Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 03/22] drm/i915/guc: Update GuC firmware versions and names Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 04/22] drm/i915/guc: Update GuC firmware CSS header Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 05/22] drm/i915/guc: Update GuC boot parameters Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 06/22] drm/i915/guc: Update suspend/resume protocol Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 07/22] drm/i915/guc: Update GuC sample-forcewake command Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 08/22] drm/i915/guc: Update GuC ADS object definition Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 09/22] drm/i915/guc: Reset GuC ADS during sanitize Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 10/22] drm/i915/guc: Always ask GuC to update power domain states Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 11/22] drm/i915/guc: Define GuC firmware version for Geminilake Michal Wajdeczko
2019-05-24 17:36   ` Srivatsa, Anusha
2019-05-23 23:30 ` [PATCH v4 12/22] drm/i915/huc: Define HuC " Michal Wajdeczko
2019-05-24 17:39   ` Srivatsa, Anusha
2019-05-23 23:30 ` [PATCH v4 13/22] drm/i915/guc: New GuC interrupt register for Gen11 Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 14/22] drm/i915/guc: New GuC scratch registers " Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 15/22] drm/i915/huc: New HuC status register " Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 16/22] drm/i915/guc: Create vfuncs for the GuC interrupts control functions Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 17/22] drm/i915/guc: Correctly handle GuC interrupts on Gen11 Michal Wajdeczko
2019-05-27 14:30   ` Michał Winiarski
2019-05-23 23:30 ` Michal Wajdeczko [this message]
2019-05-23 23:30 ` [PATCH v4 19/22] drm/i915/guc: Enable GuC CTB communication " Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 20/22] drm/i915/guc: Define GuC firmware version for Icelake Michal Wajdeczko
2019-05-23 23:30 ` [PATCH v4 21/22] drm/i915/huc: Define HuC " Michal Wajdeczko
2019-05-25  0:58   ` Ye, Tony
2019-05-23 23:30 ` [PATCH v4 22/22] HAX: turn on GuC/HuC auto mode Michal Wajdeczko
2019-05-23 23:51 ` ✗ Fi.CI.CHECKPATCH: warning for GuC 32.0.3 (rev5) Patchwork
2019-05-24  0:09 ` ✓ Fi.CI.BAT: success " Patchwork
2019-05-25 10:39 ` ✗ Fi.CI.IGT: failure " Patchwork
2019-05-25 11:47   ` Michal Wajdeczko

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=20190523233049.28020-19-michal.wajdeczko@intel.com \
    --to=michal.wajdeczko@intel.com \
    --cc=intel-gfx@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.