From: Johan Hovold <johan@kernel.org>
To: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Cc: Bjorn Andersson <andersson@kernel.org>,
Maximilian Luz <luzmaximilian@gmail.com>,
Konrad Dybcio <konradybcio@kernel.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Ard Biesheuvel <ardb@kernel.org>,
Steev Klimaszewski <steev@kali.org>,
linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
devicetree@vger.kernel.org, linux-efi@vger.kernel.org,
Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Subject: Re: [PATCH v4 6/8] firmware: qcom: scm: add modparam to control QSEECOM enablement
Date: Fri, 27 Jun 2025 14:46:38 +0200 [thread overview]
Message-ID: <aF6Srse7BhDJkQiH@hovoldconsulting.com> (raw)
In-Reply-To: <cjinqyqn7qgvdoltoywxa2lq6bjyfrotmon3iv24tqt3bpdlpe@3xb2k42ffegj>
On Fri, Jun 27, 2025 at 02:33:27AM +0300, Dmitry Baryshkov wrote:
> On Thu, Jun 26, 2025 at 02:58:52PM +0200, Johan Hovold wrote:
> > On Thu, Jun 26, 2025 at 02:08:23PM +0300, Dmitry Baryshkov wrote:
> > > On Thu, Jun 26, 2025 at 12:11:20PM +0200, Johan Hovold wrote:
> > > > On Wed, Jun 25, 2025 at 01:53:25AM +0300, Dmitry Baryshkov wrote:
> > > > > From: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> > > > >
> > > > > In preparation to enabling QSEECOM for the platforms rather than
> > > > > individual machines provide a mechanism for the user to override default
> > > > > selection. Allow users to use qcom_scm.qseecom modparam.
> > > > >
> > > > > Setting it to 'force' will enable QSEECOM even if it disabled or not
> > > > > handled by the allowlist.
> > > > >
> > > > > Setting it to 'off' will forcibly disable the QSEECOM interface,
> > > > > allowing incompatible machines to function.
> > > > >
> > > > > Setting it to 'roefivars' will enable the QSEECOM interface, making UEFI
> > > > > variables read-only.
> > > > >
> > > > > All other values mean 'auto', trusting the allowlist in the module.
> > > >
> > > > I don't see the need for this. The kernel should just provide sensible
> > > > defaults.
> > >
> > > It does provide _defaults_. However with the next commit we mass-enable
> > > QSEECOM for SoC families, which includes untested WoA devices. If the
> > > user observes a misbehaviour of the UEFI vars or any other
> > > QSEECOM-related driver on those platforms, it is much easier to let
> > > users test and workaround UEFI misbehaviour.
> >
> > You basically know by now which machines supports qseecom and which do
> > not, right (e.g. UFS storage means non-persistent EFI vars)?
Do you have a theory about why on some platforms, like the one you're
currently adding support for, writing UEFI variables does not work?
Can you please include that information in the series so we can consider
alternate routes for replacing the current whitelist with this black and
white thing you're going for.
Is it related to UFS at all, for example?
> > And it's a pretty bad user experience to have people trying to write
> > efivariables when setting up a machine and then spend hours trying to
> > debug why they don't persist after a reboot.
> >
> > I don't think that's fair to users.
>
> So, is it a user or a developer, trying to port Linux to a new hardware?
> Also, R/O implementation makes it obvious, that the variables do not
> persist.
A developer enabling support for a new platform can patch the driver and
does not need a command line option.
If you enable it by default, suddenly a bunch of end-users are going to
have to debug why storing efi variables silently fails. That would not
be fair to them.
> > Let whoever brings up a new machine figure this out. It's just one
> > entry, no scaling issues, and we get accurate information (unless
> > Qualcomm, who sits on the documentation, is willing to provide it
> > upfront).
>
> And that's not really scallable. All other parts of a particular device
> are described by the DT only (that's especially true on the PMIC GLINK
> machines). If we are to support new laptop in e.g. distro kernel, we
> need to provide a DT... and a patch for qcom-scm driver. I'd very much
> prefer to do it other way around: provide a DT and patch qcom-scm if the
> laptop is any way different from other laptops. E.g. we know that all
> X1Elite laptops support R/W EFI variables.
But this is just kicking the can and putting the burden on someone else.
Now a user or distro would need to pass command line parameters after
spending time debugging why efi variable updates do not persist after a
reboot.
If we know with reasonable certainty that all, say X1E, devices works,
then that that's one thing.
But if this series now enables broken EFI variable support on every
other device then I don't think that's ok (even if you provide a command
line parameter that each user now have to pass).
Then I'd rather see a proposal for how to determine which machines
support this or not, information which was not available when this
interface was reverse engineered and where a conservative whitelist
approach made perfect sense.
> Except for X1-CRD, which deserves an entry in the driver.
I think you meant my sc8280xp CRD here.
Johan
next prev parent reply other threads:[~2025-06-27 12:46 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-24 22:53 [PATCH v4 0/8] firmware: qcom: enable UEFI variables on Lenovo Yoga C630 Dmitry Baryshkov
2025-06-24 22:53 ` [PATCH v4 1/8] efi: efivars: don't crash in efivar_set_variable{,_locked} in r/o case Dmitry Baryshkov
2025-06-26 10:04 ` Johan Hovold
2025-06-26 11:03 ` Dmitry Baryshkov
2025-06-26 12:51 ` Johan Hovold
2025-06-26 12:54 ` Dmitry Baryshkov
2025-06-27 12:27 ` Johan Hovold
2025-06-28 15:05 ` Dmitry Baryshkov
2025-06-30 12:15 ` Johan Hovold
2025-06-24 22:53 ` [PATCH v4 2/8] firmware: qcom: scm: allow specifying quirks for QSEECOM implementations Dmitry Baryshkov
2025-06-24 22:53 ` [PATCH v4 3/8] firmware: qcom: uefisecapp: add support for R/O UEFI vars Dmitry Baryshkov
2025-07-16 19:13 ` Bjorn Andersson
2025-07-16 21:07 ` Dmitry Baryshkov
2025-06-24 22:53 ` [PATCH v4 4/8] firmware: qcom: enable QSEECOM on Lenovo Yoga C630 Dmitry Baryshkov
2025-06-24 22:53 ` [PATCH v4 5/8] firmware; qcom: scm: enable QSEECOM on SC8280XP CRD Dmitry Baryshkov
2025-06-26 23:34 ` Konrad Dybcio
2025-06-26 23:48 ` Dmitry Baryshkov
2025-06-26 23:54 ` Konrad Dybcio
2025-06-27 12:23 ` Johan Hovold
2025-06-27 12:26 ` Konrad Dybcio
2025-06-27 12:50 ` Johan Hovold
2025-06-28 14:50 ` Dmitry Baryshkov
2025-06-30 12:16 ` Johan Hovold
2025-07-16 19:02 ` Bjorn Andersson
2025-06-24 22:53 ` [PATCH v4 6/8] firmware: qcom: scm: add modparam to control QSEECOM enablement Dmitry Baryshkov
2025-06-26 10:11 ` Johan Hovold
2025-06-26 11:08 ` Dmitry Baryshkov
2025-06-26 12:58 ` Johan Hovold
2025-06-26 23:33 ` Dmitry Baryshkov
2025-06-27 12:46 ` Johan Hovold [this message]
2025-06-28 15:03 ` Dmitry Baryshkov
2025-06-30 12:42 ` Johan Hovold
2025-07-01 11:10 ` Dmitry Baryshkov
2025-07-10 9:40 ` Johan Hovold
2025-06-24 22:53 ` [PATCH v4 7/8] firmware: qcom: scm: rework QSEECOM allowlist Dmitry Baryshkov
2025-06-26 9:56 ` Johan Hovold
2025-06-26 11:09 ` Dmitry Baryshkov
2025-06-26 13:02 ` Johan Hovold
2025-06-24 22:53 ` [PATCH v4 8/8] arm64: dts: qcom: sdm850-lenovo-yoga-c630: fix RTC offset info Dmitry Baryshkov
2025-06-26 10:16 ` Johan Hovold
2025-06-26 11:10 ` Dmitry Baryshkov
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=aF6Srse7BhDJkQiH@hovoldconsulting.com \
--to=johan@kernel.org \
--cc=andersson@kernel.org \
--cc=ardb@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.baryshkov@linaro.org \
--cc=dmitry.baryshkov@oss.qualcomm.com \
--cc=konrad.dybcio@oss.qualcomm.com \
--cc=konradybcio@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-efi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luzmaximilian@gmail.com \
--cc=robh@kernel.org \
--cc=steev@kali.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