Skip to content

Commit

Permalink
[ARM] cdb89712,clps7500,h720x: avoid namespace clash for FLASH_* cons…
Browse files Browse the repository at this point in the history
…tants

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King authored and Russell King committed Nov 13, 2008
1 parent 1e8b041 commit d9a682a
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 17 deletions.
4 changes: 0 additions & 4 deletions arch/arm/mach-clps711x/include/mach/hardware.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,6 @@
#include <asm/hardware/cs89712.h>

/* dynamic ioremap() areas */
#define FLASH_START 0x00000000
#define FLASH_SIZE 0x800000
#define FLASH_WIDTH 4

#define SRAM_START 0x60000000
#define SRAM_SIZE 0xc000
#define SRAM_WIDTH 4
Expand Down
6 changes: 3 additions & 3 deletions arch/arm/mach-clps7500/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,9 @@ static struct map_desc cl7500_io_desc[] __initdata = {
.length = ISA_SIZE,
.type = MT_DEVICE
}, { /* Flash */
.virtual = FLASH_BASE,
.pfn = __phys_to_pfn(FLASH_START),
.length = FLASH_SIZE,
.virtual = CLPS7500_FLASH_BASE,
.pfn = __phys_to_pfn(CLPS7500_FLASH_START),
.length = CLPS7500_FLASH_SIZE,
.type = MT_DEVICE
}, { /* LED */
.virtual = LED_BASE,
Expand Down
6 changes: 3 additions & 3 deletions arch/arm/mach-clps7500/include/mach/hardware.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@
#define ISA_SIZE 0x00010000
#define ISA_BASE 0xe1000000

#define FLASH_START 0x01000000 /* XXX */
#define FLASH_SIZE 0x01000000
#define FLASH_BASE 0xe2000000
#define CLPS7500_FLASH_START 0x01000000 /* XXX */
#define CLPS7500_FLASH_SIZE 0x01000000
#define CLPS7500_FLASH_BASE 0xe2000000

#define LED_START 0x0302B000
#define LED_SIZE 0x00001000
Expand Down
6 changes: 3 additions & 3 deletions arch/arm/mach-h720x/include/mach/boards.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
#ifdef CONFIG_ARCH_H7202

/* FLASH */
#define FLASH_VIRT 0xd0000000
#define FLASH_PHYS 0x00000000
#define FLASH_SIZE 0x02000000
#define H720X_FLASH_VIRT 0xd0000000
#define H720X_FLASH_PHYS 0x00000000
#define H720X_FLASH_SIZE 0x02000000

/* onboard LAN controller */
# define ETH0_PHYS 0x08000000
Expand Down
4 changes: 3 additions & 1 deletion drivers/mtd/maps/cdb89712.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
#include <linux/mtd/partitions.h>



#define FLASH_START 0x00000000
#define FLASH_SIZE 0x800000
#define FLASH_WIDTH 4

static struct mtd_info *flash_mtd;

Expand Down
6 changes: 3 additions & 3 deletions drivers/mtd/maps/h720x-flash.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ static struct mtd_info *mymtd;
static struct map_info h720x_map = {
.name = "H720X",
.bankwidth = 4,
.size = FLASH_SIZE,
.phys = FLASH_PHYS,
.size = H720X_FLASH_SIZE,
.phys = H720X_FLASH_PHYS,
};

static struct mtd_partition h720x_partitions[] = {
Expand Down Expand Up @@ -70,7 +70,7 @@ int __init h720x_mtd_init(void)

char *part_type = NULL;

h720x_map.virt = ioremap(FLASH_PHYS, FLASH_SIZE);
h720x_map.virt = ioremap(h720x_map.phys, h720x_map.size);

if (!h720x_map.virt) {
printk(KERN_ERR "H720x-MTD: ioremap failed\n");
Expand Down

0 comments on commit d9a682a

Please sign in to comment.