aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/mach-bf527/boards/ezkit.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/blackfin/mach-bf527/boards/ezkit.c')
-rw-r--r--arch/blackfin/mach-bf527/boards/ezkit.c53
1 files changed, 48 insertions, 5 deletions
diff --git a/arch/blackfin/mach-bf527/boards/ezkit.c b/arch/blackfin/mach-bf527/boards/ezkit.c
index 762f754c06cc..8ee2b744e234 100644
--- a/arch/blackfin/mach-bf527/boards/ezkit.c
+++ b/arch/blackfin/mach-bf527/boards/ezkit.c
@@ -42,10 +42,7 @@
42#include <linux/irq.h> 42#include <linux/irq.h>
43#include <linux/interrupt.h> 43#include <linux/interrupt.h>
44#include <linux/usb/sl811.h> 44#include <linux/usb/sl811.h>
45#if defined(CONFIG_USB_MUSB_HDRC) || defined(CONFIG_USB_MUSB_HDRC_MODULE)
46#include <linux/usb/musb.h> 45#include <linux/usb/musb.h>
47#endif
48#include <asm/cplb.h>
49#include <asm/dma.h> 46#include <asm/dma.h>
50#include <asm/bfin5xx_spi.h> 47#include <asm/bfin5xx_spi.h>
51#include <asm/reboot.h> 48#include <asm/reboot.h>
@@ -129,6 +126,16 @@ static struct resource musb_resources[] = {
129 }, 126 },
130}; 127};
131 128
129static struct musb_hdrc_config musb_config = {
130 .multipoint = 0,
131 .dyn_fifo = 0,
132 .soft_con = 1,
133 .dma = 1,
134 .num_eps = 7,
135 .dma_channels = 7,
136 .gpio_vrsel = GPIO_PG13,
137};
138
132static struct musb_hdrc_platform_data musb_plat = { 139static struct musb_hdrc_platform_data musb_plat = {
133#if defined(CONFIG_USB_MUSB_OTG) 140#if defined(CONFIG_USB_MUSB_OTG)
134 .mode = MUSB_OTG, 141 .mode = MUSB_OTG,
@@ -137,7 +144,7 @@ static struct musb_hdrc_platform_data musb_plat = {
137#elif defined(CONFIG_USB_GADGET_MUSB_HDRC) 144#elif defined(CONFIG_USB_GADGET_MUSB_HDRC)
138 .mode = MUSB_PERIPHERAL, 145 .mode = MUSB_PERIPHERAL,
139#endif 146#endif
140 .multipoint = 0, 147 .config = &musb_config,
141}; 148};
142 149
143static u64 musb_dmamask = ~(u32)0; 150static u64 musb_dmamask = ~(u32)0;
@@ -218,7 +225,7 @@ static struct mtd_partition partition_info[] = {
218 { 225 {
219 .name = "linux kernel(nand)", 226 .name = "linux kernel(nand)",
220 .offset = 0, 227 .offset = 0,
221 .size = 4 * SIZE_1M, 228 .size = 4 * 1024 * 1024,
222 }, 229 },
223 { 230 {
224 .name = "file system(nand)", 231 .name = "file system(nand)",
@@ -846,6 +853,38 @@ static struct platform_device bfin_device_gpiokeys = {
846}; 853};
847#endif 854#endif
848 855
856#if defined(CONFIG_JOYSTICK_BFIN_ROTARY) || defined(CONFIG_JOYSTICK_BFIN_ROTARY_MODULE)
857#include <linux/input.h>
858#include <asm/bfin_rotary.h>
859
860static struct bfin_rotary_platform_data bfin_rotary_data = {
861 /*.rotary_up_key = KEY_UP,*/
862 /*.rotary_down_key = KEY_DOWN,*/
863 .rotary_rel_code = REL_WHEEL,
864 .rotary_button_key = KEY_ENTER,
865 .debounce = 10, /* 0..17 */
866 .mode = ROT_QUAD_ENC | ROT_DEBE,
867};
868
869static struct resource bfin_rotary_resources[] = {
870 {
871 .start = IRQ_CNT,
872 .end = IRQ_CNT,
873 .flags = IORESOURCE_IRQ,
874 },
875};
876
877static struct platform_device bfin_rotary_device = {
878 .name = "bfin-rotary",
879 .id = -1,
880 .num_resources = ARRAY_SIZE(bfin_rotary_resources),
881 .resource = bfin_rotary_resources,
882 .dev = {
883 .platform_data = &bfin_rotary_data,
884 },
885};
886#endif
887
849static struct resource bfin_gpios_resources = { 888static struct resource bfin_gpios_resources = {
850 .start = 0, 889 .start = 0,
851 .end = MAX_BLACKFIN_GPIOS - 1, 890 .end = MAX_BLACKFIN_GPIOS - 1,
@@ -962,6 +1001,10 @@ static struct platform_device *stamp_devices[] __initdata = {
962 &bfin_device_gpiokeys, 1001 &bfin_device_gpiokeys,
963#endif 1002#endif
964 1003
1004#if defined(CONFIG_JOYSTICK_BFIN_ROTARY) || defined(CONFIG_JOYSTICK_BFIN_ROTARY_MODULE)
1005 &bfin_rotary_device,
1006#endif
1007
965#if defined(CONFIG_MTD_PHYSMAP) || defined(CONFIG_MTD_PHYSMAP_MODULE) 1008#if defined(CONFIG_MTD_PHYSMAP) || defined(CONFIG_MTD_PHYSMAP_MODULE)
966 &ezkit_flash_device, 1009 &ezkit_flash_device,
967#endif 1010#endif