summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorflorian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73>2007-10-23 10:46:19 +0000
committerflorian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73>2007-10-23 10:46:19 +0000
commit3fb6c53e6d43887437a7dcbbb4f2da4fcf23967f (patch)
tree9e3f5f455303e0c3a08ed2a94776d28b00dd6904
parentcec0e612add24b1b571924cb847552634e27e3fc (diff)
The RB513 CF driver is now a module, enable it by default for the RB1xx profile.
Fix the membase of the CF driver. git-svn-id: svn://svn.openwrt.org/openwrt/trunk@9416 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--package/kernel/modules/block.mk15
-rw-r--r--target/linux/adm5120/files/arch/mips/adm5120/boards/mikrotik.c6
-rw-r--r--target/linux/adm5120/files/drivers/block/rb1xx/Makefile3
-rw-r--r--target/linux/adm5120/files/include/asm-mips/mach-adm5120/adm5120_defs.h1
-rw-r--r--target/linux/adm5120/patches-2.6.23/120-cf.patch14
-rw-r--r--target/linux/adm5120/router_le/config-2.6.232
-rw-r--r--target/linux/adm5120/router_le/profiles/RB1xx.mk2
7 files changed, 37 insertions, 6 deletions
diff --git a/package/kernel/modules/block.mk b/package/kernel/modules/block.mk
index fc33073d5..9a4d6ffb7 100644
--- a/package/kernel/modules/block.mk
+++ b/package/kernel/modules/block.mk
@@ -182,3 +182,18 @@ define KernelPackage/nbd/description
endef
$(eval $(call KernelPackage,nbd))
+
+
+define KernelPackage/rb153-cf
+ SUBMENU:=$(BLOCK_MENU)
+ TITLE:=RouterBoard 153 CF Slot
+ KCONFIG:=CONFIG_BLK_DEV_CF_MIPS
+ FILES:=$(LINUX_DIR)/drivers/block/rb1xx/rb153-cf.$(LINUX_KMOD_SUFFIX)
+ AUTOLOAD:=$(call AutoLoad,30,rb153-cf)
+endef
+
+define KernelPackage/rb153-cf/description
+ Kernel module for the RouterBoard 153 CF slot
+endef
+
+$(eval $(call KernelPackage,rb153-cf))
diff --git a/target/linux/adm5120/files/arch/mips/adm5120/boards/mikrotik.c b/target/linux/adm5120/files/arch/mips/adm5120/boards/mikrotik.c
index 74dd860dc..1ed420e0c 100644
--- a/target/linux/adm5120/files/arch/mips/adm5120/boards/mikrotik.c
+++ b/target/linux/adm5120/files/arch/mips/adm5120/boards/mikrotik.c
@@ -182,11 +182,13 @@ static void rb150_nand_cmd_ctrl(struct mtd_info *mtd, int cmd,
static struct resource cf_slot0_res[] = {
{
.name = "cf_membase",
+ .start = ADM5120_EXTIO0_BASE,
+ .end = ADM5120_EXTIO0_BASE + ADM5120_MPMC_SIZE-1 ,
.flags = IORESOURCE_MEM
}, {
.name = "cf_irq",
- .start = INTC_IRQ_GPIO4, /* 5 */
- .end = INTC_IRQ_GPIO4,
+ .start = ADM5120_IRQ_GPIO4, /* 5 */
+ .end = ADM5120_IRQ_GPIO4,
.flags = IORESOURCE_IRQ
}
};
diff --git a/target/linux/adm5120/files/drivers/block/rb1xx/Makefile b/target/linux/adm5120/files/drivers/block/rb1xx/Makefile
index 672aaa697..9e46301e8 100644
--- a/target/linux/adm5120/files/drivers/block/rb1xx/Makefile
+++ b/target/linux/adm5120/files/drivers/block/rb1xx/Makefile
@@ -1,2 +1,3 @@
## Makefile for the RB1xx CF port
-obj-y += bdev.o ata.o
+obj-$(CONFIG_BLK_DEV_CF_MIPS) += rb153-cf.o
+rb153-cf-objs := bdev.o ata.o
diff --git a/target/linux/adm5120/files/include/asm-mips/mach-adm5120/adm5120_defs.h b/target/linux/adm5120/files/include/asm-mips/mach-adm5120/adm5120_defs.h
index d39620aab..2f92a4564 100644
--- a/target/linux/adm5120/files/include/asm-mips/mach-adm5120/adm5120_defs.h
+++ b/target/linux/adm5120/files/include/asm-mips/mach-adm5120/adm5120_defs.h
@@ -30,6 +30,7 @@
#define ADM5120_SDRAM1_BASE 0x01000000
#define ADM5120_SRAM1_BASE 0x10000000
#define ADM5120_NAND_BASE ADM5120_SRAM1_BASE
+#define ADM5120_EXTIO0_BASE 0x10C00000
#define ADM5120_MPMC_BASE 0x11000000
#define ADM5120_USBC_BASE 0x11200000
#define ADM5120_PCIMEM_BASE 0x11400000
diff --git a/target/linux/adm5120/patches-2.6.23/120-cf.patch b/target/linux/adm5120/patches-2.6.23/120-cf.patch
index cbfe42d6c..6a4165130 100644
--- a/target/linux/adm5120/patches-2.6.23/120-cf.patch
+++ b/target/linux/adm5120/patches-2.6.23/120-cf.patch
@@ -7,7 +7,7 @@ Index: linux-2.6.23/drivers/block/Kconfig
module will be called z2ram.
+config BLK_DEV_CF_MIPS
-+ bool "CF slot of RB153 board"
++ tristate "CF slot of RB153 board"
+ depends on MIPS_ADM5120
+ default y
+ help
@@ -29,3 +29,15 @@ Index: linux-2.6.23/drivers/block/Makefile
obj-$(CONFIG_AMIGA_FLOPPY) += amiflop.o
obj-$(CONFIG_PS3_DISK) += ps3disk.o
obj-$(CONFIG_ATARI_FLOPPY) += ataflop.o
+diff --git a/fs/partitions/check.c b/fs/partitions/check.c
+index 722e12e..60af038 100644
+--- a/fs/partitions/check.c
++++ b/fs/partitions/check.c
+@@ -526,6 +526,7 @@ exit:
+ kobject_uevent(&p->kobj, KOBJ_ADD);
+ }
+ }
++EXPORT_SYMBOL(register_disk);
+
+ int rescan_partitions(struct gendisk *disk, struct block_device *bdev)
+ {
diff --git a/target/linux/adm5120/router_le/config-2.6.23 b/target/linux/adm5120/router_le/config-2.6.23
index 4267f70a7..7727187fa 100644
--- a/target/linux/adm5120/router_le/config-2.6.23
+++ b/target/linux/adm5120/router_le/config-2.6.23
@@ -10,7 +10,7 @@ CONFIG_BAYCOM_SER_FDX=m
CONFIG_BAYCOM_SER_HDX=m
CONFIG_BINFMT_MISC=m
CONFIG_BITREVERSE=y
-CONFIG_BLK_DEV_CF_MIPS=y
+CONFIG_BLK_DEV_CF_MIPS=m
CONFIG_CIFS_DEBUG2=y
CONFIG_CIFS_EXPERIMENTAL=y
CONFIG_CIFS_STATS2=y
diff --git a/target/linux/adm5120/router_le/profiles/RB1xx.mk b/target/linux/adm5120/router_le/profiles/RB1xx.mk
index 76e4ad87f..fddcb6396 100644
--- a/target/linux/adm5120/router_le/profiles/RB1xx.mk
+++ b/target/linux/adm5120/router_le/profiles/RB1xx.mk
@@ -7,7 +7,7 @@
define Profile/RouterBoard
NAME:=Mikrotik RouterBoard 1xx family
- PACKAGES:=kmod-madwifi
+ PACKAGES:=kmod-madwifi kmod-rb153-cf
endef
define Profile/RouterBoard/Description