From: Guru Das Srinagesh <quic_gurus@quicinc.com>
To: Kathiravan T <quic_kathirav@quicinc.com>
Cc: Trilok Soni <quic_tsoni@quicinc.com>,
Andy Gross <agross@kernel.org>,
Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konrad.dybcio@linaro.org>,
Linus Walleij <linus.walleij@linaro.org>,
"Elliot Berman" <quic_eberman@quicinc.com>,
Mukesh Ojha <quic_mojha@quicinc.com>,
Kalle Valo <kvalo@kernel.org>,
Loic Poulain <loic.poulain@linaro.org>,
<linux-arm-msm@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<linux-gpio@vger.kernel.org>, <quic_srichara@quicinc.com>,
<quic_sjaganat@quicinc.com>, <quic_anusha@quicinc.com>,
<quic_saahtoma@quicinc.com>,
Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Subject: Re: [PATCH V5 1/3] firmware: qcom_scm: provide a read-modify-write function
Date: Fri, 28 Jul 2023 17:34:40 -0700 [thread overview]
Message-ID: <20230729003440.GB25463@quicinc.com> (raw)
In-Reply-To: <3ab86e8d-cc00-d0bb-20f8-4c75c90a7db8@quicinc.com>
On Jul 23 2023 19:25, Kathiravan T wrote:
>
> On 7/22/2023 6:47 AM, Trilok Soni wrote:
> >On 7/20/2023 12:04 AM, Kathiravan T wrote:
> >>From: Mukesh Ojha <quic_mojha@quicinc.com>
> >>
> >>It was realized by Srinivas K. that there is a need of read-modify-write
> >>scm exported function so that it can be used by multiple clients.
> >>
> >>Let's introduce qcom_scm_io_update_field() which masks out the bits and
> >>write the passed value to that bit-offset.
> >>
> >>Suggested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
> >>Signed-off-by: Mukesh Ojha <quic_mojha@quicinc.com>
> >>Signed-off-by: Kathiravan T <quic_kathirav@quicinc.com>
> >>---
> >>Changes in V5:
> >> - No changes
> >>
> >> drivers/firmware/qcom_scm.c | 15 +++++++++++++++
> >> include/linux/firmware/qcom/qcom_scm.h | 2 ++
> >> 2 files changed, 17 insertions(+)
> >>
> >>diff --git a/drivers/firmware/qcom_scm.c b/drivers/firmware/qcom_scm.c
> >>index fde33acd46b7..104d86e49b97 100644
> >>--- a/drivers/firmware/qcom_scm.c
> >>+++ b/drivers/firmware/qcom_scm.c
> >>@@ -407,6 +407,21 @@ int qcom_scm_set_remote_state(u32 state, u32 id)
> >> }
> >> EXPORT_SYMBOL(qcom_scm_set_remote_state);
> >> +int qcom_scm_io_update_field(phys_addr_t addr, unsigned int mask,
> >>unsigned int val)
> >>+{
> >>+ unsigned int old, new;
> >>+ int ret;
> >>+
> >>+ ret = qcom_scm_io_readl(addr, &old);
> >>+ if (ret)
> >>+ return ret;
> >>+
> >>+ new = (old & ~mask) | (val & mask);
> >>+
> >>+ return qcom_scm_io_writel(addr, new);
> >>+}
> >>+EXPORT_SYMBOL(qcom_scm_io_update_field);
> >
> >EXPORT_SYMBO_GPL please.
>
>
> Sure, is it okay if I send the patch to convert the existing EXPORT_SYMBOL
> to EXPORT_SYMBOL_GPL as well?
This is done already [1].
[1] https://lore.kernel.org/lkml/19d9ac0bf79f957574ef9b3b73246ea0113cc0fd.1690503893.git.quic_gurus@quicinc.com/
next prev parent reply other threads:[~2023-07-29 0:34 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-20 7:04 [PATCH V5 0/3] Introduce the read-modify-write API to collect Kathiravan T
2023-07-20 7:04 ` [PATCH V5 1/3] firmware: qcom_scm: provide a read-modify-write function Kathiravan T
2023-07-22 1:17 ` Trilok Soni
2023-07-23 13:55 ` Kathiravan T
2023-07-29 0:34 ` Guru Das Srinagesh [this message]
2023-07-24 19:05 ` Elliot Berman
2023-07-20 7:04 ` [PATCH V5 2/3] pinctrl: qcom: Use qcom_scm_io_update_field() Kathiravan T
2023-07-22 3:09 ` Bjorn Andersson
2023-07-23 13:48 ` Kathiravan T
2023-07-20 7:04 ` [PATCH V5 3/3] firmware: scm: Modify only the download bits in TCSR register Kathiravan T
2023-07-21 23:15 ` kernel test robot
2023-07-24 19:05 ` Elliot Berman
2023-07-25 10:24 ` Kathiravan T
2023-07-20 7:08 ` [PATCH V5 0/3] Introduce the read-modify-write API to collect Kathiravan T
2023-07-24 19:05 ` Elliot Berman
2023-07-25 9:55 ` Kathiravan T
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=20230729003440.GB25463@quicinc.com \
--to=quic_gurus@quicinc.com \
--cc=agross@kernel.org \
--cc=andersson@kernel.org \
--cc=konrad.dybcio@linaro.org \
--cc=kvalo@kernel.org \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=loic.poulain@linaro.org \
--cc=quic_anusha@quicinc.com \
--cc=quic_eberman@quicinc.com \
--cc=quic_kathirav@quicinc.com \
--cc=quic_mojha@quicinc.com \
--cc=quic_saahtoma@quicinc.com \
--cc=quic_sjaganat@quicinc.com \
--cc=quic_srichara@quicinc.com \
--cc=quic_tsoni@quicinc.com \
--cc=srinivas.kandagatla@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