Re: [PATCH v6 4/6] iommu/arm-smmu: Add the device_link between masters and smmu

2018-02-01 Thread Vivek Gautam
Hi, On 1/31/2018 6:39 PM, Robin Murphy wrote: On 19/01/18 11:43, Vivek Gautam wrote: From: Sricharan R <sricha...@codeaurora.org> Finally add the device link between the master device and smmu, so that the smmu gets runtime enabled/disabled only when the master needs it. This is don

Re: [PATCH v6 2/6] iommu/arm-smmu: Add pm_runtime/sleep ops

2018-01-31 Thread Vivek Gautam
On 1/31/2018 5:53 PM, Robin Murphy wrote: On 19/01/18 11:43, Vivek Gautam wrote: From: Sricharan R <sricha...@codeaurora.org> The smmu needs to be functional only when the respective master's using it are active. The device_link feature helps to track such functional dependenci

Re: [PATCH v6 5/6] iommu/arm-smmu: Add support for qcom,smmu-v2 variant

2018-01-31 Thread Vivek Gautam
On 1/30/2018 1:12 AM, Rob Herring wrote: On Fri, Jan 19, 2018 at 05:13:42PM +0530, Vivek Gautam wrote: qcom,smmu-v2 is an arm,smmu-v2 implementation with specific clock and power requirements. This smmu core is used with multiple masters on msm8996, viz. mdss, video, etc. Add bindings

[PATCH v6 6/6] drm/msm: iommu: Replace runtime calls with runtime suppliers

2018-01-19 Thread Vivek Gautam
() calls, to power-up the connected iommu through the device link interface. In case the device link is not setup these get/put_suppliers() calls will be a no-op, and the iommu driver should take care of powering on its devices accordingly. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.

[PATCH v6 4/6] iommu/arm-smmu: Add the device_link between masters and smmu

2018-01-19 Thread Vivek Gautam
From: Sricharan R Finally add the device link between the master device and smmu, so that the smmu gets runtime enabled/disabled only when the master needs it. This is done from add_device callback which gets called once when the master is added to the smmu.

[PATCH v6 5/6] iommu/arm-smmu: Add support for qcom,smmu-v2 variant

2018-01-19 Thread Vivek Gautam
qcom,smmu-v2 is an arm,smmu-v2 implementation with specific clock and power requirements. This smmu core is used with multiple masters on msm8996, viz. mdss, video, etc. Add bindings for the same. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- .../devicetree/bindings/iom

[PATCH v6 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2018-01-19 Thread Vivek Gautam
aran R <sricha...@codeaurora.org> [vivek: Cleanup pm runtime calls] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drivers/iommu/arm-smmu.c | 45 + 1 file changed, 41 insertions(+), 4 deletions(-) diff --git a/drivers/iommu/ar

[PATCH v6 2/6] iommu/arm-smmu: Add pm_runtime/sleep ops

2018-01-19 Thread Vivek Gautam
; Signed-off-by: Archit Taneja <arch...@codeaurora.org> [vivek: Clock rework to request bulk of clocks] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drivers/iommu/arm-smmu.c | 55 ++-- 1 file changed, 53 insertions(+), 2

[PATCH v6 0/6] iommu/arm-smmu: Add runtime pm/sleep support

2018-01-19 Thread Vivek Gautam
device_link between masters and smmu Vivek Gautam (3): base: power: runtime: Export pm_runtime_get/put_suppliers iommu/arm-smmu: Add support for qcom,smmu-v2 variant drm/msm: iommu: Replace runtime calls with runtime suppliers .../devicetree/bindings/iommu/arm,smmu.txt | 43 +++

Re: [PATCH v5 1/6] base: power: runtime: Export pm_runtime_get/put_suppliers

2018-01-11 Thread Vivek Gautam
On 01/12/2018 04:23 AM, Rafael J. Wysocki wrote: On Tue, Jan 9, 2018 at 11:01 AM, Vivek Gautam <vivek.gau...@codeaurora.org> wrote: The device link allows the pm framework to tie the supplier and consumer. So, whenever the consumer is powered-on the supplier is powered-on

Re: [PATCH v5 5/6] iommu/arm-smmu: Add support for qcom,smmu-v2 variant

2018-01-11 Thread Vivek Gautam
Hi Rob, On 01/12/2018 03:53 AM, Rob Herring wrote: On Tue, Jan 09, 2018 at 03:31:48PM +0530, Vivek Gautam wrote: qcom,smmu-v2 is an arm,smmu-v2 implementation with specific clock and power requirements. This smmu core is used with multiple masters on msm8996, viz. mdss, video, etc. Add

Re: [PATCH v5 0/6] iommu/arm-smmu: Add runtime pm/sleep support

2018-01-09 Thread Vivek Gautam
On 01/09/2018 04:53 PM, Rafael J. Wysocki wrote: On Tuesday, January 9, 2018 11:01:43 AM CET Vivek Gautam wrote: This series provides the support for turning on the arm-smmu's clocks/power domains using runtime pm. This is done using the recently introduced device links patches, which lets

[PATCH v5 5/6] iommu/arm-smmu: Add support for qcom,smmu-v2 variant

2018-01-09 Thread Vivek Gautam
qcom,smmu-v2 is an arm,smmu-v2 implementation with specific clock and power requirements. This smmu core is used with multiple masters on msm8996, viz. mdss, video, etc. Add bindings for the same. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- * Major change in this

[PATCH v5 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2018-01-09 Thread Vivek Gautam
aran R <sricha...@codeaurora.org> [vivek: Cleanup pm runtime calls] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drivers/iommu/arm-smmu.c | 45 + 1 file changed, 41 insertions(+), 4 deletions(-) diff --git a/drivers/iommu/ar

[PATCH v5 1/6] base: power: runtime: Export pm_runtime_get/put_suppliers

2018-01-09 Thread Vivek Gautam
://patchwork.kernel.org/patch/9827825/ Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- * This is v2 of the patch [1]. Adding it to this patch series. [1] https://patchwork.kernel.org/patch/10102447/ drivers/base/power/runtime.c | 2 ++ 1 file changed, 2 insertions(+) diff

[PATCH v5 4/6] iommu/arm-smmu: Add the device_link between masters and smmu

2018-01-09 Thread Vivek Gautam
From: Sricharan R Finally add the device link between the master device and smmu, so that the smmu gets runtime enabled/disabled only when the master needs it. This is done from add_device callback which gets called once when the master is added to the smmu.

[PATCH v5 2/6] iommu/arm-smmu: Add pm_runtime/sleep ops

2018-01-09 Thread Vivek Gautam
; Signed-off-by: Archit Taneja <arch...@codeaurora.org> [vivek: Clock rework to request bulk of clocks] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drivers/iommu/arm-smmu.c | 55 ++-- 1 file changed, 53 insertions(+), 2

[PATCH v5 6/6] drm/msm: iommu: Replace runtime calls with runtime suppliers

2018-01-09 Thread Vivek Gautam
() calls, to power-up the connected iommu through the device link interface. In case the device link is not setup these get/put_suppliers() calls will be a no-op, and the iommu driver should take care of powering on its devices accordingly. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.

[PATCH v5 0/6] iommu/arm-smmu: Add runtime pm/sleep support

2018-01-09 Thread Vivek Gautam
445/ Sricharan R (3): iommu/arm-smmu: Add pm_runtime/sleep ops iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device iommu/arm-smmu: Add the device_link between masters and smmu Vivek Gautam (3): base: power: runtime: Export pm_runtime_get/put_suppliers iommu/arm-smmu: Add supp

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-11-28 Thread Vivek Gautam
On 11/28/2017 05:13 AM, Rob Clark wrote: On Mon, Nov 27, 2017 at 5:22 PM, Stephen Boyd<sb...@codeaurora.org> wrote: On 11/15, Vivek Gautam wrote: Hi, On Mon, Aug 7, 2017 at 5:59 PM, Rob Clark<robdcl...@gmail.com> wrote: On Mon, Aug 7, 2017 at 4:27 AM, Vivek Gauta

Re: [PATCH v2 1/1] iommu/arm-smmu: Defer TLB flush in case of unmap op

2017-11-20 Thread Vivek Gautam
Hi Will, On 10/14/2017 12:38 AM, Will Deacon wrote: On Wed, Sep 06, 2017 at 11:07:35AM +0530, Vivek Gautam wrote: We don't want to touch the TLB when smmu is suspended, so defer the TLB maintenance until smmu is resumed. On resume, we issue arm_smmu_device_reset() to restore the configuration

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-11-14 Thread Vivek Gautam
Hi, On Mon, Aug 7, 2017 at 5:59 PM, Rob Clark <robdcl...@gmail.com> wrote: > On Mon, Aug 7, 2017 at 4:27 AM, Vivek Gautam > <vivek.gau...@codeaurora.org> wrote: >> On Thu, Jul 13, 2017 at 5:20 PM, Rob Clark <robdcl...@gmail.com> wrote: >>> On Thu, Jul 1

Re: [RFC PATCH 1/1] iommu/arm-smmu: Add support for multiple TBU child devices

2017-09-27 Thread Vivek Gautam
Hi Rob, On 09/19/2017 07:40 PM, Rob Herring wrote: Thanks for reviewing the patch. On Tue, Sep 12, 2017 at 05:31:07PM +0530, Vivek Gautam wrote: ARM MMU-500 implements a TBU (uTLB) for each connected master besides a single TCU which controls and manages the address translations. Each

Re: [PATCH v2 1/1] iommu/arm-smmu: Defer TLB flush in case of unmap op

2017-09-13 Thread Vivek Gautam
Hi, On 09/06/2017 11:07 AM, Vivek Gautam wrote: We don't want to touch the TLB when smmu is suspended, so defer the TLB maintenance until smmu is resumed. On resume, we issue arm_smmu_device_reset() to restore the configuration and flush the TLBs. Signed-off-by: Vivek Gautam <vivek.

[RFC PATCH 1/1] iommu/arm-smmu: Add support for multiple TBU child devices

2017-09-12 Thread Vivek Gautam
as long as it's available. When the master is not available, the TBUs are identified with sid and powered on. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- - The idea behind this patch is to handle the distributed smmu architectures, similar to MMU-500. - Untest

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-08-07 Thread Vivek Gautam
On Thu, Jul 13, 2017 at 5:20 PM, Rob Clark <robdcl...@gmail.com> wrote: > On Thu, Jul 13, 2017 at 1:35 AM, Sricharan R <sricha...@codeaurora.org> wrote: >> Hi Vivek, >> >> On 7/13/2017 10:43 AM, Vivek Gautam wrote: >>> Hi Stephen, >>> >>>

Re: [PATCH] iommu/arm-smmu: Defer TLB flush in case of unmap op

2017-08-07 Thread Vivek Gautam
Hi Robin, On Fri, Aug 4, 2017 at 10:34 PM, Robin Murphy <robin.mur...@arm.com> wrote: > On 03/08/17 06:35, Vivek Gautam wrote: >> Hi Robin, >> >> >> >> On 08/02/2017 05:47 PM, Robin Murphy wrote: >>> On 02/08/17 10:53, Vivek Gautam wrot

Re: [PATCH] iommu/arm-smmu: Defer TLB flush in case of unmap op

2017-08-02 Thread Vivek Gautam
Hi Robin, On 08/02/2017 05:47 PM, Robin Murphy wrote: On 02/08/17 10:53, Vivek Gautam wrote: We don't want to touch the TLB when smmu is suspended. Defer it until resume. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- Hi all, Here's the small patch in response of sugg

[PATCH] iommu/arm-smmu: Defer TLB flush in case of unmap op

2017-08-02 Thread Vivek Gautam
We don't want to touch the TLB when smmu is suspended. Defer it until resume. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- Hi all, Here's the small patch in response of suggestion to defer tlb operations when smmu is in suspend state. The patch stores the TLB requests in

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-07-24 Thread Vivek Gautam
l.dea...@arm.com> >>>>>>>>> wrote: >>>>>>>>>> On Thu, Jul 13, 2017 at 10:55:10AM -0400, Rob Clark wrote: >>>>>>>>>>> On Thu, Jul 13, 2017 at 9:53 AM, Sricharan R >>>>>>>>>&g

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-07-13 Thread Vivek Gautam
On Thu, Jul 13, 2017 at 7:27 PM, Vivek Gautam <vivek.gau...@codeaurora.org> wrote: > On Thu, Jul 13, 2017 at 11:05 AM, Sricharan R <sricha...@codeaurora.org> > wrote: >> Hi Vivek, >> >> On 7/13/2017 10:43 AM, Vivek Gautam wrote: >>> Hi Stephen, >

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-07-13 Thread Vivek Gautam
On Thu, Jul 13, 2017 at 11:05 AM, Sricharan R <sricha...@codeaurora.org> wrote: > Hi Vivek, > > On 7/13/2017 10:43 AM, Vivek Gautam wrote: >> Hi Stephen, >> >> >> On 07/13/2017 04:24 AM, Stephen Boyd wrote: >>> On 07/06, Vivek Gautam wrote: >

Re: [PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-07-12 Thread Vivek Gautam
Hi Stephen, On 07/13/2017 04:24 AM, Stephen Boyd wrote: On 07/06, Vivek Gautam wrote: @@ -1231,12 +1237,18 @@ static int arm_smmu_map(struct iommu_domain *domain, unsigned long iova, static size_t arm_smmu_unmap(struct iommu_domain *domain, unsigned long iova

Re: [PATCH V4 4/6] iommu/arm-smmu: Add the device_link between masters and smmu

2017-07-12 Thread Vivek Gautam
On 07/13/2017 04:25 AM, Stephen Boyd wrote: On 07/06, Vivek Gautam wrote: diff --git a/drivers/iommu/arm-smmu.c b/drivers/iommu/arm-smmu.c index ddbfa8ab69e6..75567d9698ab 100644 --- a/drivers/iommu/arm-smmu.c +++ b/drivers/iommu/arm-smmu.c @@ -1348,6 +1348,7 @@ static int arm_smmu_add_device

Re: [PATCH V4 2/6] iommu/arm-smmu: Add pm_runtime/sleep ops

2017-07-12 Thread Vivek Gautam
On 07/13/2017 04:31 AM, Stephen Boyd wrote: On 07/12, Stephen Boyd wrote: On 07/06, Vivek Gautam wrote: From: Sricharan R <sricha...@codeaurora.org> The smmu needs to be functional only when the respective master's using it are active. The device_link feature helps to track such func

Re: [PATCH V4 6/6] iommu/arm-smmu: Add support for qcom,msm8996-smmu-v2 clocks

2017-07-10 Thread Vivek Gautam
Hi Rob, On Mon, Jul 10, 2017 at 9:10 AM, Rob Herring <r...@kernel.org> wrote: > On Thu, Jul 06, 2017 at 03:07:05PM +0530, Vivek Gautam wrote: >> qcom,msm8996-smmu-v2 is an arm,smmu-v2 implementation with >> specific clock and power requirements. This smmu core is used >

[PATCH V4 6/6] iommu/arm-smmu: Add support for qcom, msm8996-smmu-v2 clocks

2017-07-06 Thread Vivek Gautam
qcom,msm8996-smmu-v2 is an arm,smmu-v2 implementation with specific clock and power requirements. This smmu core is used with multiple masters on msm8996, viz. mdss, video, etc. Add bindings for the same. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- Documentation/devi

[PATCH V4 5/6] iommu/arm-smmu: Add support for MMU40x/500 clocks

2017-07-06 Thread Vivek Gautam
lt;sricha...@codeaurora.org> [vivek: clock rework and cleanup] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- .../devicetree/bindings/iommu/arm,smmu.txt | 24 ++ drivers/iommu/arm-smmu.c | 12 ++- 2 files changed, 3

[PATCH V4 4/6] iommu/arm-smmu: Add the device_link between masters and smmu

2017-07-06 Thread Vivek Gautam
From: Sricharan R Finally add the device link between the master device and smmu, so that the smmu gets runtime enabled/disabled only when the master needs it. This is done from add_device callback which gets called once when the master is added to the smmu.

[PATCH V4 3/6] iommu/arm-smmu: Invoke pm_runtime during probe, add/remove device

2017-07-06 Thread Vivek Gautam
aran R <sricha...@codeaurora.org> [stanimir: added runtime pm in .unmap iommu op] Signed-off-by: Stanimir Varbanov <stanimir.varba...@linaro.org> [vivek: Cleanup pm runtime calls] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drive

[PATCH V4 2/6] iommu/arm-smmu: Add pm_runtime/sleep ops

2017-07-06 Thread Vivek Gautam
; Signed-off-by: Archit Taneja <arch...@codeaurora.org> [vivek: Clock rework to loop over clock names data] Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drivers/iommu/arm-smmu.c | 95 +++- 1 file changed, 94 insertions(+), 1

[PATCH V4 1/6] iommu/arm-smmu: Fix the error path in arm_smmu_add_device

2017-07-06 Thread Vivek Gautam
fwspec->iommu_priv is available only after arm_smmu_master_cfg instance has been allocated. We shouldn't free it before that. Also it's logical to free the master cfg itself without checking for fwspec. Signed-off-by: Vivek Gautam <vivek.gau...@codeaurora.org> --- drivers/iommu/arm-s

[PATCH V4 0/6] iommu/arm-smmu: Add runtime pm/sleep support

2017-07-06 Thread Vivek Gautam
device iommu/arm-smmu: Add the device_link between masters and smmu iommu/arm-smmu: Add support for MMU40x/500 clocks Vivek Gautam (2): iommu/arm-smmu: Fix the error path in arm_smmu_add_device iommu/arm-smmu: Add support for qcom,msm8996-smmu-v2 clocks .../devicetree/bindings/iommu/arm

<    1   2   3   4