linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: PL330: Accept revisions of the dmac
@ 2010-09-03  8:30 Jassi Brar
  2010-09-03 22:43 ` Kukjin Kim
  2010-09-05  9:14 ` Linus Walleij
  0 siblings, 2 replies; 9+ messages in thread
From: Jassi Brar @ 2010-09-03  8:30 UTC (permalink / raw)
  To: linux-arm-kernel

From: Jassi Brar <jassi.brar@samsung.com>

The driver can handle different revisions of the core which
vary only minorly. So check for only the necessary part of
the IDs.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
---
 arch/arm/common/pl330.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/arch/arm/common/pl330.c b/arch/arm/common/pl330.c
index 5ebbab6..8f0f86d 100644
--- a/arch/arm/common/pl330.c
+++ b/arch/arm/common/pl330.c
@@ -146,8 +146,7 @@
 #define DESIGNER	0x41
 #define REVISION	0x0
 #define INTEG_CFG	0x0
-#define PERIPH_ID_VAL	((PART << 0) | (DESIGNER << 12) \
-			  | (REVISION << 20) | (INTEG_CFG << 24))
+#define PERIPH_ID_VAL	((PART << 0) | (DESIGNER << 12))
 
 #define PCELL_ID_VAL	0xb105f00d
 
@@ -1859,10 +1858,10 @@ int pl330_add(struct pl330_info *pi)
 	regs = pi->base;
 
 	/* Check if we can handle this DMAC */
-	if (get_id(pi, PERIPH_ID) != PERIPH_ID_VAL
+	if ((get_id(pi, PERIPH_ID) & 0xfffff) != PERIPH_ID_VAL
 	   || get_id(pi, PCELL_ID) != PCELL_ID_VAL) {
 		dev_err(pi->dev, "PERIPH_ID 0x%x, PCELL_ID 0x%x !\n",
-			readl(regs + PERIPH_ID), readl(regs + PCELL_ID));
+			get_id(pi, PERIPH_ID), get_id(pi, PCELL_ID));
 		return -EINVAL;
 	}
 
-- 
1.6.2.5

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2010-10-05 12:31 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-03  8:30 [PATCH] ARM: PL330: Accept revisions of the dmac Jassi Brar
2010-09-03 22:43 ` Kukjin Kim
2010-09-04  1:32   ` Jassi Brar
2010-09-05  9:14 ` Linus Walleij
2010-09-05  9:53   ` Jassi Brar
2010-09-06  8:35     ` Linus Walleij
2010-09-06 23:27       ` Jassi Brar
2010-09-07 21:39         ` Linus Walleij
2010-10-05 12:31           ` Linus Walleij

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).