diff options
author | Bryan Wu <bryan.wu@analog.com> | 2007-11-12 10:24:42 -0500 |
---|---|---|
committer | Bryan Wu <bryan.wu@analog.com> | 2007-11-12 10:24:42 -0500 |
commit | 5d448dd50712ae42f8176b5bb8db4703bef6f0f5 (patch) | |
tree | bc0912451dacdb40393516362171da19317800aa /arch/blackfin/mach-bf561 | |
parent | 4a589e1ef67fdb2d5fa783117da8dc7cba576af4 (diff) |
Blackfin arch: move hard coded pin_req to board file
Remove some sort of bloaty code, try to get these pin_req arrays built at compile-time
- move this static things to the blackfin board file
- add pin_req array to struct bfin5xx_spi_master
- tested on BF537/BF548 with SPI flash
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Diffstat (limited to 'arch/blackfin/mach-bf561')
-rw-r--r-- | arch/blackfin/mach-bf561/boards/cm_bf561.c | 2 | ||||
-rw-r--r-- | arch/blackfin/mach-bf561/boards/ezkit.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/arch/blackfin/mach-bf561/boards/cm_bf561.c b/arch/blackfin/mach-bf561/boards/cm_bf561.c index 97aeb43fd8b4..9e46b52a3194 100644 --- a/arch/blackfin/mach-bf561/boards/cm_bf561.c +++ b/arch/blackfin/mach-bf561/boards/cm_bf561.c | |||
@@ -38,6 +38,7 @@ | |||
38 | #include <linux/irq.h> | 38 | #include <linux/irq.h> |
39 | #include <asm/dma.h> | 39 | #include <asm/dma.h> |
40 | #include <asm/bfin5xx_spi.h> | 40 | #include <asm/bfin5xx_spi.h> |
41 | #include <asm/portmux.h> | ||
41 | 42 | ||
42 | /* | 43 | /* |
43 | * Name the Board for the /proc/cpuinfo | 44 | * Name the Board for the /proc/cpuinfo |
@@ -182,6 +183,7 @@ static struct resource bfin_spi0_resource[] = { | |||
182 | static struct bfin5xx_spi_master bfin_spi0_info = { | 183 | static struct bfin5xx_spi_master bfin_spi0_info = { |
183 | .num_chipselect = 8, | 184 | .num_chipselect = 8, |
184 | .enable_dma = 1, /* master has the ability to do dma transfer */ | 185 | .enable_dma = 1, /* master has the ability to do dma transfer */ |
186 | .pin_req = {P_SPI0_SCK, P_SPI0_MISO, P_SPI0_MOSI, 0}, | ||
185 | }; | 187 | }; |
186 | 188 | ||
187 | static struct platform_device bfin_spi0_device = { | 189 | static struct platform_device bfin_spi0_device = { |
diff --git a/arch/blackfin/mach-bf561/boards/ezkit.c b/arch/blackfin/mach-bf561/boards/ezkit.c index 059d516cec23..6434ca216dd2 100644 --- a/arch/blackfin/mach-bf561/boards/ezkit.c +++ b/arch/blackfin/mach-bf561/boards/ezkit.c | |||
@@ -35,6 +35,7 @@ | |||
35 | #include <linux/pata_platform.h> | 35 | #include <linux/pata_platform.h> |
36 | #include <asm/dma.h> | 36 | #include <asm/dma.h> |
37 | #include <asm/bfin5xx_spi.h> | 37 | #include <asm/bfin5xx_spi.h> |
38 | #include <asm/portmux.h> | ||
38 | 39 | ||
39 | /* | 40 | /* |
40 | * Name the Board for the /proc/cpuinfo | 41 | * Name the Board for the /proc/cpuinfo |
@@ -160,6 +161,7 @@ static struct resource bfin_spi0_resource[] = { | |||
160 | static struct bfin5xx_spi_master bfin_spi0_info = { | 161 | static struct bfin5xx_spi_master bfin_spi0_info = { |
161 | .num_chipselect = 8, | 162 | .num_chipselect = 8, |
162 | .enable_dma = 1, /* master has the ability to do dma transfer */ | 163 | .enable_dma = 1, /* master has the ability to do dma transfer */ |
164 | .pin_req = {P_SPI0_SCK, P_SPI0_MISO, P_SPI0_MOSI, 0}, | ||
163 | }; | 165 | }; |
164 | 166 | ||
165 | static struct platform_device bfin_spi0_device = { | 167 | static struct platform_device bfin_spi0_device = { |