Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: robert.richter@cavium.com (Robert Richter)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 0/3] Cavium ThunderX2 SMMUv3 errata workarounds
Date: Thu, 27 Apr 2017 15:39:10 +0200	[thread overview]
Message-ID: <20170427133910.GB31368@rric.localdomain> (raw)
In-Reply-To: <1493293584-20287-1-git-send-email-gakula@caviumnetworks.com>

On 27.04.17 17:16:21, Geetha sowjanya wrote:
> From: Geetha <gakula@cavium.com>
> 
> Cavium CN99xx SMMUv3 implementation has two Silicon Erratas.
> 1. Errata ID #74
>    SMMU register alias Page 1 is not implemented
> 2. Errata ID #126
>    SMMU doesnt support unique IRQ lines for gerror, eventq and cmdq-sync
> 
> The following patchset does software workaround for these two erratas.
> 
> This series is based on RFC patch.  
> https://www.spinics.net/lists/arm-kernel/msg575739.html
> 
> As suggested by Will Deacon, code is modified to use silicon id to
> enable errata#74 workaround.

Can we go with the previous series [1] and:

 * drop the iort model numbering part,

 * add an enablement function that enables flags (smmu->options)
   depending on midr values (which replaces the macro code)?

E.g.:

static void acpi_smmu_enable_cavium(struct arm_smmu_device *smmu)
{
	u32 cpu_model;

	if (!IS_ENABLED(CONFIG_ARM64))
		return;

	cpu_model = read_cpuid_id() & MIDR_CPU_MODEL_MASK;
	switch (cpu_model) {
	case ...:
	case ...:
		break;
	default:
		/* No Cavium CN99xx SMMU v3 */
		return;
	}

	smmu->options |= (ARM_SMMU_OPT_PAGE0_REGS_ONLY |
		      	 ARM_SMMU_OPT_USE_SHARED_IRQS);
}

-Robert


[1] [RFC PATCH 0/7] Cavium CN99xx SMMUv3 Errata workarounds
    https://marc.info/?l=linux-acpi&m=149192179623708&w=2

> 
> Linu Cherian (1):
>   iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #74
> 
> Geetha (2):
>   arm64: Add MIDR values for Cavium cn99xx SoCs
>   iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #126
> 
>  Documentation/arm64/silicon-errata.txt |  2 ++
>  arch/arm64/include/asm/cputype.h       |  3 ++
>  drivers/acpi/arm64/iort.c              | 14 +++++++-
>  drivers/iommu/arm-smmu-v3.c            | 64 +++++++++++++++++++++++++++++-----
>  4 files changed, 73 insertions(+), 10 deletions(-)
> 
> -- 
> 1.9.1
> 

  parent reply	other threads:[~2017-04-27 13:39 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-27 11:46 [PATCH 0/3] Cavium ThunderX2 SMMUv3 errata workarounds Geetha sowjanya
2017-04-27 11:46 ` [PATCH 1/3] arm64: Add MIDR values for Cavium cn99xx SoCs Geetha sowjanya
2017-04-27 13:01   ` Jayachandran C.
2017-04-27 11:46 ` [PATCH 2/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #74 Geetha sowjanya
2017-04-27 16:42   ` Mark Rutland
2017-04-27 17:00     ` Will Deacon
2017-05-02  6:31       ` Geetha Akula
2017-05-03  9:47         ` Will Deacon
2017-05-03 10:32           ` Geetha Akula
2017-05-04 23:36           ` Jon Masters
2017-04-27 11:46 ` [PATCH 3/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 Geetha sowjanya
2017-04-27 13:39 ` Robert Richter [this message]
2017-04-27 16:37   ` [PATCH 0/3] Cavium ThunderX2 SMMUv3 errata workarounds Sunil Kovvuri

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=20170427133910.GB31368@rric.localdomain \
    --to=robert.richter@cavium.com \
    --cc=linux-arm-kernel@lists.infradead.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