All of lore.kernel.org
 help / color / mirror / Atom feed
From: Robert Richter <robert.richter-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>
To: Geetha Akula
	<geethasowjanya.akula-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Rob Herring <robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	devel-E0kO6a4B6psdnm+yROfE0A@public.gmane.org,
	Catalin Marinas <catalin.marinas-5wv7dgnIgG8@public.gmane.org>,
	Linu Cherian
	<linu.cherian-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>,
	"Rafael J. Wysocki" <rjw-LthD3rsA81gm4RdzfppkhA@public.gmane.org>,
	jcm-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	Geetha sowjanya
	<gakula-M3mlKVOIwJVv6pq1l3V1OdBPR1lH4CV8@public.gmane.org>,
	Will Deacon <will.deacon-5wv7dgnIgG8@public.gmane.org>,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Geetha Sowjanya
	<geethasowjanya.akula-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>,
	Linux IOMMU
	<iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org>,
	Sudeep Holla <sudeep.holla-5wv7dgnIgG8@public.gmane.org>,
	Sunil Goutham <sgoutham-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>,
	linux-acpi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	Charles Garcia-Tobin
	<Charles.Garcia-Tobin-5wv7dgnIgG8@public.gmane.org>
Subject: Re: [Devel] [RESEND PATCH v9 3/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #126
Date: Tue, 27 Jun 2017 17:18:01 +0200	[thread overview]
Message-ID: <20170627151801.GT31368@rric.localdomain> (raw)
In-Reply-To: <CANHdaibSGtbdQfZ2kv1E9t4eE+JY2wtsDP7=rEw-mj059yhyHA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

On 27.06.17 20:28:14, Geetha Akula wrote:
> On Tue, Jun 27, 2017 at 7:36 PM, Will Deacon <will.deacon-5wv7dgnIgG8@public.gmane.org> wrote:
> > On Tue, Jun 27, 2017 at 03:56:10PM +0200, Robert Richter wrote:
> >> On 23.06.17 19:04:36, Geetha sowjanya wrote:
> >> > From: Geetha Sowjanya <geethasowjanya.akula-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org>
> >> >
> >> > Cavium ThunderX2 SMMU doesn't support MSI and also doesn't have unique irq
> >> > lines for gerror, eventq and cmdq-sync.
> >> >
> >> > New named irq "combined" is set as a errata workaround, which allows to
> >> > share the irq line by register single irq handler for all the interrupts.
> >> >
> >> > Signed-off-by: Geetha sowjanya <gakula-M3mlKVOIwJVv6pq1l3V1OdBPR1lH4CV8@public.gmane.org>
> >> > ---
> >> >  Documentation/arm64/silicon-errata.txt             |    1 +
> >> >  .../devicetree/bindings/iommu/arm,smmu-v3.txt      |    6 +
> >> >  drivers/acpi/arm64/iort.c                          |   57 ++++++++---
> >> >  drivers/iommu/arm-smmu-v3.c                        |  100 ++++++++++++++-----
> >> >  4 files changed, 121 insertions(+), 43 deletions(-)
> >>
> >> > +static int arm_smmu_setup_irqs(struct arm_smmu_device *smmu)
> >> > +{
> >> > +   int ret, irq;
> >> > +   u32 irqen_flags = IRQ_CTRL_EVTQ_IRQEN | IRQ_CTRL_GERROR_IRQEN;
> >> > +
> >> > +   /* Disable IRQs first */
> >> > +   ret = arm_smmu_write_reg_sync(smmu, 0, ARM_SMMU_IRQ_CTRL,
> >> > +                                 ARM_SMMU_IRQ_CTRLACK);
> >> > +   if (ret) {
> >> > +           dev_err(smmu->dev, "failed to disable irqs\n");
> >> > +           return ret;
> >> > +   }
> >> > +
> >> > +   irq = smmu->combined_irq;
> >> > +   if (irq) {
> >> > +           /*
> >> > +            * Cavium ThunderX2 implementation doesn't not support unique
> >> > +            * irq lines. Use single irq line for all the SMMUv3 interrupts.
> >> > +            */
> >> > +           ret = devm_request_threaded_irq(smmu->dev, irq,
> >> > +                                   arm_smmu_combined_irq_handler,
> >> > +                                   arm_smmu_combined_irq_thread,
> >> > +                                   IRQF_ONESHOT,
> >>
> >> Without the IRQF_SHARED flag set I see the following on a dual node
> >> system now:
> Node1 SMMU interrupts are programmed wrong in the firmware.
> Node 0 and Node1 SMMU do not share interrupts.
> I have verified the patch on dual node with correct interrupt numbers
> programmed in firmware.

Ah, ok, will update to latest fw.

Thanks,

-Robert

WARNING: multiple messages have this Message-ID (diff)
From: Robert Richter <robert.richter@cavium.com>
To: Geetha Akula <geethasowjanya.akula@gmail.com>
Cc: Will Deacon <will.deacon@arm.com>,
	Geetha sowjanya <gakula@caviumnetworks.com>,
	Robin Murphy <robin.murphy@arm.com>,
	Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,
	Hanjun Guo <hanjun.guo@linaro.org>,
	Sudeep Holla <sudeep.holla@arm.com>,
	Linux IOMMU <iommu@lists.linux-foundation.org>,
	Rob Herring <robh@kernel.org>,
	Charles Garcia-Tobin <Charles.Garcia-Tobin@arm.com>,
	Geetha Sowjanya <geethasowjanya.akula@cavium.com>,
	jcm@redhat.com, Linu Cherian <linu.cherian@cavium.com>,
	"Rafael J. Wysocki" <rjw@rjwysocki.net>,
	linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org,
	Catalin Marinas <catalin.marinas@arm.com>,
	Sunil Goutham <sgoutham@cavium.com>,
	linux-arm-kernel@lists.infradead.org, devel@acpica.org
Subject: Re: [Devel] [RESEND PATCH v9 3/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #126
Date: Tue, 27 Jun 2017 17:18:01 +0200	[thread overview]
Message-ID: <20170627151801.GT31368@rric.localdomain> (raw)
In-Reply-To: <CANHdaibSGtbdQfZ2kv1E9t4eE+JY2wtsDP7=rEw-mj059yhyHA@mail.gmail.com>

On 27.06.17 20:28:14, Geetha Akula wrote:
> On Tue, Jun 27, 2017 at 7:36 PM, Will Deacon <will.deacon@arm.com> wrote:
> > On Tue, Jun 27, 2017 at 03:56:10PM +0200, Robert Richter wrote:
> >> On 23.06.17 19:04:36, Geetha sowjanya wrote:
> >> > From: Geetha Sowjanya <geethasowjanya.akula@cavium.com>
> >> >
> >> > Cavium ThunderX2 SMMU doesn't support MSI and also doesn't have unique irq
> >> > lines for gerror, eventq and cmdq-sync.
> >> >
> >> > New named irq "combined" is set as a errata workaround, which allows to
> >> > share the irq line by register single irq handler for all the interrupts.
> >> >
> >> > Signed-off-by: Geetha sowjanya <gakula@caviumnetworks.com>
> >> > ---
> >> >  Documentation/arm64/silicon-errata.txt             |    1 +
> >> >  .../devicetree/bindings/iommu/arm,smmu-v3.txt      |    6 +
> >> >  drivers/acpi/arm64/iort.c                          |   57 ++++++++---
> >> >  drivers/iommu/arm-smmu-v3.c                        |  100 ++++++++++++++-----
> >> >  4 files changed, 121 insertions(+), 43 deletions(-)
> >>
> >> > +static int arm_smmu_setup_irqs(struct arm_smmu_device *smmu)
> >> > +{
> >> > +   int ret, irq;
> >> > +   u32 irqen_flags = IRQ_CTRL_EVTQ_IRQEN | IRQ_CTRL_GERROR_IRQEN;
> >> > +
> >> > +   /* Disable IRQs first */
> >> > +   ret = arm_smmu_write_reg_sync(smmu, 0, ARM_SMMU_IRQ_CTRL,
> >> > +                                 ARM_SMMU_IRQ_CTRLACK);
> >> > +   if (ret) {
> >> > +           dev_err(smmu->dev, "failed to disable irqs\n");
> >> > +           return ret;
> >> > +   }
> >> > +
> >> > +   irq = smmu->combined_irq;
> >> > +   if (irq) {
> >> > +           /*
> >> > +            * Cavium ThunderX2 implementation doesn't not support unique
> >> > +            * irq lines. Use single irq line for all the SMMUv3 interrupts.
> >> > +            */
> >> > +           ret = devm_request_threaded_irq(smmu->dev, irq,
> >> > +                                   arm_smmu_combined_irq_handler,
> >> > +                                   arm_smmu_combined_irq_thread,
> >> > +                                   IRQF_ONESHOT,
> >>
> >> Without the IRQF_SHARED flag set I see the following on a dual node
> >> system now:
> Node1 SMMU interrupts are programmed wrong in the firmware.
> Node 0 and Node1 SMMU do not share interrupts.
> I have verified the patch on dual node with correct interrupt numbers
> programmed in firmware.

Ah, ok, will update to latest fw.

Thanks,

-Robert

WARNING: multiple messages have this Message-ID (diff)
From: robert.richter@cavium.com (Robert Richter)
To: linux-arm-kernel@lists.infradead.org
Subject: [Devel] [RESEND PATCH v9 3/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #126
Date: Tue, 27 Jun 2017 17:18:01 +0200	[thread overview]
Message-ID: <20170627151801.GT31368@rric.localdomain> (raw)
In-Reply-To: <CANHdaibSGtbdQfZ2kv1E9t4eE+JY2wtsDP7=rEw-mj059yhyHA@mail.gmail.com>

On 27.06.17 20:28:14, Geetha Akula wrote:
> On Tue, Jun 27, 2017 at 7:36 PM, Will Deacon <will.deacon@arm.com> wrote:
> > On Tue, Jun 27, 2017 at 03:56:10PM +0200, Robert Richter wrote:
> >> On 23.06.17 19:04:36, Geetha sowjanya wrote:
> >> > From: Geetha Sowjanya <geethasowjanya.akula@cavium.com>
> >> >
> >> > Cavium ThunderX2 SMMU doesn't support MSI and also doesn't have unique irq
> >> > lines for gerror, eventq and cmdq-sync.
> >> >
> >> > New named irq "combined" is set as a errata workaround, which allows to
> >> > share the irq line by register single irq handler for all the interrupts.
> >> >
> >> > Signed-off-by: Geetha sowjanya <gakula@caviumnetworks.com>
> >> > ---
> >> >  Documentation/arm64/silicon-errata.txt             |    1 +
> >> >  .../devicetree/bindings/iommu/arm,smmu-v3.txt      |    6 +
> >> >  drivers/acpi/arm64/iort.c                          |   57 ++++++++---
> >> >  drivers/iommu/arm-smmu-v3.c                        |  100 ++++++++++++++-----
> >> >  4 files changed, 121 insertions(+), 43 deletions(-)
> >>
> >> > +static int arm_smmu_setup_irqs(struct arm_smmu_device *smmu)
> >> > +{
> >> > +   int ret, irq;
> >> > +   u32 irqen_flags = IRQ_CTRL_EVTQ_IRQEN | IRQ_CTRL_GERROR_IRQEN;
> >> > +
> >> > +   /* Disable IRQs first */
> >> > +   ret = arm_smmu_write_reg_sync(smmu, 0, ARM_SMMU_IRQ_CTRL,
> >> > +                                 ARM_SMMU_IRQ_CTRLACK);
> >> > +   if (ret) {
> >> > +           dev_err(smmu->dev, "failed to disable irqs\n");
> >> > +           return ret;
> >> > +   }
> >> > +
> >> > +   irq = smmu->combined_irq;
> >> > +   if (irq) {
> >> > +           /*
> >> > +            * Cavium ThunderX2 implementation doesn't not support unique
> >> > +            * irq lines. Use single irq line for all the SMMUv3 interrupts.
> >> > +            */
> >> > +           ret = devm_request_threaded_irq(smmu->dev, irq,
> >> > +                                   arm_smmu_combined_irq_handler,
> >> > +                                   arm_smmu_combined_irq_thread,
> >> > +                                   IRQF_ONESHOT,
> >>
> >> Without the IRQF_SHARED flag set I see the following on a dual node
> >> system now:
> Node1 SMMU interrupts are programmed wrong in the firmware.
> Node 0 and Node1 SMMU do not share interrupts.
> I have verified the patch on dual node with correct interrupt numbers
> programmed in firmware.

Ah, ok, will update to latest fw.

Thanks,

-Robert

WARNING: multiple messages have this Message-ID (diff)
From: Robert Richter <robert.richter at cavium.com>
To: devel@acpica.org
Subject: Re: [Devel] [RESEND PATCH v9 3/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #126
Date: Tue, 27 Jun 2017 17:18:01 +0200	[thread overview]
Message-ID: <20170627151801.GT31368@rric.localdomain> (raw)
In-Reply-To: CANHdaibSGtbdQfZ2kv1E9t4eE+JY2wtsDP7=rEw-mj059yhyHA@mail.gmail.com

[-- Attachment #1: Type: text/plain, Size: 2508 bytes --]

On 27.06.17 20:28:14, Geetha Akula wrote:
> On Tue, Jun 27, 2017 at 7:36 PM, Will Deacon <will.deacon(a)arm.com> wrote:
> > On Tue, Jun 27, 2017 at 03:56:10PM +0200, Robert Richter wrote:
> >> On 23.06.17 19:04:36, Geetha sowjanya wrote:
> >> > From: Geetha Sowjanya <geethasowjanya.akula(a)cavium.com>
> >> >
> >> > Cavium ThunderX2 SMMU doesn't support MSI and also doesn't have unique irq
> >> > lines for gerror, eventq and cmdq-sync.
> >> >
> >> > New named irq "combined" is set as a errata workaround, which allows to
> >> > share the irq line by register single irq handler for all the interrupts.
> >> >
> >> > Signed-off-by: Geetha sowjanya <gakula(a)caviumnetworks.com>
> >> > ---
> >> >  Documentation/arm64/silicon-errata.txt             |    1 +
> >> >  .../devicetree/bindings/iommu/arm,smmu-v3.txt      |    6 +
> >> >  drivers/acpi/arm64/iort.c                          |   57 ++++++++---
> >> >  drivers/iommu/arm-smmu-v3.c                        |  100 ++++++++++++++-----
> >> >  4 files changed, 121 insertions(+), 43 deletions(-)
> >>
> >> > +static int arm_smmu_setup_irqs(struct arm_smmu_device *smmu)
> >> > +{
> >> > +   int ret, irq;
> >> > +   u32 irqen_flags = IRQ_CTRL_EVTQ_IRQEN | IRQ_CTRL_GERROR_IRQEN;
> >> > +
> >> > +   /* Disable IRQs first */
> >> > +   ret = arm_smmu_write_reg_sync(smmu, 0, ARM_SMMU_IRQ_CTRL,
> >> > +                                 ARM_SMMU_IRQ_CTRLACK);
> >> > +   if (ret) {
> >> > +           dev_err(smmu->dev, "failed to disable irqs\n");
> >> > +           return ret;
> >> > +   }
> >> > +
> >> > +   irq = smmu->combined_irq;
> >> > +   if (irq) {
> >> > +           /*
> >> > +            * Cavium ThunderX2 implementation doesn't not support unique
> >> > +            * irq lines. Use single irq line for all the SMMUv3 interrupts.
> >> > +            */
> >> > +           ret = devm_request_threaded_irq(smmu->dev, irq,
> >> > +                                   arm_smmu_combined_irq_handler,
> >> > +                                   arm_smmu_combined_irq_thread,
> >> > +                                   IRQF_ONESHOT,
> >>
> >> Without the IRQF_SHARED flag set I see the following on a dual node
> >> system now:
> Node1 SMMU interrupts are programmed wrong in the firmware.
> Node 0 and Node1 SMMU do not share interrupts.
> I have verified the patch on dual node with correct interrupt numbers
> programmed in firmware.

Ah, ok, will update to latest fw.

Thanks,

-Robert

  parent reply	other threads:[~2017-06-27 15:18 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-23 13:34 [RESEND PATCH v9 3/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #126 Geetha sowjanya
2017-06-23 13:34 ` [Devel] " Geetha sowjanya
2017-06-23 13:34 ` Geetha sowjanya
     [not found] ` <1498224876-5200-1-git-send-email-gakula-M3mlKVOIwJVv6pq1l3V1OdBPR1lH4CV8@public.gmane.org>
2017-06-27 13:56   ` [Devel] " Robert Richter
2017-06-27 13:56     ` Robert Richter
2017-06-27 13:56     ` Robert Richter
2017-06-27 13:56     ` Robert Richter
2017-06-27 14:06     ` Will Deacon
2017-06-27 14:06       ` Will Deacon
2017-06-27 14:06       ` Will Deacon
     [not found]       ` <20170627140559.GK14041-5wv7dgnIgG8@public.gmane.org>
2017-06-27 14:58         ` Geetha Akula
2017-06-27 14:58           ` Geetha Akula
2017-06-27 14:58           ` Geetha Akula
2017-06-27 14:58           ` Geetha Akula
     [not found]           ` <CANHdaibSGtbdQfZ2kv1E9t4eE+JY2wtsDP7=rEw-mj059yhyHA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-06-27 15:18             ` Robert Richter [this message]
2017-06-27 15:18               ` Robert Richter
2017-06-27 15:18               ` Robert Richter
2017-06-27 15:18               ` Robert Richter

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=20170627151801.GT31368@rric.localdomain \
    --to=robert.richter-ygcgfspz5w/qt0dzr+alfa@public.gmane.org \
    --cc=Charles.Garcia-Tobin-5wv7dgnIgG8@public.gmane.org \
    --cc=catalin.marinas-5wv7dgnIgG8@public.gmane.org \
    --cc=devel-E0kO6a4B6psdnm+yROfE0A@public.gmane.org \
    --cc=gakula-M3mlKVOIwJVv6pq1l3V1OdBPR1lH4CV8@public.gmane.org \
    --cc=geethasowjanya.akula-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=geethasowjanya.akula-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=jcm-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=linu.cherian-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org \
    --cc=linux-acpi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=rjw-LthD3rsA81gm4RdzfppkhA@public.gmane.org \
    --cc=robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=sgoutham-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org \
    --cc=sudeep.holla-5wv7dgnIgG8@public.gmane.org \
    --cc=will.deacon-5wv7dgnIgG8@public.gmane.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 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.