Re: [PATCH v2 10/20] omap: zoom: add fixed regulator device for wlan
On Fri, Jul 23, 2010 at 12:15 PM, Mark Brown broo...@opensource.wolfsonmicro.com wrote: On Fri, Jul 23, 2010 at 02:13:38AM +0300, Ohad Ben-Cohen wrote: On Thu, Jul 22, 2010 at 2:16 PM, Roger Quadros roger.quad...@nokia.com wrote: .dev_name = mmci-omap-hs.2 I already set the .dev member of the consumer in a similar manner to how all other regulators are configured in this board - please check out patch 13: https://patchwork.kernel.org/patch/113418/ Does this look reasonable to you ? You should really be using dev_name in preference to dev these days unless there's a *very* good reason. Changed, thank you. I'll submit the updated patch now as a standalone patch as it has no dependencies on the whole series, and it could only help to start trimming that series down. -- To unsubscribe from this list: send the line unsubscribe linux-omap in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 10/20] omap: zoom: add fixed regulator device for wlan
On Fri, Jul 23, 2010 at 02:13:38AM +0300, Ohad Ben-Cohen wrote: On Thu, Jul 22, 2010 at 2:16 PM, Roger Quadros roger.quad...@nokia.com wrote: .dev_name = mmci-omap-hs.2 I already set the .dev member of the consumer in a similar manner to how all other regulators are configured in this board - please check out patch 13: https://patchwork.kernel.org/patch/113418/ Does this look reasonable to you ? You should really be using dev_name in preference to dev these days unless there's a *very* good reason. -- To unsubscribe from this list: send the line unsubscribe linux-omap in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 10/20] omap: zoom: add fixed regulator device for wlan
On 07/21/2010 08:59 PM, ext Mark Brown wrote: On Wed, Jul 21, 2010 at 08:33:44PM +0300, Ohad Ben-Cohen wrote: +static struct regulator_consumer_supply zoom_vmmc3_supply = { + .supply = vmmc, +}; This looks like a misconfiguration on the consumer - I'd strongly expect the consumer to have a dev_name specified also with the name being in terms of the consumer device. you need to add something like .dev_name = mmci-omap-hs.2 regards, -roger -- To unsubscribe from this list: send the line unsubscribe linux-omap in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 10/20] omap: zoom: add fixed regulator device for wlan
On Thu, Jul 22, 2010 at 2:16 PM, Roger Quadros roger.quad...@nokia.com wrote: On 07/21/2010 08:59 PM, ext Mark Brown wrote: On Wed, Jul 21, 2010 at 08:33:44PM +0300, Ohad Ben-Cohen wrote: +static struct regulator_consumer_supply zoom_vmmc3_supply = { + .supply = vmmc, +}; This looks like a misconfiguration on the consumer - I'd strongly expect the consumer to have a dev_name specified also with the name being in terms of the consumer device. you need to add something like .dev_name = mmci-omap-hs.2 I already set the .dev member of the consumer in a similar manner to how all other regulators are configured in this board - please check out patch 13: https://patchwork.kernel.org/patch/113418/ Does this look reasonable to you ? Thanks, Ohad. regards, -roger -- To unsubscribe from this list: send the line unsubscribe linux-omap in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH v2 10/20] omap: zoom: add fixed regulator device for wlan
Add a fixed regulator vmmc device to enable power control of the wl1271 wlan device. Signed-off-by: Ohad Ben-Cohen o...@wizery.com --- arch/arm/mach-omap2/board-zoom-peripherals.c | 34 ++ 1 files changed, 34 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/board-zoom-peripherals.c b/arch/arm/mach-omap2/board-zoom-peripherals.c index 6b39849..2fc0f4a 100644 --- a/arch/arm/mach-omap2/board-zoom-peripherals.c +++ b/arch/arm/mach-omap2/board-zoom-peripherals.c @@ -16,6 +16,7 @@ #include linux/gpio.h #include linux/i2c/twl.h #include linux/regulator/machine.h +#include linux/regulator/fixed.h #include asm/mach-types.h #include asm/mach/arch.h @@ -27,6 +28,8 @@ #include mux.h #include hsmmc.h +#define OMAP_ZOOM_WLAN_PMENA_GPIO (101) + /* Zoom2 has Qwerty keyboard*/ static int board_keymap[] = { KEY(0, 0, KEY_E), @@ -106,6 +109,10 @@ static struct regulator_consumer_supply zoom_vmmc2_supply = { .supply = vmmc, }; +static struct regulator_consumer_supply zoom_vmmc3_supply = { + .supply = vmmc, +}; + /* VMMC1 for OMAP VDD_MMC1 (i/o) and MMC1 card */ static struct regulator_init_data zoom_vmmc1 = { .constraints = { @@ -151,6 +158,32 @@ static struct regulator_init_data zoom_vsim = { .consumer_supplies = zoom_vsim_supply, }; +static struct regulator_init_data zoom_vmmc3 = { + .constraints = { + .valid_ops_mask = REGULATOR_CHANGE_STATUS, + }, + .num_consumer_supplies = 1, + .consumer_supplies = zoom_vmmc3_supply, +}; + +static struct fixed_voltage_config zoom_vwlan = { + .supply_name = vwl1271, + .microvolts = 180, /* 1.8V */ + .gpio = OMAP_ZOOM_WLAN_PMENA_GPIO, + .startup_delay = 7, /* 70msec */ + .enable_high = 1, + .enabled_at_boot = 0, + .init_data = zoom_vmmc3, +}; + +static struct platform_device omap_vwlan_device = { + .name = reg-fixed-voltage, + .id = 1, + .dev = { + .platform_data = zoom_vwlan, + }, +}; + static struct omap2_hsmmc_info mmc[] __initdata = { { .name = external, @@ -280,6 +313,7 @@ static void enable_board_wakeup_source(void) void __init zoom_peripherals_init(void) { omap_i2c_init(); + platform_device_register(omap_vwlan_device); usb_musb_init(musb_board_data); enable_board_wakeup_source(); } -- 1.7.0.4 -- To unsubscribe from this list: send the line unsubscribe linux-omap in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2 10/20] omap: zoom: add fixed regulator device for wlan
On Wed, Jul 21, 2010 at 08:33:44PM +0300, Ohad Ben-Cohen wrote: +static struct regulator_consumer_supply zoom_vmmc3_supply = { + .supply = vmmc, +}; This looks like a misconfiguration on the consumer - I'd strongly expect the consumer to have a dev_name specified also with the name being in terms of the consumer device. -- To unsubscribe from this list: send the line unsubscribe linux-omap in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html