diff options
author | Michael Hennerich <michael.hennerich@analog.com> | 2009-10-16 08:35:20 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2009-12-15 00:16:18 -0500 |
commit | 57af8edf3f0346aa0f942f245acbfe122bb75707 (patch) | |
tree | 550fc3225de142609abeb33cd2a71e16d7133d2d | |
parent | 31ad0e27ed71c30cd328b503ce6163392b4dd9e2 (diff) |
Blackfin: bf537-stamp/bf548-ezkit: update ADXL34x resources
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
-rw-r--r-- | arch/blackfin/mach-bf537/boards/stamp.c | 25 | ||||
-rw-r--r-- | arch/blackfin/mach-bf548/boards/ezkit.c | 6 |
2 files changed, 23 insertions, 8 deletions
diff --git a/arch/blackfin/mach-bf537/boards/stamp.c b/arch/blackfin/mach-bf537/boards/stamp.c index d5a4c82df604..fc76ddb69343 100644 --- a/arch/blackfin/mach-bf537/boards/stamp.c +++ b/arch/blackfin/mach-bf537/boards/stamp.c | |||
@@ -698,7 +698,7 @@ static const struct ad7879_platform_data bfin_ad7879_ts_info = { | |||
698 | 698 | ||
699 | #if defined(CONFIG_INPUT_ADXL34X) || defined(CONFIG_INPUT_ADXL34X_MODULE) | 699 | #if defined(CONFIG_INPUT_ADXL34X) || defined(CONFIG_INPUT_ADXL34X_MODULE) |
700 | #include <linux/input.h> | 700 | #include <linux/input.h> |
701 | #include <linux/spi/adxl34x.h> | 701 | #include <linux/input/adxl34x.h> |
702 | static const struct adxl34x_platform_data adxl34x_info = { | 702 | static const struct adxl34x_platform_data adxl34x_info = { |
703 | .x_axis_offset = 0, | 703 | .x_axis_offset = 0, |
704 | .y_axis_offset = 0, | 704 | .y_axis_offset = 0, |
@@ -722,9 +722,7 @@ static const struct adxl34x_platform_data adxl34x_info = { | |||
722 | .ev_code_y = ABS_Y, /* EV_REL */ | 722 | .ev_code_y = ABS_Y, /* EV_REL */ |
723 | .ev_code_z = ABS_Z, /* EV_REL */ | 723 | .ev_code_z = ABS_Z, /* EV_REL */ |
724 | 724 | ||
725 | .ev_code_tap_x = BTN_TOUCH, /* EV_KEY */ | 725 | .ev_code_tap = {BTN_TOUCH, BTN_TOUCH, BTN_TOUCH}, /* EV_KEY x,y,z */ |
726 | .ev_code_tap_y = BTN_TOUCH, /* EV_KEY */ | ||
727 | .ev_code_tap_z = BTN_TOUCH, /* EV_KEY */ | ||
728 | 726 | ||
729 | /* .ev_code_ff = KEY_F,*/ /* EV_KEY */ | 727 | /* .ev_code_ff = KEY_F,*/ /* EV_KEY */ |
730 | /* .ev_code_act_inactivity = KEY_A,*/ /* EV_KEY */ | 728 | /* .ev_code_act_inactivity = KEY_A,*/ /* EV_KEY */ |
@@ -795,6 +793,13 @@ static struct bfin5xx_spi_chip data_flash_chip_info = { | |||
795 | }; | 793 | }; |
796 | #endif | 794 | #endif |
797 | 795 | ||
796 | #if defined(CONFIG_INPUT_ADXL34X_SPI) || defined(CONFIG_INPUT_ADXL34X_SPI_MODULE) | ||
797 | static struct bfin5xx_spi_chip spi_adxl34x_chip_info = { | ||
798 | .enable_dma = 0, /* use dma transfer with this chip*/ | ||
799 | .bits_per_word = 8, | ||
800 | }; | ||
801 | #endif | ||
802 | |||
798 | static struct spi_board_info bfin_spi_board_info[] __initdata = { | 803 | static struct spi_board_info bfin_spi_board_info[] __initdata = { |
799 | #if defined(CONFIG_MTD_M25P80) \ | 804 | #if defined(CONFIG_MTD_M25P80) \ |
800 | || defined(CONFIG_MTD_M25P80_MODULE) | 805 | || defined(CONFIG_MTD_M25P80_MODULE) |
@@ -933,6 +938,18 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
933 | .mode = SPI_MODE_0, | 938 | .mode = SPI_MODE_0, |
934 | }, | 939 | }, |
935 | #endif | 940 | #endif |
941 | #if defined(CONFIG_INPUT_ADXL34X_SPI) || defined(CONFIG_INPUT_ADXL34X_SPI_MODULE) | ||
942 | { | ||
943 | .modalias = "adxl34x", | ||
944 | .platform_data = &adxl34x_info, | ||
945 | .irq = IRQ_PF6, | ||
946 | .max_speed_hz = 5000000, /* max spi clock (SCK) speed in HZ */ | ||
947 | .bus_num = 0, | ||
948 | .chip_select = 2, | ||
949 | .controller_data = &spi_adxl34x_chip_info, | ||
950 | .mode = SPI_MODE_3, | ||
951 | }, | ||
952 | #endif | ||
936 | }; | 953 | }; |
937 | 954 | ||
938 | #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE) | 955 | #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE) |
diff --git a/arch/blackfin/mach-bf548/boards/ezkit.c b/arch/blackfin/mach-bf548/boards/ezkit.c index 0d65cfaf0f6d..93595cf35e67 100644 --- a/arch/blackfin/mach-bf548/boards/ezkit.c +++ b/arch/blackfin/mach-bf548/boards/ezkit.c | |||
@@ -186,7 +186,7 @@ static struct platform_device bfin_rotary_device = { | |||
186 | #endif | 186 | #endif |
187 | 187 | ||
188 | #if defined(CONFIG_INPUT_ADXL34X) || defined(CONFIG_INPUT_ADXL34X_MODULE) | 188 | #if defined(CONFIG_INPUT_ADXL34X) || defined(CONFIG_INPUT_ADXL34X_MODULE) |
189 | #include <linux/spi/adxl34x.h> | 189 | #include <linux/input/adxl34x.h> |
190 | static const struct adxl34x_platform_data adxl34x_info = { | 190 | static const struct adxl34x_platform_data adxl34x_info = { |
191 | .x_axis_offset = 0, | 191 | .x_axis_offset = 0, |
192 | .y_axis_offset = 0, | 192 | .y_axis_offset = 0, |
@@ -210,9 +210,7 @@ static const struct adxl34x_platform_data adxl34x_info = { | |||
210 | .ev_code_y = ABS_Y, /* EV_REL */ | 210 | .ev_code_y = ABS_Y, /* EV_REL */ |
211 | .ev_code_z = ABS_Z, /* EV_REL */ | 211 | .ev_code_z = ABS_Z, /* EV_REL */ |
212 | 212 | ||
213 | .ev_code_tap_x = BTN_TOUCH, /* EV_KEY */ | 213 | .ev_code_tap = {BTN_TOUCH, BTN_TOUCH, BTN_TOUCH}, /* EV_KEY x,y,z */ |
214 | .ev_code_tap_y = BTN_TOUCH, /* EV_KEY */ | ||
215 | .ev_code_tap_z = BTN_TOUCH, /* EV_KEY */ | ||
216 | 214 | ||
217 | /* .ev_code_ff = KEY_F,*/ /* EV_KEY */ | 215 | /* .ev_code_ff = KEY_F,*/ /* EV_KEY */ |
218 | /* .ev_code_act_inactivity = KEY_A,*/ /* EV_KEY */ | 216 | /* .ev_code_act_inactivity = KEY_A,*/ /* EV_KEY */ |