linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: shc_work@mail.ru (Alexander Shiyan)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 04/17] ARM clps711x: Using a single definition for virtual address register
Date: Sat, 21 Apr 2012 13:11:17 +0400	[thread overview]
Message-ID: <1334999490-27177-5-git-send-email-shc_work@mail.ru> (raw)
In-Reply-To: <1334999490-27177-1-git-send-email-shc_work@mail.ru>

Using a single definition for the virtual address register for all
variants boards clps711x.

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
 arch/arm/include/asm/hardware/ep7211.h         |    5 -----
 arch/arm/include/asm/hardware/ep7212.h         |    9 ++-------
 arch/arm/mach-clps711x/include/mach/hardware.h |   10 ----------
 drivers/mtd/nand/autcpu12.c                    |    4 ++--
 4 files changed, 4 insertions(+), 24 deletions(-)

diff --git a/arch/arm/include/asm/hardware/ep7211.h b/arch/arm/include/asm/hardware/ep7211.h
index 654d5f6..ca4d198 100644
--- a/arch/arm/include/asm/hardware/ep7211.h
+++ b/arch/arm/include/asm/hardware/ep7211.h
@@ -25,11 +25,6 @@
 
 #include <asm/hardware/clps7111.h>
 
-/*
- * define EP7211_BASE to be the base address of the region
- * you want to access.
- */
-
 #define EP7211_PHYS_BASE	(0x80000000)
 
 /*
diff --git a/arch/arm/include/asm/hardware/ep7212.h b/arch/arm/include/asm/hardware/ep7212.h
index 3b43bbe..0b1f508 100644
--- a/arch/arm/include/asm/hardware/ep7212.h
+++ b/arch/arm/include/asm/hardware/ep7212.h
@@ -23,16 +23,11 @@
 #ifndef __ASM_HARDWARE_EP7212_H
 #define __ASM_HARDWARE_EP7212_H
 
-/*
- * define EP7212_BASE to be the base address of the region
- * you want to access.
- */
-
 #define EP7212_PHYS_BASE	(0x80000000)
 
 #ifndef __ASSEMBLY__
-#define ep_readl(off)		__raw_readl(EP7212_BASE + (off))
-#define ep_writel(val,off)	__raw_writel(val, EP7212_BASE + (off))
+#define ep_readl(off)		__raw_readl(CLPS7111_BASE + (off))
+#define ep_writel(val,off)	__raw_writel(val, CLPS7111_BASE + (off))
 #endif
 
 /*
diff --git a/arch/arm/mach-clps711x/include/mach/hardware.h b/arch/arm/mach-clps711x/include/mach/hardware.h
index 2ff3473..8c7b28e 100644
--- a/arch/arm/mach-clps711x/include/mach/hardware.h
+++ b/arch/arm/mach-clps711x/include/mach/hardware.h
@@ -54,14 +54,10 @@
 
 #if defined (CONFIG_SOC_EP7211)
 
-#define EP7211_VIRT_BASE	CLPS7111_VIRT_BASE
-#define EP7211_BASE		CLPS7111_VIRT_BASE
 #include <asm/hardware/ep7211.h>
 
 #elif defined (CONFIG_SOC_EP7212)
 
-#define EP7212_VIRT_BASE	CLPS7111_VIRT_BASE
-#define EP7212_BASE		CLPS7111_VIRT_BASE
 #include <asm/hardware/ep7212.h>
 
 #elif defined (CONFIG_SOC_EP7213)
@@ -75,9 +71,6 @@
 
 #if  defined (CONFIG_ARCH_AUTCPU12)
 
-#define  CS89712_VIRT_BASE	CLPS7111_VIRT_BASE
-#define  CS89712_BASE		CLPS7111_VIRT_BASE
-
 #include <asm/hardware/clps7111.h>
 #include <asm/hardware/ep7212.h>
 #include <asm/hardware/cs89712.h>
@@ -158,9 +151,6 @@
 
 #if defined (CONFIG_ARCH_CEIVA)
 
-#define  CEIVA_VIRT_BASE	CLPS7111_VIRT_BASE
-#define  CEIVA_BASE		CLPS7111_VIRT_BASE
-
 #include <asm/hardware/clps7111.h>
 #include <asm/hardware/ep7212.h>
 
diff --git a/drivers/mtd/nand/autcpu12.c b/drivers/mtd/nand/autcpu12.c
index 2e42ec2..5bd4107 100644
--- a/drivers/mtd/nand/autcpu12.c
+++ b/drivers/mtd/nand/autcpu12.c
@@ -102,7 +102,7 @@ static void autcpu12_hwcontrol(struct mtd_info *mtd, int cmd,
 		void __iomem *addr;
 		unsigned char bits;
 
-		addr = CS89712_VIRT_BASE + AUTCPU12_SMC_PORT_OFFSET;
+		addr = CLPS7111_VIRT_BASE + AUTCPU12_SMC_PORT_OFFSET;
 		bits = (ctrl & NAND_CLE) << 4;
 		bits |= (ctrl & NAND_ALE) << 2;
 		writeb((readb(addr) & ~0x30) | bits, addr);
@@ -120,7 +120,7 @@ static void autcpu12_hwcontrol(struct mtd_info *mtd, int cmd,
  */
 int autcpu12_device_ready(struct mtd_info *mtd)
 {
-	void __iomem *addr = CS89712_VIRT_BASE + AUTCPU12_SMC_PORT_OFFSET;
+	void __iomem *addr = CLPS7111_VIRT_BASE + AUTCPU12_SMC_PORT_OFFSET;
 
 	return readb(addr) & AUTCPU12_SMC_RDY;
 }
-- 
1.7.3.4

  parent reply	other threads:[~2012-04-21  9:11 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-21  9:11 clps711x patchset Alexander Shiyan
2012-04-21  9:11 ` [PATCH 01/17] ARM clps711x: Cleanup: Rename ARCH_EP7211 and ARCH_EP7212 to SOC_xxx Alexander Shiyan
2012-04-21  9:11 ` [PATCH 02/17] ARM clps711x: Added Cirrus Logic EP7312 CPU variant Alexander Shiyan
2012-04-21 11:21   ` Arnd Bergmann
2012-04-21 11:30     ` Re[2]: " Alexander Shiyan
2012-04-21 11:48     ` Russell King - ARM Linux
2012-04-21 12:11       ` Arnd Bergmann
2012-04-21 12:20         ` Russell King - ARM Linux
2012-04-22 13:58           ` Arnd Bergmann
2012-04-22 14:13             ` Russell King - ARM Linux
2012-04-22 14:24             ` Re[2]: " Alexander Shiyan
2012-04-21  9:11 ` [PATCH 03/17] ARM clps711x: Selecting CPU-variant automatically for clps711x targets Alexander Shiyan
2012-04-21  9:11 ` Alexander Shiyan [this message]
2012-04-21  9:11 ` [PATCH 05/17] ARM clps711x: Added missing definitions for PORT C Alexander Shiyan
2012-04-21  9:11 ` [PATCH 06/17] ARM clps711x: Remove now unused cs89712 board header Alexander Shiyan
2012-04-21  9:11 ` [PATCH 07/17] ARM clps711x: Remove unused includes Alexander Shiyan
2012-04-21  9:11 ` [PATCH 08/17] ARM clps711x: Cleanup: remove unused definitions for ep_readl/ep_writel Alexander Shiyan
2012-04-21  9:11 ` [PATCH 09/17] ARM clps711x: Using a single definition for physical address register Alexander Shiyan
2012-04-21  9:11 ` [PATCH 10/17] ARM clps711x: Address register renaming to reflect the fact that the name is the same for all arch Alexander Shiyan
2012-04-21  9:11 ` [PATCH 11/17] ARM clps711x: Move definitions of register address in one unit Alexander Shiyan
2012-04-21  9:11 ` [PATCH 12/17] ARM clps711x: Simple optimise debug_macro by removing one NOP Alexander Shiyan
2012-04-21 10:46   ` Russell King - ARM Linux
2012-04-21 10:50     ` Re[2]: " Alexander Shiyan
2012-04-21 11:18   ` Arnd Bergmann
2012-04-21 11:49     ` Arnd Bergmann
2012-04-21  9:11 ` [PATCH 13/17] ARM clps711x: Removed unused header mach/time.h Alexander Shiyan
2012-04-21  9:11 ` [PATCH 14/17] ARM clps711x: Do not mask interrupts in ack procedure Alexander Shiyan
2012-04-21  9:11 ` [PATCH 15/17] ARM clps711x: Removed unused definitions from mach/irqs.h Alexander Shiyan
2012-04-21  9:11 ` [PATCH 16/17] ARM clps711x: Replaced frequency settings to definition Alexander Shiyan
2012-04-21  9:11 ` [PATCH 17/17] ARM clps711x: Make select CPU spees as KConfig option Alexander Shiyan
2012-04-21 11:40 ` clps711x patchset Arnd Bergmann
2012-04-21 12:04   ` Re[2]: " Alexander Shiyan
2012-04-21 12:14     ` Arnd Bergmann

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=1334999490-27177-5-git-send-email-shc_work@mail.ru \
    --to=shc_work@mail.ru \
    --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;
as well as URLs for NNTP newsgroup(s).