mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-12-24 22:35:11 +02:00
[ar71xx] fix GPIO function select bit definitions (based on a patch by Jonas <jmajau at ubnt.com>)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@13699 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
61bfc135bd
commit
5375152a1a
@ -201,9 +201,8 @@ extern void ar71xx_add_device_usb(void) __init;
|
|||||||
|
|
||||||
#define GPIO_FUNC_STEREO_EN BIT(17)
|
#define GPIO_FUNC_STEREO_EN BIT(17)
|
||||||
#define GPIO_FUNC_SLIC_EN BIT(16)
|
#define GPIO_FUNC_SLIC_EN BIT(16)
|
||||||
#define GPIO_FUNC_SPI_CS1_EN BIT(15)
|
#define GPIO_FUNC_SPI_CS2_EN BIT(13)
|
||||||
#define GPIO_FUNC_SPI_CS0_EN BIT(14)
|
#define GPIO_FUNC_SPI_CS1_EN BIT(12)
|
||||||
#define GPIO_FUNC_SPI_EN BIT(13)
|
|
||||||
#define GPIO_FUNC_UART_EN BIT(8)
|
#define GPIO_FUNC_UART_EN BIT(8)
|
||||||
#define GPIO_FUNC_USB_OC_EN BIT(4)
|
#define GPIO_FUNC_USB_OC_EN BIT(4)
|
||||||
#define GPIO_FUNC_USB_CLK_EN BIT(0)
|
#define GPIO_FUNC_USB_CLK_EN BIT(0)
|
||||||
|
@ -152,6 +152,9 @@ static inline void rb433_add_device_spi(void) {}
|
|||||||
|
|
||||||
static void __init rb4xx_generic_setup(void)
|
static void __init rb4xx_generic_setup(void)
|
||||||
{
|
{
|
||||||
|
ar71xx_gpio_function_enable(GPIO_FUNC_SPI_CS1_EN |
|
||||||
|
GPIO_FUNC_SPI_CS2_EN);
|
||||||
|
|
||||||
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(rb4xx_leds_gpio),
|
ar71xx_add_device_leds_gpio(-1, ARRAY_SIZE(rb4xx_leds_gpio),
|
||||||
rb4xx_leds_gpio);
|
rb4xx_leds_gpio);
|
||||||
|
|
||||||
|
@ -481,8 +481,6 @@ void __init ar71xx_add_device_spi(struct ar71xx_spi_platform_data *pdata,
|
|||||||
struct spi_board_info const *info,
|
struct spi_board_info const *info,
|
||||||
unsigned n)
|
unsigned n)
|
||||||
{
|
{
|
||||||
ar71xx_gpio_function_enable(GPIO_FUNC_SPI_EN);
|
|
||||||
|
|
||||||
spi_register_board_info(info, n);
|
spi_register_board_info(info, n);
|
||||||
ar71xx_spi_device.dev.platform_data = pdata;
|
ar71xx_spi_device.dev.platform_data = pdata;
|
||||||
platform_device_register(&ar71xx_spi_device);
|
platform_device_register(&ar71xx_spi_device);
|
||||||
|
@ -201,9 +201,8 @@ extern void ar71xx_add_device_usb(void) __init;
|
|||||||
|
|
||||||
#define GPIO_FUNC_STEREO_EN BIT(17)
|
#define GPIO_FUNC_STEREO_EN BIT(17)
|
||||||
#define GPIO_FUNC_SLIC_EN BIT(16)
|
#define GPIO_FUNC_SLIC_EN BIT(16)
|
||||||
#define GPIO_FUNC_SPI_CS1_EN BIT(15)
|
#define GPIO_FUNC_SPI_CS2_EN BIT(13)
|
||||||
#define GPIO_FUNC_SPI_CS0_EN BIT(14)
|
#define GPIO_FUNC_SPI_CS1_EN BIT(12)
|
||||||
#define GPIO_FUNC_SPI_EN BIT(13)
|
|
||||||
#define GPIO_FUNC_UART_EN BIT(8)
|
#define GPIO_FUNC_UART_EN BIT(8)
|
||||||
#define GPIO_FUNC_USB_OC_EN BIT(4)
|
#define GPIO_FUNC_USB_OC_EN BIT(4)
|
||||||
#define GPIO_FUNC_USB_CLK_EN BIT(0)
|
#define GPIO_FUNC_USB_CLK_EN BIT(0)
|
||||||
|
Loading…
Reference in New Issue
Block a user