From: Mark Rutland <mark.rutland@arm.com>
To: Kumar Gala <galak@codeaurora.org>
Cc: "linux-arm-msm@vger.kernel.org" <linux-arm-msm@vger.kernel.org>,
Lina Iyer <lina.iyer@linaro.org>,
"arm@kernel.org" <arm@kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
Catalin Marinas <Catalin.Marinas@arm.com>,
Lorenzo Pieralisi <Lorenzo.Pieralisi@arm.com>
Subject: Re: [PATCH v5 2/2] firmware: qcom: scm: Add support for ARM64 SoCs
Date: Wed, 29 Apr 2015 17:38:08 +0100 [thread overview]
Message-ID: <20150429163808.GE8781@leverpostej> (raw)
In-Reply-To: <CF235ECE-3429-48D3-BEF9-85204E6DBD98@codeaurora.org>
On Wed, Apr 29, 2015 at 05:18:04PM +0100, Kumar Gala wrote:
>
> > On Apr 29, 2015, at 10:42 AM, Mark Rutland <mark.rutland@arm.com> wrote:
> >
> > Hi Kumar,
> >
> > On Tue, Apr 28, 2015 at 08:23:58PM +0100, Kumar Gala wrote:
> >> Add an implementation of the SCM interface that works on ARM64/64-bit SoCs
> >
> > What is the intended use of this on arm64 SoCs?
> >
> > Given the negative reaction to the SMP bringup [1] code that seems to be
> > the only user, I'm somewhat confused as to why this is being pushed as a
> > non-RFC in the mean time.
> >
> > Are there other users of this interface code? If so, could you please
> > mention that in the commit message. I'd also ask that you would Cc me on
> > future postings of this series.
> >
> > […]
>
> The SCM interface is needed for other things like display:
>
> https://patchwork.kernel.org/patch/6198691/
Thanks for the link. It would be good if you could mention some users in
the commit message.
> >> +static int qcom_scm_set_boot_addr(void *entry, const cpumask_t *cpus, int flags)
> >> +{
> >> + struct qcom_scm_desc desc = {0};
> >> + unsigned int cpu = cpumask_first(cpus);
> >> + u64 mpidr_el1 = cpu_logical_map(cpu);
> >> +
> >> + /* For now we assume only a single cpu is set in the mask */
> >> + WARN_ON(cpumask_weight(cpus) != 1);
> >> +
> >> + if (mpidr_el1 & ~MPIDR_HWID_BITMASK) {
> >> + pr_err("CPU%d:Failed to set boot address\n", cpu);
> >> + return -ENOSYS;
> >> + }
> >> +
> >> + desc.args[0] = virt_to_phys(entry);
> >> + desc.args[1] = BIT(MPIDR_AFFINITY_LEVEL(mpidr_el1, 0));
> >> + desc.args[2] = BIT(MPIDR_AFFINITY_LEVEL(mpidr_el1, 1));
> >> + desc.args[3] = BIT(MPIDR_AFFINITY_LEVEL(mpidr_el1, 2));
> >> + desc.args[4] = ~0ULL;
> >> + desc.args[5] = QCOM_SCM_FLAG_HLOS | flags;
> >> + desc.arginfo = QCOM_SCM_ARGS(6);
> >> +
> >> + return qcom_scm_call(QCOM_SCM_SVC_BOOT, QCOM_SCM_BOOT_ADDR_MC, &desc);
> >> +}
> >> +
> >> +int __qcom_scm_set_cold_boot_addr(void *entry, const cpumask_t *cpus)
> >> +{
> >> + int flags = QCOM_SCM_FLAG_COLDBOOT_MC;
> >> +
> >> + return qcom_scm_set_boot_addr(entry, cpus, flags);
> >> +}
> >> +
> >> +int __qcom_scm_set_warm_boot_addr(void *entry, const cpumask_t *cpus)
> >> +{
> >> + int flags = QCOM_SCM_FLAG_WARMBOOT_MC;
> >> +
> >> + return qcom_scm_set_boot_addr(entry, cpus, flags);
> >> +}
> >> +
> >> +void __qcom_scm_cpu_power_down(u32 flags)
> >> +{
> >> + struct qcom_scm_desc desc = {0};
> >> + desc.args[0] = flags & QCOM_SCM_FLUSH_FLAG_MASK;
> >> + desc.arginfo = QCOM_SCM_ARGS(1);
> >> +
> >> + qcom_scm_call_atomic(QCOM_SCM_SVC_BOOT, QCOM_SCM_CMD_TERMINATE_PC, &desc);
> >> +}
> >
> > As mentioned in the other thread, I don't want to see this for arm64,
> > and must NAK this portion.
>
> I can have these return an error code, but we want to keep the interface the same between the 32-bit and 64-bit.
I don't follow. If nothing calls these on the 64-bit side, then there's
no interface they need to be there for.
Thanks,
Mark.
next prev parent reply other threads:[~2015-04-29 16:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-28 19:23 [PATCH v5 1/2] firmware: qcom: scm: Split out 32-bit specific SCM code Kumar Gala
2015-04-28 19:23 ` [PATCH v5 2/2] firmware: qcom: scm: Add support for ARM64 SoCs Kumar Gala
2015-04-29 15:42 ` Mark Rutland
2015-04-29 16:18 ` Kumar Gala
2015-04-29 16:38 ` Mark Rutland [this message]
2015-04-29 17:25 ` Kumar Gala
2015-08-06 1:27 ` Stephen Boyd
2015-08-06 3:30 ` Andy Gross
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=20150429163808.GE8781@leverpostej \
--to=mark.rutland@arm.com \
--cc=Catalin.Marinas@arm.com \
--cc=Lorenzo.Pieralisi@arm.com \
--cc=arm@kernel.org \
--cc=galak@codeaurora.org \
--cc=lina.iyer@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.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