[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230113211135.2530064-5-cristian.marussi@arm.com>
Date: Fri, 13 Jan 2023 21:11:22 +0000
From: Cristian Marussi <cristian.marussi@....com>
To: linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org
Cc: sudeep.holla@....com, james.quinlan@...adcom.com,
Jonathan.Cameron@...wei.com, f.fainelli@...il.com,
etienne.carriere@...aro.org, vincent.guittot@...aro.org,
souvik.chakravarty@....com, wleavitt@...vell.com,
peter.hilber@...nsynergy.com, nicola.mazzucato@....com,
tarek.el-sherbiny@....com, quic_kshivnan@...cinc.com,
cristian.marussi@....com
Subject: [PATCH v7 04/17] firmware: arm_scmi: Add flags field to xfer
Add a flags field to xfer and define a flagbit and related macro to easily
identify xfers originated from Raw transmissions.
Signed-off-by: Cristian Marussi <cristian.marussi@....com>
---
v5 --> v6
- convert is_raw boolean to a bitflag
---
drivers/firmware/arm_scmi/protocols.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/firmware/arm_scmi/protocols.h b/drivers/firmware/arm_scmi/protocols.h
index 2f3bf691db7c..b5941beb8b03 100644
--- a/drivers/firmware/arm_scmi/protocols.h
+++ b/drivers/firmware/arm_scmi/protocols.h
@@ -115,6 +115,7 @@ struct scmi_msg_hdr {
* - SCMI_XFER_SENT_OK -> SCMI_XFER_RESP_OK [ -> SCMI_XFER_DRESP_OK ]
* - SCMI_XFER_SENT_OK -> SCMI_XFER_DRESP_OK
* (Missing synchronous response is assumed OK and ignored)
+ * @flags: Optional flags associated to this xfer.
* @lock: A spinlock to protect state and busy fields.
* @priv: A pointer for transport private usage.
*/
@@ -135,6 +136,9 @@ struct scmi_xfer {
#define SCMI_XFER_RESP_OK 1
#define SCMI_XFER_DRESP_OK 2
int state;
+#define SCMI_XFER_FLAG_IS_RAW BIT(0)
+#define SCMI_XFER_IS_RAW(x) ((x)->flags & SCMI_XFER_FLAG_IS_RAW)
+ int flags;
/* A lock to protect state and busy fields */
spinlock_t lock;
void *priv;
--
2.34.1
Powered by blists - more mailing lists