Skip to content

Commit

Permalink
[Blackfin] arch: add board resources for new simple-gpio char driver
Browse files Browse the repository at this point in the history
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
  • Loading branch information
Mike Frysinger authored and Bryan Wu committed Feb 22, 2008
1 parent edf0564 commit cad2ab6
Show file tree
Hide file tree
Showing 6 changed files with 89 additions and 0 deletions.
15 changes: 15 additions & 0 deletions arch/blackfin/mach-bf527/boards/ezkit.c
Original file line number Diff line number Diff line change
Expand Up @@ -818,6 +818,19 @@ static struct platform_device bfin_device_gpiokeys = {
};
#endif

static struct resource bfin_gpios_resources = {
.start = 0,
.end = MAX_BLACKFIN_GPIOS - 1,
.flags = IORESOURCE_IRQ,
};

static struct platform_device bfin_gpios_device = {
.name = "simple-gpio",
.id = -1,
.num_resources = 1,
.resource = &bfin_gpios_resources,
};

static struct platform_device *stamp_devices[] __initdata = {
#if defined(CONFIG_MTD_NAND_BF5XX) || defined(CONFIG_MTD_NAND_BF5XX_MODULE)
&bf5xx_nand_device,
Expand Down Expand Up @@ -895,6 +908,8 @@ static struct platform_device *stamp_devices[] __initdata = {
#if defined(CONFIG_KEYBOARD_GPIO) || defined(CONFIG_KEYBOARD_GPIO_MODULE)
&bfin_device_gpiokeys,
#endif

&bfin_gpios_device,
};

static int __init stamp_init(void)
Expand Down
15 changes: 15 additions & 0 deletions arch/blackfin/mach-bf533/boards/ezkit.c
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,19 @@ static struct platform_device bfin_device_gpiokeys = {
};
#endif

static struct resource bfin_gpios_resources = {
.start = 0,
.end = MAX_BLACKFIN_GPIOS - 1,
.flags = IORESOURCE_IRQ,
};

static struct platform_device bfin_gpios_device = {
.name = "simple-gpio",
.id = -1,
.num_resources = 1,
.resource = &bfin_gpios_resources,
};

#if defined(CONFIG_I2C_GPIO) || defined(CONFIG_I2C_GPIO_MODULE)
#include <linux/i2c-gpio.h>

Expand Down Expand Up @@ -350,6 +363,8 @@ static struct platform_device *ezkit_devices[] __initdata = {
#if defined(CONFIG_I2C_GPIO) || defined(CONFIG_I2C_GPIO_MODULE)
&i2c_gpio_device,
#endif

&bfin_gpios_device,
};

static int __init ezkit_init(void)
Expand Down
15 changes: 15 additions & 0 deletions arch/blackfin/mach-bf533/boards/stamp.c
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,19 @@ static struct platform_device bfin_device_gpiokeys = {
};
#endif

static struct resource bfin_gpios_resources = {
.start = 0,
.end = MAX_BLACKFIN_GPIOS - 1,
.flags = IORESOURCE_IRQ,
};

static struct platform_device bfin_gpios_device = {
.name = "simple-gpio",
.id = -1,
.num_resources = 1,
.resource = &bfin_gpios_resources,
};

#if defined(CONFIG_I2C_GPIO) || defined(CONFIG_I2C_GPIO_MODULE)
#include <linux/i2c-gpio.h>

Expand Down Expand Up @@ -518,6 +531,8 @@ static struct platform_device *stamp_devices[] __initdata = {
#if defined(CONFIG_I2C_GPIO) || defined(CONFIG_I2C_GPIO_MODULE)
&i2c_gpio_device,
#endif

&bfin_gpios_device,
&stamp_flash_device,
};

Expand Down
15 changes: 15 additions & 0 deletions arch/blackfin/mach-bf537/boards/stamp.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,19 @@ static struct platform_device bfin_device_gpiokeys = {
};
#endif

static struct resource bfin_gpios_resources = {
.start = 0,
.end = MAX_BLACKFIN_GPIOS - 1,
.flags = IORESOURCE_IRQ,
};

static struct platform_device bfin_gpios_device = {
.name = "simple-gpio",
.id = -1,
.num_resources = 1,
.resource = &bfin_gpios_resources,
};

#if defined(CONFIG_BFIN_CFPCMCIA) || defined(CONFIG_BFIN_CFPCMCIA_MODULE)
static struct resource bfin_pcmcia_cf_resources[] = {
{
Expand Down Expand Up @@ -821,6 +834,8 @@ static struct platform_device *stamp_devices[] __initdata = {
#if defined(CONFIG_KEYBOARD_GPIO) || defined(CONFIG_KEYBOARD_GPIO_MODULE)
&bfin_device_gpiokeys,
#endif

&bfin_gpios_device,
&stamp_flash_device,
};

Expand Down
15 changes: 15 additions & 0 deletions arch/blackfin/mach-bf548/boards/ezkit.c
Original file line number Diff line number Diff line change
Expand Up @@ -594,6 +594,19 @@ static struct platform_device bfin_device_gpiokeys = {
};
#endif

static struct resource bfin_gpios_resources = {
.start = 0,
.end = MAX_BLACKFIN_GPIOS - 1,
.flags = IORESOURCE_IRQ,
};

static struct platform_device bfin_gpios_device = {
.name = "simple-gpio",
.id = -1,
.num_resources = 1,
.resource = &bfin_gpios_resources,
};

static struct platform_device *ezkit_devices[] __initdata = {
#if defined(CONFIG_RTC_DRV_BFIN) || defined(CONFIG_RTC_DRV_BFIN_MODULE)
&rtc_device,
Expand Down Expand Up @@ -646,6 +659,8 @@ static struct platform_device *ezkit_devices[] __initdata = {
#if defined(CONFIG_KEYBOARD_GPIO) || defined(CONFIG_KEYBOARD_GPIO_MODULE)
&bfin_device_gpiokeys,
#endif

&bfin_gpios_device,
&ezkit_flash_device,
};

Expand Down
14 changes: 14 additions & 0 deletions arch/blackfin/mach-bf561/boards/ezkit.c
Original file line number Diff line number Diff line change
Expand Up @@ -389,6 +389,19 @@ static struct platform_device bfin_device_gpiokeys = {
};
#endif

static struct resource bfin_gpios_resources = {
.start = 0,
.end = MAX_BLACKFIN_GPIOS - 1,
.flags = IORESOURCE_IRQ,
};

static struct platform_device bfin_gpios_device = {
.name = "simple-gpio",
.id = -1,
.num_resources = 1,
.resource = &bfin_gpios_resources,
};

#if defined(CONFIG_I2C_GPIO) || defined(CONFIG_I2C_GPIO_MODULE)
#include <linux/i2c-gpio.h>

Expand Down Expand Up @@ -446,6 +459,7 @@ static struct platform_device *ezkit_devices[] __initdata = {
&isp1362_hcd_device,
#endif

&bfin_gpios_device,
&ezkit_flash_device,
};

Expand Down

0 comments on commit cad2ab6

Please sign in to comment.