All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sai Prakash Ranjan <saiprakash.ranjan@codeaurora.org>
To: Stephen Boyd <swboyd@chromium.org>
Cc: Vivek Gautam <vivek.gautam@codeaurora.org>,
	agross@kernel.org, iommu@lists.linux-foundation.org,
	joro@8bytes.org, robin.murphy@arm.com, will.deacon@arm.com,
	bjorn.andersson@linaro.org, linux-arm-msm@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-arm-msm-owner@vger.kernel.org
Subject: Re: [PATCH v4 3/3] iommu: arm-smmu-impl: Add sdm845 implementation hook
Date: Mon, 16 Sep 2019 15:17:52 +0530	[thread overview]
Message-ID: <f61884eb2b71fe90a8b5dda6c33b1c9d@codeaurora.org> (raw)
In-Reply-To: <5d72761c.1c69fb81.bf5be.09b4@mx.google.com>

Hi Stephen,

On 2019-09-06 20:37, Stephen Boyd wrote:
> Quoting Vivek Gautam (2019-08-22 23:32:48)
>> diff --git a/drivers/iommu/arm-smmu-impl.c 
>> b/drivers/iommu/arm-smmu-impl.c
>> index 3f88cd078dd5..0aef87c41f9c 100644
>> --- a/drivers/iommu/arm-smmu-impl.c
>> +++ b/drivers/iommu/arm-smmu-impl.c
>> @@ -102,7 +103,6 @@ static struct arm_smmu_device 
>> *cavium_smmu_impl_init(struct arm_smmu_device *smm
>>         return &cs->smmu;
>>  }
>> 
>> -
>>  #define ARM_MMU500_ACTLR_CPRE          (1 << 1)
>> 
>>  #define ARM_MMU500_ACR_CACHE_LOCK      (1 << 26)
> 
> Drop this hunk?
> 
>> @@ -147,6 +147,28 @@ static const struct arm_smmu_impl arm_mmu500_impl 
>> = {
>>         .reset = arm_mmu500_reset,
>>  };
>> 
>> +static int qcom_sdm845_smmu500_reset(struct arm_smmu_device *smmu)
>> +{
>> +       int ret;
>> +
>> +       arm_mmu500_reset(smmu);
>> +
>> +       /*
>> +        * To address performance degradation in non-real time 
>> clients,
>> +        * such as USB and UFS, turn off wait-for-safe on sdm845 based 
>> boards,
>> +        * such as MTP and db845, whose firmwares implement secure 
>> monitor
>> +        * call handlers to turn on/off the wait-for-safe logic.
>> +        */
>> +       ret = qcom_scm_qsmmu500_wait_safe_toggle(0);
>> +       if (ret)
>> +               dev_warn(smmu->dev, "Failed to turn off SAFE 
>> logic\n");
>> +
>> +       return 0;
> 
> return ret? Or intentionally don't return an error for failure?
> 
>> +}
>> +
>> +const struct arm_smmu_impl qcom_sdm845_smmu500_impl = {
> 
> static?
> 
>> +       .reset = qcom_sdm845_smmu500_reset,
>> +};
>> 
>>  struct arm_smmu_device *arm_smmu_impl_init(struct arm_smmu_device 
>> *smmu)
>>  {

Have addressed all your comments in v5.

Thanks,
Sai

-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a 
member
of Code Aurora Forum, hosted by The Linux Foundation

WARNING: multiple messages have this Message-ID (diff)
From: Sai Prakash Ranjan <saiprakash.ranjan@codeaurora.org>
To: Stephen Boyd <swboyd@chromium.org>
Cc: linux-arm-msm@vger.kernel.org, will.deacon@arm.com,
	linux-kernel@vger.kernel.org, bjorn.andersson@linaro.org,
	iommu@lists.linux-foundation.org, agross@kernel.org,
	robin.murphy@arm.com, linux-arm-msm-owner@vger.kernel.org
Subject: Re: [PATCH v4 3/3] iommu: arm-smmu-impl: Add sdm845 implementation hook
Date: Mon, 16 Sep 2019 15:17:52 +0530	[thread overview]
Message-ID: <f61884eb2b71fe90a8b5dda6c33b1c9d@codeaurora.org> (raw)
In-Reply-To: <5d72761c.1c69fb81.bf5be.09b4@mx.google.com>

Hi Stephen,

On 2019-09-06 20:37, Stephen Boyd wrote:
> Quoting Vivek Gautam (2019-08-22 23:32:48)
>> diff --git a/drivers/iommu/arm-smmu-impl.c 
>> b/drivers/iommu/arm-smmu-impl.c
>> index 3f88cd078dd5..0aef87c41f9c 100644
>> --- a/drivers/iommu/arm-smmu-impl.c
>> +++ b/drivers/iommu/arm-smmu-impl.c
>> @@ -102,7 +103,6 @@ static struct arm_smmu_device 
>> *cavium_smmu_impl_init(struct arm_smmu_device *smm
>>         return &cs->smmu;
>>  }
>> 
>> -
>>  #define ARM_MMU500_ACTLR_CPRE          (1 << 1)
>> 
>>  #define ARM_MMU500_ACR_CACHE_LOCK      (1 << 26)
> 
> Drop this hunk?
> 
>> @@ -147,6 +147,28 @@ static const struct arm_smmu_impl arm_mmu500_impl 
>> = {
>>         .reset = arm_mmu500_reset,
>>  };
>> 
>> +static int qcom_sdm845_smmu500_reset(struct arm_smmu_device *smmu)
>> +{
>> +       int ret;
>> +
>> +       arm_mmu500_reset(smmu);
>> +
>> +       /*
>> +        * To address performance degradation in non-real time 
>> clients,
>> +        * such as USB and UFS, turn off wait-for-safe on sdm845 based 
>> boards,
>> +        * such as MTP and db845, whose firmwares implement secure 
>> monitor
>> +        * call handlers to turn on/off the wait-for-safe logic.
>> +        */
>> +       ret = qcom_scm_qsmmu500_wait_safe_toggle(0);
>> +       if (ret)
>> +               dev_warn(smmu->dev, "Failed to turn off SAFE 
>> logic\n");
>> +
>> +       return 0;
> 
> return ret? Or intentionally don't return an error for failure?
> 
>> +}
>> +
>> +const struct arm_smmu_impl qcom_sdm845_smmu500_impl = {
> 
> static?
> 
>> +       .reset = qcom_sdm845_smmu500_reset,
>> +};
>> 
>>  struct arm_smmu_device *arm_smmu_impl_init(struct arm_smmu_device 
>> *smmu)
>>  {

Have addressed all your comments in v5.

Thanks,
Sai

-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a 
member
of Code Aurora Forum, hosted by The Linux Foundation
_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu

  reply	other threads:[~2019-09-16  9:47 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-23  6:32 [PATCH v4 0/3] Qcom smmu-500 wait-for-safe handling for sdm845 Vivek Gautam
2019-08-23  6:32 ` Vivek Gautam
2019-08-23  6:32 ` [PATCH v4 1/3] firmware: qcom_scm-64: Add atomic version of qcom_scm_call Vivek Gautam
2019-08-23  6:32   ` Vivek Gautam
2019-09-06 15:12   ` Stephen Boyd
2019-09-06 15:12     ` Stephen Boyd
2019-09-16  9:48     ` Sai Prakash Ranjan
2019-09-16  9:48       ` Sai Prakash Ranjan
2019-08-23  6:32 ` [PATCH v4 2/3] firmware/qcom_scm: Add scm call to handle smmu errata Vivek Gautam
2019-08-23  6:32   ` Vivek Gautam
2019-08-23  6:32 ` [PATCH v4 3/3] iommu: arm-smmu-impl: Add sdm845 implementation hook Vivek Gautam
2019-08-23  6:32   ` Vivek Gautam
2019-09-06  6:32   ` Vivek Gautam
2019-09-06  6:32     ` Vivek Gautam
2019-09-06 15:07   ` Stephen Boyd
2019-09-06 15:07     ` Stephen Boyd
2019-09-16  9:47     ` Sai Prakash Ranjan [this message]
2019-09-16  9:47       ` Sai Prakash Ranjan
2019-09-10 13:26   ` Robin Murphy
2019-09-10 13:26     ` Robin Murphy
2019-09-16  9:46     ` Sai Prakash Ranjan
2019-09-16  9:46       ` Sai Prakash Ranjan

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=f61884eb2b71fe90a8b5dda6c33b1c9d@codeaurora.org \
    --to=saiprakash.ranjan@codeaurora.org \
    --cc=agross@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=iommu@lists.linux-foundation.org \
    --cc=joro@8bytes.org \
    --cc=linux-arm-msm-owner@vger.kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robin.murphy@arm.com \
    --cc=swboyd@chromium.org \
    --cc=vivek.gautam@codeaurora.org \
    --cc=will.deacon@arm.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.