<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/git/stable/linux-stable.git/drivers/firmware/qcom, branch master</title>
<subtitle>Linux kernel stable tree</subtitle>
<id>https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/atom?h=master</id>
<link rel='self' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/'/>
<updated>2026-07-30T21:31:34+00:00</updated>
<entry>
<title>firmware: qcom: scm: Fix tzmem state on probe retry</title>
<updated>2026-07-30T21:31:34+00:00</updated>
<author>
<name>Mukesh Ojha</name>
<email>mukesh.ojha@oss.qualcomm.com</email>
</author>
<published>2026-07-24T09:49:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=9941fe8a04f3d258e07eb5899db3027252a4190f'/>
<id>urn:sha1:9941fe8a04f3d258e07eb5899db3027252a4190f</id>
<content type='text'>
qcom_tzmem_enable() returns -EBUSY if called a second time, but this
causes probe retries to fail permanently if a later step in
qcom_scm_probe() defers after qcom_tzmem_enable() has already succeeded.

Use DO_ONCE() to ensure qcom_tzmem_init() runs exactly once across all
calls in a thread-safe manner. qcom_tzmem_dev is set on every call since
probe retries use the same device pointer. The result of the first
initialisation is cached and returned to every subsequent caller.

Fixes: 40289e35ca52 ("firmware: qcom: scm: enable the TZ mem allocator")
Reviewed-by: Bartosz Golaszewski &lt;bartosz.golaszewski@oss.qualcomm.com&gt;
Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Signed-off-by: Mukesh Ojha &lt;mukesh.ojha@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260724094939.613844-4-mukesh.ojha@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: Fix reserved memory cleanup on probe failure</title>
<updated>2026-07-30T21:31:34+00:00</updated>
<author>
<name>Mukesh Ojha</name>
<email>mukesh.ojha@oss.qualcomm.com</email>
</author>
<published>2026-07-24T09:49:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=b697b20cea4374d27e2134da4bb7b0ea39f36c8b'/>
<id>urn:sha1:b697b20cea4374d27e2134da4bb7b0ea39f36c8b</id>
<content type='text'>
of_reserved_mem_device_init() adds an entry to a global list with no
devres counterpart. If qcom_scm_probe() fails after the call the
assignment is never cleaned up. A probe retry would add a duplicate
entry, leaking the original one permanently.

Add an err_rmem label that calls of_reserved_mem_device_release() and
route all error paths after of_reserved_mem_device_init() through it.
of_reserved_mem_device_release() is safe to call unconditionally as it
simply walks an empty list when nothing was assigned.

Fixes: a33b2579c8d3 ("firmware: qcom: scm: add support for SHM bridge memory carveout")
Reviewed-by: Bartosz Golaszewski &lt;bartosz.golaszewski@oss.qualcomm.com&gt;
Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Signed-off-by: Mukesh Ojha &lt;mukesh.ojha@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260724094939.613844-3-mukesh.ojha@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: Fix NULL dereference in IRQ handler before __scm is published</title>
<updated>2026-07-30T21:31:33+00:00</updated>
<author>
<name>Mukesh Ojha</name>
<email>mukesh.ojha@oss.qualcomm.com</email>
</author>
<published>2026-07-24T09:49:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=966d23c7e68ea32679275a7e3d2383181002c868'/>
<id>urn:sha1:966d23c7e68ea32679275a7e3d2383181002c868</id>
<content type='text'>
In qcom_scm_probe(), devm_request_threaded_irq() is called before
smp_store_release(&amp;__scm, scm). Two paths can dereference __scm before
it is published, both causing a NULL pointer dereference.

The IRQ handler receives scm via its data argument but passes only wq_ctx
to qcom_scm_waitq_wakeup() and qcom_scm_get_completion(), which then
dereference __scm directly. Thread scm through both functions so the IRQ
handler path never touches __scm.

Non-atomic SMC calls made during probe (e.g. from qcom_tzmem_init via
qcom_scm_shm_bridge_enable) can return WAITQ_SLEEP, causing
qcom_scm_wait_for_wq_completion() to run before __scm is published and
dereference it. Add platform_set_drvdata(pdev, scm) early in probe and
change qcom_scm_wait_for_wq_completion() to take the device pointer and
use dev_get_drvdata() to reach scm, removing any dependency on __scm.

Fixes: 6bf325992236 ("firmware: qcom: scm: Add wait-queue handling logic")
Reviewed-by: Bartosz Golaszewski &lt;bartosz.golaszewski@oss.qualcomm.com&gt;
Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Signed-off-by: Mukesh Ojha &lt;mukesh.ojha@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260724094939.613844-2-mukesh.ojha@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: Allow QSEECOM on Asus Zenbook A16 (UX3607OA)</title>
<updated>2026-07-30T21:31:14+00:00</updated>
<author>
<name>Konrad Dybcio</name>
<email>konrad.dybcio@oss.qualcomm.com</email>
</author>
<published>2026-07-21T17:11:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=ca8c96d3187a11229b3bd44992a9bc3d22caf13a'/>
<id>urn:sha1:ca8c96d3187a11229b3bd44992a9bc3d22caf13a</id>
<content type='text'>
In line with other Glymur-based machines, the Asus Zenbook A16
(UX3607OA) exposes EFI variables through the "uefisecapp".

Add it to the QSEECOM allowlist to enable this access.

Signed-off-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Reviewed-by: Dmitry Baryshkov &lt;dmitry.baryshkov@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260721-topic-a16_submission-v1-3-8ea213130d05@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: Add minidump SRAM support</title>
<updated>2026-07-13T14:43:24+00:00</updated>
<author>
<name>Mukesh Ojha</name>
<email>mukesh.ojha@oss.qualcomm.com</email>
</author>
<published>2026-06-24T19:08:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=7bd52a0d456eef0243f508fc712e59c612ee7d45'/>
<id>urn:sha1:7bd52a0d456eef0243f508fc712e59c612ee7d45</id>
<content type='text'>
On most Qualcomm SoCs where minidump is supported, a word in always-on
SRAM is shared between the operating system (OS) and boot firmware.
Before DDR is initialized on the warm reset following a crash, firmware
reads this word to decide if minidump is enabled and collect a minidump,
and where to deliver it (USB upload to a host, or save to local
storage). The OS is expected to select one of the destinations.

The SRAM region is described by a 'sram' phandle on the SCM DT node.
If the property is absent the feature is silently disabled, keeping
existing SoCs unaffected.

Expose a 'minidump_dest' module parameter (default: usb) so the user
can select the destination. Only the string names "usb" or "storage"
are accepted.

Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Signed-off-by: Mukesh Ojha &lt;mukesh.ojha@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260624190830.3131112-6-mukesh.ojha@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: use dev_err_probe() for dload address failure</title>
<updated>2026-07-13T14:43:13+00:00</updated>
<author>
<name>Mukesh Ojha</name>
<email>mukesh.ojha@oss.qualcomm.com</email>
</author>
<published>2026-06-24T19:08:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=d0a05db99bd0d76aafc20245922eec28c939a192'/>
<id>urn:sha1:d0a05db99bd0d76aafc20245922eec28c939a192</id>
<content type='text'>
Replace the bare `return ret` after qcom_scm_find_dload_address() with
dev_err_probe() to produce a consistent, deferred-probe-aware error
message when the download-mode address cannot be resolved.

Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Reviewed-by: Dmitry Baryshkov &lt;dmitry.baryshkov@oss.qualcomm.com&gt;
Signed-off-by: Mukesh Ojha &lt;mukesh.ojha@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260624190830.3131112-5-mukesh.ojha@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: Fix missing smp_load_acquire()</title>
<updated>2026-07-13T14:43:13+00:00</updated>
<author>
<name>Mukesh Ojha</name>
<email>mukesh.ojha@oss.qualcomm.com</email>
</author>
<published>2026-06-24T19:08:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=d9603a7790d164657a51997d7265ca845bee78bf'/>
<id>urn:sha1:d9603a7790d164657a51997d7265ca845bee78bf</id>
<content type='text'>
__scm is published in qcom_scm_probe() with smp_store_release()
but qcom_scm_set_download_mode() reads it directly without
smp_load_acquire(), creating a potential ordering violation where a
CPU could observe a stale or partially initialised __scm pointer.

Use smp_load_acquire() to acquire __scm in the
qcom_scm_set_download_mode() function.

Signed-off-by: Mukesh Ojha &lt;mukesh.ojha@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260624190830.3131112-4-mukesh.ojha@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: Allow QSEECOM on Honor Magicbook Art 14</title>
<updated>2026-07-11T16:31:11+00:00</updated>
<author>
<name>Konstantin Shabanov</name>
<email>mail@etehtsea.me</email>
</author>
<published>2026-06-29T15:48:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=cfe9b47ef18bdb737be480f3e539e9561ef74078'/>
<id>urn:sha1:cfe9b47ef18bdb737be480f3e539e9561ef74078</id>
<content type='text'>
Allow particular machine accessing eg. efivars.

Signed-off-by: Konstantin Shabanov &lt;mail@etehtsea.me&gt;
Reviewed-by: Dmitry Baryshkov &lt;dmitry.baryshkov@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260629154812.9066-5-mail@etehtsea.me
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: instrument SMC call path with tracepoints</title>
<updated>2026-07-11T16:31:11+00:00</updated>
<author>
<name>Yuvaraj Ranganathan</name>
<email>yuvaraj.ranganathan@oss.qualcomm.com</email>
</author>
<published>2026-05-22T06:39:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=41329e72363c02facfeae063ef304aa7ced68c3b'/>
<id>urn:sha1:41329e72363c02facfeae063ef304aa7ced68c3b</id>
<content type='text'>
Wire the five tracepoints defined in qcom_scm_trace.h into the SMC
execution path by including the header with CREATE_TRACE_POINTS.

Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Signed-off-by: Yuvaraj Ranganathan &lt;yuvaraj.ranganathan@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260522-scm-tracepoints-v2-2-e27cdbe0c585@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: qcom: scm: add trace events for the SMC call interface</title>
<updated>2026-07-11T16:31:11+00:00</updated>
<author>
<name>Yuvaraj Ranganathan</name>
<email>yuvaraj.ranganathan@oss.qualcomm.com</email>
</author>
<published>2026-05-22T06:38:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=f6bb2daa4584229af155c2488b83151999315293'/>
<id>urn:sha1:f6bb2daa4584229af155c2488b83151999315293</id>
<content type='text'>
The SCM SMC call path is opaque at runtime. Stalls caused by firmware
congestion, QCOM_SCM_WAITQ_SLEEP/RESUME cycles, and EBUSY retry loops
are invisible without recompiling the kernel with temporary printk
statements or attaching a hardware debugger.

Add five TRACE_EVENTs covering the complete lifecycle of an SCM call:

  scm_smc_request
    Emit before each arm_smccc_smc_quirk() invocation. Records the
    SMC function ID, decoded service and command identifiers, argument
    count, and up to six register arguments in hex and decimal. Because
    the caller loops on QCOM_SCM_INTERRUPTED, this event fires once per
    physical SMC instruction including inte

  scm_smc_done
    Emit after the outer __scm_smc_do() returns, pairing each
    request with its final outcome. Records the SMC function ID, the
    kernel error code returned to the caller, and the four firmware
    result registers a0-a3.

  scm_waitq_sleep
    Emit when the firmware returns QCOM_SCM_WAITQ_SLEEP. Records
    the wait-queue context and the SMC call context handles required
    to issue the matching WAITQ_RESUME.

  scm_waitq_resume
    Emit just before constructing and sending the WAITQ_RESUME
    follow-up call. Records the SMC call context handle being resumed.

  scm_waitq_get_wq_ctx
    Emit after a successful WAITQ_GET_WQ_CTX fast-call. Records
    the returned wait-queue context, flags, and more_pending indicator.

These events let ftrace and perf reconstruct the full sequence of
firmware interactions, measure per-call and end-to-end latency, and
attribute waitqueue stalls to specific service/command pairs without
modifying driver source.

Reviewed-by: Konrad Dybcio &lt;konrad.dybcio@oss.qualcomm.com&gt;
Signed-off-by: Yuvaraj Ranganathan &lt;yuvaraj.ranganathan@oss.qualcomm.com&gt;
Link: https://lore.kernel.org/r/20260522-scm-tracepoints-v2-1-e27cdbe0c585@oss.qualcomm.com
Signed-off-by: Bjorn Andersson &lt;andersson@kernel.org&gt;
</content>
</entry>
</feed>
