IGEP board changes for .38 merge window
Subsystems (3)
cover IGEP board changes for .38 merge window
Hi Tony,
Here's a new patches for IGEP boards. These patches are rebased on top of your for-next tree. Please consider adding for .38 merge window. Thanks.
Cheers,
Enric Balletbo i Serra (3):
omap3: igep3: Add USB EHCI support for IGEP module.
omap3: igep3: Fix IGEP module second MMC channel power supply.
omap3: igep2: Add keypad support.
arch/arm/mach-omap2/board-igep0020.c | 33 ++++++++++++++ arch/arm/mach-omap2/board-igep0030.c | 80 +++++++++++++++++++++++++++++----- 2 files changed, 102 insertions(+), 11 deletions(-)
PATCH 1/3 omap3: igep3: Add USB EHCI support for IGEP module.
The OMAP3 IGEP module has one EHCI interface on board using USB2HS port. GPIO183 is used as PHY reset.
--- arch/arm/mach-omap2/board-igep0030.c | 15 ++++++++++++++- 1 files changed, 14 insertions(+), 1 deletions(-)
arch/arm/mach-omap2/board-igep0030.c +14 -1
@@ -43,7 +43,7 @@#define IGEP3_GPIO_WIFI_NRESET 139#define IGEP3_GPIO_BT_NRESET 137 -#define IGEP3_GPIO_USBH_NRESET 115 +#define IGEP3_GPIO_USBH_NRESET 183 #if defined(CONFIG_MTD_ONENAND_OMAP2) || \
@@ -363,8 +363,20 @@ static void __init igep3_wifi_bt_init(void)void __init igep3_wifi_bt_init (void ) {}#endif +static const struct ehci_hcd_omap_platform_data ehci_pdata__initconst = { + .port_mode[0 ] =EHCI_HCD_OMAP_MODE_UNKNOWN , + .port_mode[1 ] =EHCI_HCD_OMAP_MODE_PHY , + .port_mode[2 ] =EHCI_HCD_OMAP_MODE_UNKNOWN , + + .phy_reset = true, + .reset_gpio_port[0 ] = -EINVAL , + .reset_gpio_port[1 ] =IGEP3_GPIO_USBH_NRESET , + .reset_gpio_port[2 ] = -EINVAL , +}; +#ifdef CONFIG_OMAP_MUX static struct omap_board_mux board_mux[]__initdata = { +OMAP3_MUX (I2C2_SDA ,OMAP_MUX_MODE4 |OMAP_PIN_OUTPUT ), { .reg_offset =OMAP_MUX_TERMINATOR }, };#endif
@@ -378,6 +390,7 @@ static void __init igep3_init(void)omap_serial_init ();usb_musb_init (&musb_board_data); +usb_ehci_init (&ehci_pdata);igep3_flash_init ();igep3_leds_init ();
Signature · 1 line
1.7.0.4
PATCH 2/3 omap3: igep3: Fix IGEP module second MMC channel power supply.
In reply to Enric Balletbo i SerraThe second MMC channel (used by the WLAN/BT module) is not linked to power regulator. This causes the WLAN/BT module to fail being detected if CONFIG_REGULATOR_DUMMY is not set.
This patch adds the two regulators that actually feed the WLAN/BT module (1v8 from the TWL4030 VIO LDO, and a fixed 3v3). With that patch, the second channel is properly detected.
Also change vmmc1 to use symbolic names instead of direct device reference.
--- arch/arm/mach-omap2/board-igep0030.c | 65 ++++++++++++++++++++++++++++----- 1 files changed, 55 insertions(+), 10 deletions(-)
arch/arm/mach-omap2/board-igep0030.c +55 -10
@@ -19,6 +19,7 @@#include <linux/interrupt.h> #include <linux/regulator/machine.h> +#include <linux/regulator/fixed.h> #include <linux/i2c/twl.h> #include <linux/mmc/host.h>
@@ -140,9 +141,8 @@ static void __init igep3_flash_init(void)static void __init igep3_flash_init (void ) {}#endif -static struct regulator_consumer_supply igep3_vmmc1_supply = { - .supply ="vmmc" , -}; +static struct regulator_consumer_supply igep3_vmmc1_supply = +REGULATOR_SUPPLY ("vmmc" ,"mmci-omap-hs.0" );/* VMMC1 for OMAP VDD_MMC1 (i/o) and MMC1 card */ static struct regulator_init_data igep3_vmmc1 = {
@@ -159,6 +159,52 @@ static struct regulator_init_data igep3_vmmc1 = { .consumer_supplies = &igep3_vmmc1_supply, }; +static struct regulator_consumer_supply igep3_vio_supply = +REGULATOR_SUPPLY ("vmmc_aux" ,"mmci-omap-hs.1" ); + +static struct regulator_init_data igep3_vio = { + .constraints = { + .min_uV =1800000 , + .max_uV =1800000 , + .apply_uV =1 , + .valid_modes_mask =REGULATOR_MODE_NORMAL + |REGULATOR_MODE_STANDBY , + .valid_ops_mask =REGULATOR_CHANGE_VOLTAGE + |REGULATOR_CHANGE_MODE + |REGULATOR_CHANGE_STATUS , + }, + .num_consumer_supplies =1 , + .consumer_supplies = &igep3_vio_supply, +}; + +static struct regulator_consumer_supply igep3_vmmc2_supply = +REGULATOR_SUPPLY ("vmmc" ,"mmci-omap-hs.1" ); + +static struct regulator_init_data igep3_vmmc2 = { + .constraints = { + .valid_modes_mask =REGULATOR_MODE_NORMAL , + .always_on =1 , + }, + .num_consumer_supplies =1 , + .consumer_supplies = &igep3_vmmc2_supply, +}; + +static struct fixed_voltage_config igep3_vwlan = { + .supply_name ="vwlan" , + .microvolts =3300000 , + .gpio = -EINVAL , + .enabled_at_boot =1 , + .init_data = &igep3_vmmc2, +}; + +static struct platform_device igep3_vwlan_device = { + .name ="reg-fixed-voltage" , + .id =0 , + .dev = { + .platform_data = &igep3_vwlan, + }, +}; +static struct omap2_hsmmc_info mmc[] = { [0 ] = { .mmc =1 ,
@@ -254,12 +300,6 @@ static int igep3_twl4030_gpio_setup(struct device *dev, mmc[0 ].gpio_cd = gpio +0 ;omap2_hsmmc_init (mmc); -/* -* link regulators to MMC adapters ... we "know" the -* regulators will be set up only *after* we return. -*/ - igep3_vmmc1_supply.dev = mmc[0 ].dev; -/* TWL4030_GPIO_MAX + 1 == ledB (out, active low LED) */ #if !defined(CONFIG_LEDS_GPIO ) && !defined(CONFIG_LEDS_GPIO_MODULE ) if ((gpio_request(gpio+TWL4030_GPIO_MAX+1, "gpio-led:green:d1") == 0)
@@ -287,6 +327,10 @@ static struct twl4030_usb_data igep3_twl4030_usb_data = { .usb_mode = T2_USB_MODE_ULPI, }; +static struct platform_device *igep3_devices[]__initdata = { + &igep3_vwlan_device, +}; +static void __init igep3_init_irq (void ) {omap2_init_common_infrastructure ();
@@ -303,6 +347,7 @@ static struct twl4030_platform_data igep3_twl4030_pdata = { .usb = &igep3_twl4030_usb_data, .gpio = &igep3_twl4030_gpio_pdata, .vmmc1 = &igep3_vmmc1, + .vio = &igep3_vio, };static struct i2c_board_info __initdata igep3_i2c_boardinfo[] = {
@@ -387,7 +432,7 @@ static void __init igep3_init(void)/* Register I2C busses and drivers */ igep3_i2c_init (); - +platform_add_devices (igep3_devices,ARRAY_SIZE (igep3_devices));omap_serial_init ();usb_musb_init (&musb_board_data);usb_ehci_init (&ehci_pdata);
Signature · 1 line
1.7.0.4
PATCH 2/3 omap3: igep3: Fix IGEP module second MMC channel power supply.
Quoted 2 lines · Enric Balletbo i Serra
The second MMC channel (used by the WLAN/BT module) is not linked to power regulator. This causes the WLAN/BT module to fail being detected
if
Quoted 10 lines
CONFIG_REGULATOR_DUMMYis not set.This patch adds the two regulators that actually feed the WLAN/BT module (1v8 from the TWL4030 VIO LDO, and a fixed 3v3). With that patch, the second channel is properly detected.
Also change vmmc1 to use symbolic names instead of direct device reference.
Signed-off-by Enric Balletbo i Serra <[email protected]>
Signature · 1 line
Who you jivin' with that Cosmik Debris?
PATCH 3/3 omap3: igep2: Add keypad support.
In reply to Enric Balletbo i SerraSupport twl4030 keypad and gpio keys on IGEP v2.
--- arch/arm/mach-omap2/board-igep0020.c | 33 +++++++++++++++++++++++++++++++++ 1 files changed, 33 insertions(+), 0 deletions(-)
arch/arm/mach-omap2/board-igep0020.c +33 -0
@@ -17,6 +17,7 @@#include <linux/io.h> #include <linux/gpio.h> #include <linux/interrupt.h> +#include <linux/input.h> #include <linux/regulator/machine.h> #include <linux/regulator/fixed.h>
@@ -535,6 +536,37 @@ static struct twl4030_codec_data igep2_codec_data = { .audio = &igep2_audio_data, }; +static int igep2_keymap[] = { +KEY (0 ,0 ,KEY_LEFT ), +KEY (0 ,1 ,KEY_RIGHT ), +KEY (0 ,2 ,KEY_A ), +KEY (0 ,3 ,KEY_B ), +KEY (1 ,0 ,KEY_DOWN ), +KEY (1 ,1 ,KEY_UP ), +KEY (1 ,2 ,KEY_E ), +KEY (1 ,3 ,KEY_F ), +KEY (2 ,0 ,KEY_ENTER ), +KEY (2 ,1 ,KEY_I ), +KEY (2 ,2 ,KEY_J ), +KEY (2 ,3 ,KEY_K ), +KEY (3 ,0 ,KEY_M ), +KEY (3 ,1 ,KEY_N ), +KEY (3 ,2 ,KEY_O ), +KEY (3 ,3 ,KEY_P ) +}; + +static struct matrix_keymap_data igep2_keymap_data = { + .keymap = igep2_keymap, + .keymap_size =ARRAY_SIZE (igep2_keymap), +}; + +static struct twl4030_keypad_data igep2_keypad_pdata = { + .keymap_data = &igep2_keymap_data, + .rows =4 , + .cols =4 , + .rep =1 , +}; +static struct twl4030_platform_data igep2_twldata = { .irq_base =TWL4030_IRQ_BASE , .irq_end =TWL4030_IRQ_END ,
@@ -543,6 +575,7 @@ static struct twl4030_platform_data igep2_twldata = { .usb = &igep2_usb_data, .codec = &igep2_codec_data, .gpio = &igep2_twl4030_gpio_pdata, + .keypad = &igep2_keypad_pdata, .vmmc1 = &igep2_vmmc1, .vpll2 = &igep2_vpll2, .vio = &igep2_vio,
Signature · 1 line
1.7.0.4
Tony Lindgren
maintainercover IGEP board changes for .38 merge window
In reply to Enric Balletbo i SerraHi,
Quoted 4 lines · Enric Balletbo i Serra
Hi Tony,
Here's a new patches for IGEP boards. These patches are rebased on top of your for-next tree. Please consider adding for .38 merge window. Thanks.
I'll add these to the devel-board, let's see if we can get these and the beagle patches still in.
In general, everybody, please send in new code for each merge window by -rc6 so there's enough time for people to review and ack the code and also have it be sitting in for-next before the merge window opens.
Regards,
Tony