* [PATCH v2 0/5] Panda: Support for WLAN on WL127x @ 2011-02-15 8:40 Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 1/5] omap: panda: wlan board muxing Panduranga Mallireddy 2011-02-18 0:03 ` [PATCH v2 0/5] Panda: Support for WLAN on WL127x Tony Lindgren 0 siblings, 2 replies; 7+ messages in thread From: Panduranga Mallireddy @ 2011-02-15 8:40 UTC (permalink / raw) To: coelho, netdev, linux-omap, linux-mmc Cc: ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, tony, cjb, Panduranga Mallireddy Fixes from V1: 1. Removing the pull up of WLAN IRQ line, since it is always held up by wl127x device. Adding support for WLAN on Panda board using wl12xx and mac80211 drivers Patches were tested on Panda board. These patches add software control for emulating card detect events, add board configurations to support the wl127x device. These patches are dependent on the patches that enable clock for WLAN on panda. Please refer the following links for these patches: https://patchwork.kernel.org/patch/546381/ https://patchwork.kernel.org/patch/546401/ [PATCH 5/5] OMAP: hsmmc: Enable MMC4 and MMC5 on OMAP4 platforms is dependent on hwmod adpotation for HSMMC patches series. For original patches of adpotation for HSMMC refer: http://www.mail-archive.com/linux-omap@vger.kernel.org/msg43464.html Patches are based on mainline 2.6.38-rc3 Kishore Kadiyala (1): OMAP: hsmmc: Enable MMC4 and MMC5 on OMAP4 platforms Panduranga Mallireddy (4): omap: panda: wlan board muxing omap: select REGULATOR_FIXED_VOLTAGE by default for panda and sdp4430 omap: panda: add fixed regulator device for wlan omap: panda: add mmc5/wl1271 device support arch/arm/mach-omap2/Kconfig | 2 + arch/arm/mach-omap2/board-omap4panda.c | 67 ++++++++++++++++++++++++++++++++ arch/arm/mach-omap2/hsmmc.c | 5 ++ drivers/mmc/host/omap_hsmmc.c | 24 +++++++++-- 4 files changed, 94 insertions(+), 4 deletions(-) ^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v2 1/5] omap: panda: wlan board muxing 2011-02-15 8:40 [PATCH v2 0/5] Panda: Support for WLAN on WL127x Panduranga Mallireddy @ 2011-02-15 8:40 ` Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 2/5] omap: select REGULATOR_FIXED_VOLTAGE by default for panda and sdp4430 Panduranga Mallireddy 2011-02-18 0:03 ` [PATCH v2 0/5] Panda: Support for WLAN on WL127x Tony Lindgren 1 sibling, 1 reply; 7+ messages in thread From: Panduranga Mallireddy @ 2011-02-15 8:40 UTC (permalink / raw) To: coelho, netdev, linux-omap, linux-mmc Cc: ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, tony, cjb, Panduranga Mallireddy Add board muxing to support the wlan wl1271 chip that is hardwired to mmc5 (fifth mmc controller) on the PANDA. Based on the wlan board muxing for zoom3 by Ohad Ben-Cohen <ohadb@ti.com> Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com> --- arch/arm/mach-omap2/board-omap4panda.c | 13 +++++++++++++ 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c index 9218862..cc9df6c 100644 --- a/arch/arm/mach-omap2/board-omap4panda.c +++ b/arch/arm/mach-omap2/board-omap4panda.c @@ -401,6 +401,19 @@ static int __init omap4_panda_i2c_init(void) #ifdef CONFIG_OMAP_MUX static struct omap_board_mux board_mux[] __initdata = { + /* WLAN IRQ - GPIO 53 */ + OMAP4_MUX(GPMC_NCS3, OMAP_MUX_MODE3 | OMAP_PIN_INPUT), + /* WLAN POWER ENABLE - GPIO 43 */ + OMAP4_MUX(GPMC_A19, OMAP_MUX_MODE3 | OMAP_PIN_OUTPUT), + /* WLAN SDIO: MMC5 CMD */ + OMAP4_MUX(SDMMC5_CMD, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), + /* WLAN SDIO: MMC5 CLK */ + OMAP4_MUX(SDMMC5_CLK, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), + /* WLAN SDIO: MMC5 DAT[0-3] */ + OMAP4_MUX(SDMMC5_DAT0, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), + OMAP4_MUX(SDMMC5_DAT1, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), + OMAP4_MUX(SDMMC5_DAT2, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), + OMAP4_MUX(SDMMC5_DAT3, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP), { .reg_offset = OMAP_MUX_TERMINATOR }, }; #else -- 1.5.6.3 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 2/5] omap: select REGULATOR_FIXED_VOLTAGE by default for panda and sdp4430 2011-02-15 8:40 ` [PATCH v2 1/5] omap: panda: wlan board muxing Panduranga Mallireddy @ 2011-02-15 8:40 ` Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 3/5] omap: panda: add fixed regulator device for wlan Panduranga Mallireddy 0 siblings, 1 reply; 7+ messages in thread From: Panduranga Mallireddy @ 2011-02-15 8:40 UTC (permalink / raw) To: coelho, netdev, linux-omap, linux-mmc Cc: ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, tony, cjb, Panduranga Mallireddy Power to the wl12xx wlan device is controlled by a fixed regulator. Boards that have the wl12xx should select REGULATOR_FIXED_VOLTAGE. Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com> --- arch/arm/mach-omap2/Kconfig | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/Kconfig b/arch/arm/mach-omap2/Kconfig index 1a2cf62..eeaeb3b 100644 --- a/arch/arm/mach-omap2/Kconfig +++ b/arch/arm/mach-omap2/Kconfig @@ -300,6 +300,7 @@ config MACH_OMAP_4430SDP depends on ARCH_OMAP4 select OMAP_PACKAGE_CBL select OMAP_PACKAGE_CBS + select REGULATOR_FIXED_VOLTAGE config MACH_OMAP4_PANDA bool "OMAP4 Panda Board" @@ -307,6 +308,7 @@ config MACH_OMAP4_PANDA depends on ARCH_OMAP4 select OMAP_PACKAGE_CBL select OMAP_PACKAGE_CBS + select REGULATOR_FIXED_VOLTAGE config OMAP3_EMU bool "OMAP3 debugging peripherals" -- 1.5.6.3 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 3/5] omap: panda: add fixed regulator device for wlan 2011-02-15 8:40 ` [PATCH v2 2/5] omap: select REGULATOR_FIXED_VOLTAGE by default for panda and sdp4430 Panduranga Mallireddy @ 2011-02-15 8:40 ` Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 4/5] omap: panda: add mmc5/wl1271 device support Panduranga Mallireddy 0 siblings, 1 reply; 7+ messages in thread From: Panduranga Mallireddy @ 2011-02-15 8:40 UTC (permalink / raw) To: coelho, netdev, linux-omap, linux-mmc Cc: ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, tony, cjb, Panduranga Mallireddy Add a fixed regulator vmmc device to enable power control of the wl1271 wlan device. Based on the patch for zoom by Ohad Ben-Cohen <ohad@wizery.com> Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com> --- arch/arm/mach-omap2/board-omap4panda.c | 34 ++++++++++++++++++++++++++++++++ 1 files changed, 34 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c index cc9df6c..cd25255 100644 --- a/arch/arm/mach-omap2/board-omap4panda.c +++ b/arch/arm/mach-omap2/board-omap4panda.c @@ -26,6 +26,7 @@ #include <linux/usb/otg.h> #include <linux/i2c/twl.h> #include <linux/regulator/machine.h> +#include <linux/regulator/fixed.h> #include <mach/hardware.h> #include <mach/omap4-common.h> @@ -45,6 +46,7 @@ #define GPIO_HUB_POWER 1 #define GPIO_HUB_NRESET 62 +#define GPIO_WIFI_PMENA 43 static struct gpio_led gpio_leds[] = { { @@ -172,6 +174,37 @@ static struct regulator_consumer_supply omap4_panda_vmmc_supply[] = { }, }; +static struct regulator_consumer_supply omap4_panda_vmmc5_supply = { + .supply = "vmmc", + .dev_name = "mmci-omap-hs.4", +}; + +static struct regulator_init_data panda_vmmc5 = { + .constraints = { + .valid_ops_mask = REGULATOR_CHANGE_STATUS, + }, + .num_consumer_supplies = 1, + .consumer_supplies = &omap4_panda_vmmc5_supply, +}; + +static struct fixed_voltage_config panda_vwlan = { + .supply_name = "vwl1271", + .microvolts = 1800000, /* 1.8V */ + .gpio = GPIO_WIFI_PMENA, + .startup_delay = 70000, /* 70msec */ + .enable_high = 1, + .enabled_at_boot = 0, + .init_data = &panda_vmmc5, +}; + +static struct platform_device omap_vwlan_device = { + .name = "reg-fixed-voltage", + .id = 1, + .dev = { + .platform_data = &panda_vwlan, + }, +}; + static int omap4_twl6030_hsmmc_late_init(struct device *dev) { int ret = 0; @@ -430,6 +463,7 @@ static void __init omap4_panda_init(void) omap4_panda_i2c_init(); platform_add_devices(panda_devices, ARRAY_SIZE(panda_devices)); + platform_device_register(&omap_vwlan_device); omap_serial_init(); omap4_twl6030_hsmmc_init(mmc); /* OMAP4 Panda uses internal transceiver so register nop transceiver */ -- 1.5.6.3 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 4/5] omap: panda: add mmc5/wl1271 device support 2011-02-15 8:40 ` [PATCH v2 3/5] omap: panda: add fixed regulator device for wlan Panduranga Mallireddy @ 2011-02-15 8:40 ` Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 5/5] OMAP: hsmmc: Enable MMC4 and MMC5 on OMAP4 platforms Panduranga Mallireddy 0 siblings, 1 reply; 7+ messages in thread From: Panduranga Mallireddy @ 2011-02-15 8:40 UTC (permalink / raw) To: coelho, netdev, linux-omap, linux-mmc Cc: ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, tony, cjb, Panduranga Mallireddy Add MMC5 support on PANDA, which has the wl1271 device hardwired to. The wl1271 is a 4-wire, 1.8V, embedded SDIO WLAN device with an external IRQ line, and power-controlled by a GPIO-based fixed regulator. Based on the patch for mmc3/wl1271 device support for zoom by Ohad Ben-Cohen <ohad@wizery.com> Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com> --- arch/arm/mach-omap2/board-omap4panda.c | 20 ++++++++++++++++++++ 1 files changed, 20 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/board-omap4panda.c b/arch/arm/mach-omap2/board-omap4panda.c index cd25255..ef43010 100644 --- a/arch/arm/mach-omap2/board-omap4panda.c +++ b/arch/arm/mach-omap2/board-omap4panda.c @@ -27,6 +27,7 @@ #include <linux/i2c/twl.h> #include <linux/regulator/machine.h> #include <linux/regulator/fixed.h> +#include <linux/wl12xx.h> #include <mach/hardware.h> #include <mach/omap4-common.h> @@ -47,6 +48,7 @@ #define GPIO_HUB_POWER 1 #define GPIO_HUB_NRESET 62 #define GPIO_WIFI_PMENA 43 +#define GPIO_WIFI_IRQ 53 static struct gpio_led gpio_leds[] = { { @@ -164,6 +166,15 @@ static struct omap2_hsmmc_info mmc[] = { .gpio_wp = -EINVAL, .gpio_cd = -EINVAL, }, + { + .name = "wl1271", + .mmc = 5, + .caps = MMC_CAP_4_BIT_DATA | MMC_CAP_POWER_OFF_CARD, + .gpio_wp = -EINVAL, + .gpio_cd = -EINVAL, + .ocr_mask = MMC_VDD_165_195, + .nonremovable = true, + }, {} /* Terminator */ }; @@ -205,6 +216,12 @@ static struct platform_device omap_vwlan_device = { }, }; +struct wl12xx_platform_data omap_panda_wlan_data __initdata = { + .irq = OMAP_GPIO_IRQ(GPIO_WIFI_IRQ), + /* PANDA ref clock is 38.4 MHz */ + .board_ref_clock = 2, +}; + static int omap4_twl6030_hsmmc_late_init(struct device *dev) { int ret = 0; @@ -461,6 +478,9 @@ static void __init omap4_panda_init(void) package = OMAP_PACKAGE_CBL; omap4_mux_init(board_mux, package); + if (wl12xx_set_platform_data(&omap_panda_wlan_data)) + pr_err("error setting wl12xx data\n"); + omap4_panda_i2c_init(); platform_add_devices(panda_devices, ARRAY_SIZE(panda_devices)); platform_device_register(&omap_vwlan_device); -- 1.5.6.3 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v2 5/5] OMAP: hsmmc: Enable MMC4 and MMC5 on OMAP4 platforms 2011-02-15 8:40 ` [PATCH v2 4/5] omap: panda: add mmc5/wl1271 device support Panduranga Mallireddy @ 2011-02-15 8:40 ` Panduranga Mallireddy 0 siblings, 0 replies; 7+ messages in thread From: Panduranga Mallireddy @ 2011-02-15 8:40 UTC (permalink / raw) To: coelho, netdev, linux-omap, linux-mmc Cc: ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, tony, cjb, Kishore Kadiyala, Panduranga Mallireddy From: Kishore Kadiyala <kishore.kadiyala@ti.com> OMAP4 supports up to 5 MMC controllers, but only 3 of these were initialized. MMC5 is used by wl12xx chip. So initialize MMC4 and MMC5. Signed-off-by: Kishore Kadiyala <kishore.kadiyala@ti.com> Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com> --- arch/arm/mach-omap2/hsmmc.c | 5 +++++ drivers/mmc/host/omap_hsmmc.c | 24 ++++++++++++++++++++---- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/arch/arm/mach-omap2/hsmmc.c b/arch/arm/mach-omap2/hsmmc.c index 8f1a484..3c0809f 100644 --- a/arch/arm/mach-omap2/hsmmc.c +++ b/arch/arm/mach-omap2/hsmmc.c @@ -348,6 +348,11 @@ void __init omap2_hsmmc_init(struct omap2_hsmmc_info *controllers) mmc->slots[0].after_set_reg = NULL; } break; + case 4: + case 5: + mmc->slots[0].before_set_reg = NULL; + mmc->slots[0].after_set_reg = NULL; + break; default: pr_err("MMC%d configuration not supported!\n", c->mmc); kfree(mmc); diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index f59f8da..2525071 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c @@ -260,7 +260,7 @@ static int omap_hsmmc_1_set_power(struct device *dev, int slot, int power_on, return ret; } -static int omap_hsmmc_23_set_power(struct device *dev, int slot, int power_on, +static int omap_hsmmc_235_set_power(struct device *dev, int slot, int power_on, int vdd) { struct omap_hsmmc_host *host = @@ -316,6 +316,12 @@ static int omap_hsmmc_23_set_power(struct device *dev, int slot, int power_on, return ret; } +static int omap_hsmmc_4_set_power(struct device *dev, int slot, int power_on, + int vdd) +{ + return 0; +} + static int omap_hsmmc_1_set_sleep(struct device *dev, int slot, int sleep, int vdd, int cardsleep) { @@ -326,7 +332,7 @@ static int omap_hsmmc_1_set_sleep(struct device *dev, int slot, int sleep, return regulator_set_mode(host->vcc, mode); } -static int omap_hsmmc_23_set_sleep(struct device *dev, int slot, int sleep, +static int omap_hsmmc_235_set_sleep(struct device *dev, int slot, int sleep, int vdd, int cardsleep) { struct omap_hsmmc_host *host = @@ -365,6 +371,12 @@ static int omap_hsmmc_23_set_sleep(struct device *dev, int slot, int sleep, return regulator_enable(host->vcc_aux); } +static int omap_hsmmc_4_set_sleep(struct device *dev, int slot, int sleep, + int vdd, int cardsleep) +{ + return 0; +} + static int omap_hsmmc_reg_get(struct omap_hsmmc_host *host) { struct regulator *reg; @@ -379,10 +391,14 @@ static int omap_hsmmc_reg_get(struct omap_hsmmc_host *host) break; case OMAP_MMC2_DEVID: case OMAP_MMC3_DEVID: + case OMAP_MMC5_DEVID: /* Off-chip level shifting, or none */ - mmc_slot(host).set_power = omap_hsmmc_23_set_power; - mmc_slot(host).set_sleep = omap_hsmmc_23_set_sleep; + mmc_slot(host).set_power = omap_hsmmc_235_set_power; + mmc_slot(host).set_sleep = omap_hsmmc_235_set_sleep; break; + case OMAP_MMC4_DEVID: + mmc_slot(host).set_power = omap_hsmmc_4_set_power; + mmc_slot(host).set_sleep = omap_hsmmc_4_set_sleep; default: pr_err("MMC%d configuration not supported!\n", host->id); return -EINVAL; -- 1.5.6.3 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2 0/5] Panda: Support for WLAN on WL127x 2011-02-15 8:40 [PATCH v2 0/5] Panda: Support for WLAN on WL127x Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 1/5] omap: panda: wlan board muxing Panduranga Mallireddy @ 2011-02-18 0:03 ` Tony Lindgren 1 sibling, 0 replies; 7+ messages in thread From: Tony Lindgren @ 2011-02-18 0:03 UTC (permalink / raw) To: Panduranga Mallireddy Cc: coelho, netdev, linux-omap, linux-mmc, ohad, benzyg, pradeepgurumath, vishalm, x-boudet, naveen_jain, pavan_savoy, manjunatha_halli, cjb * Panduranga Mallireddy <panduranga_mallireddy@ti.com> [110215 00:13]: > Fixes from V1: > 1. Removing the pull up of WLAN IRQ line, since it is always held up by wl127x device. > > Adding support for WLAN on Panda board using wl12xx and mac80211 drivers Thanks, adding these to devel-board for the upcoming merge window. Tony ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2011-02-18 0:03 UTC | newest] Thread overview: 7+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-02-15 8:40 [PATCH v2 0/5] Panda: Support for WLAN on WL127x Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 1/5] omap: panda: wlan board muxing Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 2/5] omap: select REGULATOR_FIXED_VOLTAGE by default for panda and sdp4430 Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 3/5] omap: panda: add fixed regulator device for wlan Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 4/5] omap: panda: add mmc5/wl1271 device support Panduranga Mallireddy 2011-02-15 8:40 ` [PATCH v2 5/5] OMAP: hsmmc: Enable MMC4 and MMC5 on OMAP4 platforms Panduranga Mallireddy 2011-02-18 0:03 ` [PATCH v2 0/5] Panda: Support for WLAN on WL127x Tony Lindgren
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).