Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Dhruva Gole <d-gole@ti.com>
To: Jonathan Cameron <jonathan.cameron@huawei.com>
Cc: Cristian Marussi <cristian.marussi@arm.com>,
	<linux-kernel@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<arm-scmi@vger.kernel.org>, <linux-fsdevel@vger.kernel.org>,
	<sudeep.holla@arm.com>, <james.quinlan@broadcom.com>,
	<f.fainelli@gmail.com>, <vincent.guittot@linaro.org>,
	<etienne.carriere@st.com>, <peng.fan@oss.nxp.com>,
	<michal.simek@amd.com>, <dan.carpenter@linaro.org>,
	<elif.topuz@arm.com>, <lukasz.luba@arm.com>,
	<philip.radford@arm.com>, <souvik.chakravarty@arm.com>
Subject: Re: [PATCH v2 01/17] firmware: arm_scmi: Define a common SCMI_MAX_PROTOCOLS value
Date: Tue, 20 Jan 2026 12:14:19 +0530	[thread overview]
Message-ID: <20260120064419.by4nvmdgdybwe76q@lcpd911> (raw)
In-Reply-To: <20260119111827.00001704@huawei.com>

On Jan 19, 2026 at 11:18:27 +0000, Jonathan Cameron wrote:
> On Wed, 14 Jan 2026 11:46:05 +0000
> Cristian Marussi <cristian.marussi@arm.com> wrote:
> 
> > Add a common definition of SCMI_MAX_PROTOCOLS and use it all over the
> > SCMI stack.
> > 
> > Signed-off-by: Cristian Marussi <cristian.marussi@arm.com>
> Hi Cristian,
> 
> Mention the introduction of SCMI_PROTOCOL_LAST in the patch description
> and probably say why it takes that value (which is much less than
> the SCMI_MAX_PROTOCOLS value).

Rather I wonder why even add it? Is it just like a documentation/ marker
or is some other usage even planned for it?

> 
> Jonathan
> 
> > ---
> >  drivers/firmware/arm_scmi/notify.c | 4 +---
> >  include/linux/scmi_protocol.h      | 3 +++
> >  2 files changed, 4 insertions(+), 3 deletions(-)
> > 
> > diff --git a/drivers/firmware/arm_scmi/notify.c b/drivers/firmware/arm_scmi/notify.c
> > index dee9f238f6fd..78e9e27dc9ec 100644
> > --- a/drivers/firmware/arm_scmi/notify.c
> > +++ b/drivers/firmware/arm_scmi/notify.c
> > @@ -94,8 +94,6 @@
> >  #include "common.h"
> >  #include "notify.h"
> >  
> > -#define SCMI_MAX_PROTO		256
> > -
> >  #define PROTO_ID_MASK		GENMASK(31, 24)
> >  #define EVT_ID_MASK		GENMASK(23, 16)
> >  #define SRC_ID_MASK		GENMASK(15, 0)
> > @@ -1673,7 +1671,7 @@ int scmi_notification_init(struct scmi_handle *handle)
> >  	ni->gid = gid;
> >  	ni->handle = handle;
> >  
> > -	ni->registered_protocols = devm_kcalloc(handle->dev, SCMI_MAX_PROTO,
> > +	ni->registered_protocols = devm_kcalloc(handle->dev, SCMI_MAX_PROTOCOLS,
> >  						sizeof(char *), GFP_KERNEL);
> >  	if (!ni->registered_protocols)
> >  		goto err;
> > diff --git a/include/linux/scmi_protocol.h b/include/linux/scmi_protocol.h
> > index aafaac1496b0..c6efe4f371ac 100644
> > --- a/include/linux/scmi_protocol.h
> > +++ b/include/linux/scmi_protocol.h
> > @@ -926,8 +926,11 @@ enum scmi_std_protocol {
> >  	SCMI_PROTOCOL_VOLTAGE = 0x17,
> >  	SCMI_PROTOCOL_POWERCAP = 0x18,
> >  	SCMI_PROTOCOL_PINCTRL = 0x19,
> > +	SCMI_PROTOCOL_LAST = 0x7f,
> >  };
> >  
> > +#define SCMI_MAX_PROTOCOLS	256
> > +
> >  enum scmi_system_events {
> >  	SCMI_SYSTEM_SHUTDOWN,
> >  	SCMI_SYSTEM_COLDRESET,
> 

-- 
Best regards,
Dhruva Gole
Texas Instruments Incorporated


  parent reply	other threads:[~2026-01-20  6:44 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-14 11:46 [PATCH v2 00/17] Introduce SCMI Telemetry FS support Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 01/17] firmware: arm_scmi: Define a common SCMI_MAX_PROTOCOLS value Cristian Marussi
2026-01-19 11:18   ` Jonathan Cameron
2026-01-19 15:43     ` Cristian Marussi
2026-01-20  6:44     ` Dhruva Gole [this message]
2026-01-20 10:55       ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 02/17] firmware: arm_scmi: Reduce the scope of protocols mutex Cristian Marussi
2026-01-19 11:21   ` Jonathan Cameron
2026-01-19 15:45     ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 03/17] firmware: arm_scmi: Allow protocols to register for notifications Cristian Marussi
2026-01-19 11:33   ` Jonathan Cameron
2026-01-19 15:49     ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 04/17] uapi: Add ARM SCMI definitions Cristian Marussi
2026-01-19 11:43   ` Jonathan Cameron
2026-01-19 15:51     ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 05/17] firmware: arm_scmi: Add Telemetry protocol support Cristian Marussi
2026-01-19 16:29   ` Jonathan Cameron
2026-01-19 18:25     ` Cristian Marussi
2026-01-23 11:00   ` Elif Topuz
2026-03-26 13:32     ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 06/17] include: trace: Add Telemetry trace events Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 07/17] firmware: arm_scmi: Use new Telemetry traces Cristian Marussi
2026-01-23 11:43   ` Elif Topuz
2026-03-26 15:35     ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 08/17] firmware: arm_scmi: Add System Telemetry driver Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 09/17] fs/stlmfs: Document ARM SCMI Telemetry filesystem Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 10/17] firmware: arm_scmi: Add System Telemetry ioctls support Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 11/17] fs/stlmfs: Document alternative ioctl based binary interface Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 12/17] firmware: arm_scmi: Add Telemetry components view Cristian Marussi
2026-01-16 13:35   ` Elif Topuz
2026-01-19 15:42     ` Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 13/17] fs/stlmfs: Document alternative topological view Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 14/17] [RFC] docs: stlmfs: Document ARM SCMI Telemetry FS ABI Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 15/17] [RFC] firmware: arm_scmi: Add lazy population support to Telemetry FS Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 16/17] fs/stlmfs: Document lazy mode and related mount option Cristian Marussi
2026-01-14 11:46 ` [PATCH v2 17/17] [RFC] tools/scmi: Add SCMI Telemetry testing tool Cristian Marussi

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=20260120064419.by4nvmdgdybwe76q@lcpd911 \
    --to=d-gole@ti.com \
    --cc=arm-scmi@vger.kernel.org \
    --cc=cristian.marussi@arm.com \
    --cc=dan.carpenter@linaro.org \
    --cc=elif.topuz@arm.com \
    --cc=etienne.carriere@st.com \
    --cc=f.fainelli@gmail.com \
    --cc=james.quinlan@broadcom.com \
    --cc=jonathan.cameron@huawei.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lukasz.luba@arm.com \
    --cc=michal.simek@amd.com \
    --cc=peng.fan@oss.nxp.com \
    --cc=philip.radford@arm.com \
    --cc=souvik.chakravarty@arm.com \
    --cc=sudeep.holla@arm.com \
    --cc=vincent.guittot@linaro.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