Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
From: neil.armstrong@linaro.org
To: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konradybcio@kernel.org>,
	Mukesh Ojha <quic_mojha@quicinc.com>,
	Stephan Gerhold <stephan.gerhold@linaro.org>,
	Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
	Kuldeep Singh <quic_kuldsing@quicinc.com>,
	Elliot Berman <quic_eberman@quicinc.com>,
	Andrew Halaney <ahalaney@redhat.com>,
	Avaneesh Kumar Dwivedi <quic_akdwived@quicinc.com>,
	Andy Gross <andy.gross@linaro.org>,
	linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH 0/6] firmware: qcom: scm: Fixes for concurrency
Date: Wed, 20 Nov 2024 17:20:18 +0100	[thread overview]
Message-ID: <d7071991-db0a-49cc-a345-71457d68617c@linaro.org> (raw)
In-Reply-To: <vr64bidkdzoebqmkq3f5jnpqf2hqcf2nvqc27vhu53ave3bced@3ffd2wqtxrvd>

On 20/11/2024 12:13, Dmitry Baryshkov wrote:
> On Tue, Nov 19, 2024 at 07:33:16PM +0100, Krzysztof Kozlowski wrote:
>> SCM driver looks messy in terms of handling concurrency of probe.  The
>> driver exports interface which is guarded by global '__scm' variable
>> but:
>> 1. Lacks proper read barrier (commit adding write barriers mixed up
>>     READ_ONCE with a read barrier).
>> 2. Lacks barriers or checks for '__scm' in multiple places.
>> 3. Lacks probe error cleanup.
>>
>> I fixed here few visible things, but this was not tested extensively.  I
>> tried only SM8450.
>>
>> ARM32 and SC8280xp/X1E platforms would be useful for testing as well.
> 
> ARM32 devices are present in the lab.

I passed the patchset on our devices, and no regressions observed:

arm32: https://git.codelinaro.org/linaro/qcomlt/ci/staging/cdba-tester/-/pipelines/116195
arm64(including x1e): https://git.codelinaro.org/linaro/qcomlt/ci/staging/cdba-tester/-/pipelines/116201

Neil

> 
>>
>> All the issues here are non-urgent, IOW, they were here for some time
>> (v6.10-rc1 and earlier).
>>
>> Best regards,
>> Krzysztof
>>
>> ---
>> Krzysztof Kozlowski (6):
>>        firmware: qcom: scm: Fix missing read barrier in qcom_scm_is_available()
>>        firmware: qcom: scm: Fix missing read barrier in qcom_scm_get_tzmem_pool()
>>        firmware: qcom: scm: Handle various probe ordering for qcom_scm_assign_mem()
>>        [RFC/RFT] firmware: qcom: scm: Cleanup global '__scm' on probe failures
>>        firmware: qcom: scm: smc: Handle missing SCM device
>>        firmware: qcom: scm: smc: Narrow 'mempool' variable scope
>>
>>   drivers/firmware/qcom/qcom_scm-smc.c |  6 +++-
>>   drivers/firmware/qcom/qcom_scm.c     | 55 +++++++++++++++++++++++++-----------
>>   2 files changed, 44 insertions(+), 17 deletions(-)
>> ---
>> base-commit: 414c97c966b69e4a6ea7b32970fa166b2f9b9ef0
>> change-id: 20241119-qcom-scm-missing-barriers-and-all-sort-of-srap-a25d59074882
>>
>> Best regards,
>> -- 
>> Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>>
> 


      reply	other threads:[~2024-11-20 16:20 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-19 18:33 [PATCH 0/6] firmware: qcom: scm: Fixes for concurrency Krzysztof Kozlowski
2024-11-19 18:33 ` [PATCH 1/6] firmware: qcom: scm: Fix missing read barrier in qcom_scm_is_available() Krzysztof Kozlowski
2024-11-20 10:51   ` Bartosz Golaszewski
2024-11-19 18:33 ` [PATCH 2/6] firmware: qcom: scm: Fix missing read barrier in qcom_scm_get_tzmem_pool() Krzysztof Kozlowski
2024-11-19 18:45   ` Krzysztof Kozlowski
2024-11-19 18:33 ` [PATCH 3/6] firmware: qcom: scm: Handle various probe ordering for qcom_scm_assign_mem() Krzysztof Kozlowski
2024-11-20 14:07   ` Bartosz Golaszewski
2024-11-20 14:19     ` Krzysztof Kozlowski
2024-11-20 14:21       ` Krzysztof Kozlowski
2024-11-27  4:45       ` Bjorn Andersson
2024-11-19 18:33 ` [PATCH RFC/RFT 4/6] firmware: qcom: scm: Cleanup global '__scm' on probe failures Krzysztof Kozlowski
2024-11-19 19:37   ` Krzysztof Kozlowski
2024-11-28 20:25     ` Konrad Dybcio
2024-11-19 18:33 ` [PATCH 5/6] firmware: qcom: scm: smc: Handle missing SCM device Krzysztof Kozlowski
2024-11-19 18:33 ` [PATCH 6/6] firmware: qcom: scm: smc: Narrow 'mempool' variable scope Krzysztof Kozlowski
2024-11-20 11:06   ` Bartosz Golaszewski
2024-11-20 11:13 ` [PATCH 0/6] firmware: qcom: scm: Fixes for concurrency Dmitry Baryshkov
2024-11-20 16:20   ` neil.armstrong [this message]

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=d7071991-db0a-49cc-a345-71457d68617c@linaro.org \
    --to=neil.armstrong@linaro.org \
    --cc=ahalaney@redhat.com \
    --cc=andersson@kernel.org \
    --cc=andy.gross@linaro.org \
    --cc=bartosz.golaszewski@linaro.org \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=konradybcio@kernel.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=quic_akdwived@quicinc.com \
    --cc=quic_eberman@quicinc.com \
    --cc=quic_kuldsing@quicinc.com \
    --cc=quic_mojha@quicinc.com \
    --cc=stable@vger.kernel.org \
    --cc=stephan.gerhold@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