* [PATCH] ARM: pxa/raumfeld: board support cleanups
@ 2009-12-06 10:28 Daniel Mack
2009-12-10 0:30 ` Daniel Mack
2009-12-10 4:08 ` Eric Miao
0 siblings, 2 replies; 6+ messages in thread
From: Daniel Mack @ 2009-12-06 10:28 UTC (permalink / raw)
To: linux-arm-kernel
Some minor things that I didn't notice in the original post.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Eric Miao <eric.y.miao@gmail.com>
---
arch/arm/mach-pxa/raumfeld.c | 53 +++++++++++++++++++----------------------
1 files changed, 25 insertions(+), 28 deletions(-)
diff --git a/arch/arm/mach-pxa/raumfeld.c b/arch/arm/mach-pxa/raumfeld.c
index f8457bb..7b33bca 100644
--- a/arch/arm/mach-pxa/raumfeld.c
+++ b/arch/arm/mach-pxa/raumfeld.c
@@ -584,8 +584,6 @@ static struct pxafb_mach_info raumfeld_sharp_lcd_info = {
.lcd_conn = LCD_COLOR_TFT_16BPP | LCD_PCLK_EDGE_FALL,
};
-static int gpio_display_enable = GPIO_DISPLAY_ENABLE;
-
static void __init raumfeld_lcd_init(void)
{
int ret;
@@ -611,7 +609,7 @@ static void __init raumfeld_lcd_init(void)
if (ret < 0)
pr_warning("Unable to request GPIO_DISPLAY_ENABLE\n");
else
- gpio_direction_output(gpio_display_enable, 1);
+ gpio_direction_output(GPIO_DISPLAY_ENABLE, 1);
}
/**
@@ -693,14 +691,23 @@ static struct spi_board_info controller_spi_devices[] __initdata = {
* MMC for Marvell Libertas 8688 via SDIO
*/
-static void raumfeld_mci_setpower(struct device *dev, unsigned int on)
+static int raumfeld_mci_init(struct device *dev, irq_handler_t isr, void *data)
+{
+ gpio_set_value(GPIO_W2W_RESET, 1);
+ gpio_set_value(GPIO_W2W_PDN, 1);
+
+ return 0;
+}
+
+static void raumfeld_mci_exit(struct device *dev, void *data)
{
- gpio_set_value(GPIO_W2W_RESET, on);
- gpio_set_value(GPIO_W2W_PDN, on);
+ gpio_set_value(GPIO_W2W_RESET, 0);
+ gpio_set_value(GPIO_W2W_PDN, 0);
}
static struct pxamci_platform_data raumfeld_mci_platform_data = {
- .setpower = raumfeld_mci_setpower,
+ .init = raumfeld_mci_init,
+ .exit = raumfeld_mci_exit,
.detect_delay = 20,
.gpio_card_detect = -1,
.gpio_card_ro = -1,
@@ -711,9 +718,6 @@ static struct pxamci_platform_data raumfeld_mci_platform_data = {
* External power / charge logic
*/
-static int gpio_charge_dc_ok;
-static int gpio_charge_usb_susp;
-
static int power_supply_init(struct device *dev)
{
return 0;
@@ -725,7 +729,7 @@ static void power_supply_exit(struct device *dev)
static int raumfeld_is_ac_online(void)
{
- return !gpio_get_value(gpio_charge_dc_ok);
+ return !gpio_get_value(GPIO_CHARGE_DC_OK);
}
static int raumfeld_is_usb_online(void)
@@ -787,21 +791,18 @@ static void __init raumfeld_power_init(void)
else
gpio_direction_output(GPIO_CHRG_PEN2, 1);
- gpio_charge_dc_ok = GPIO_CHARGE_DC_OK;
- gpio_charge_usb_susp = GPIO_CHARGE_USB_SUSP;
-
- ret = gpio_request(gpio_charge_dc_ok, "CABLE_DC_OK");
+ ret = gpio_request(GPIO_CHARGE_DC_OK, "CABLE_DC_OK");
if (ret < 0)
pr_warning("Unable to request GPIO_CHARGE_DC_OK\n");
- ret = gpio_request(gpio_charge_usb_susp, "CHARGE_USB_SUSP");
+ ret = gpio_request(GPIO_CHARGE_USB_SUSP, "CHARGE_USB_SUSP");
if (ret < 0)
pr_warning("Unable to request GPIO_CHARGE_USB_SUSP\n");
else
- gpio_direction_output(gpio_charge_usb_susp, 0);
+ gpio_direction_output(GPIO_CHARGE_USB_SUSP, 0);
- power_supply_resources[0].start = gpio_to_irq(gpio_charge_dc_ok);
- power_supply_resources[0].end = gpio_to_irq(gpio_charge_dc_ok);
+ power_supply_resources[0].start = gpio_to_irq(GPIO_CHARGE_DC_OK);
+ power_supply_resources[0].end = gpio_to_irq(GPIO_CHARGE_DC_OK);
ret = request_irq(gpio_to_irq(GPIO_CHARGE_DONE),
&charge_done_irq, IORESOURCE_IRQ_LOWEDGE,
@@ -920,11 +921,9 @@ static struct i2c_board_info raumfeld_pwri2c_board_info = {
.platform_data = &max8660_pdata,
};
-static struct i2c_board_info raumfeld_connector_i2c_board_info[] __initdata = {
- {
- .type = "cs4270",
- .addr = 0x48,
- },
+static struct i2c_board_info raumfeld_connector_i2c_board_info __initdata = {
+ .type = "cs4270",
+ .addr = 0x48,
};
static struct eeti_ts_platform_data eeti_ts_pdata = {
@@ -1040,8 +1039,7 @@ static void __init raumfeld_connector_init(void)
{
pxa3xx_mfp_config(ARRAY_AND_SIZE(raumfeld_connector_pin_config));
spi_register_board_info(ARRAY_AND_SIZE(connector_spi_devices));
- i2c_register_board_info(0,
- ARRAY_AND_SIZE(raumfeld_connector_i2c_board_info));
+ i2c_register_board_info(0, &raumfeld_connector_i2c_board_info, 1);
platform_device_register(&smc91x_device);
@@ -1053,8 +1051,7 @@ static void __init raumfeld_speaker_init(void)
{
pxa3xx_mfp_config(ARRAY_AND_SIZE(raumfeld_speaker_pin_config));
spi_register_board_info(ARRAY_AND_SIZE(speaker_spi_devices));
- i2c_register_board_info(0,
- ARRAY_AND_SIZE(raumfeld_connector_i2c_board_info));
+ i2c_register_board_info(0, &raumfeld_connector_i2c_board_info, 1);
platform_device_register(&smc91x_device);
platform_device_register(&rotary_encoder_device);
--
1.6.5.2
^ permalink raw reply related [flat|nested] 6+ messages in thread* [PATCH] ARM: pxa/raumfeld: board support cleanups
2009-12-06 10:28 [PATCH] ARM: pxa/raumfeld: board support cleanups Daniel Mack
@ 2009-12-10 0:30 ` Daniel Mack
2009-12-10 4:08 ` Eric Miao
1 sibling, 0 replies; 6+ messages in thread
From: Daniel Mack @ 2009-12-10 0:30 UTC (permalink / raw)
To: linux-arm-kernel
Hi Eric,
On Sun, Dec 06, 2009 at 11:28:21AM +0100, Daniel Mack wrote:
> Some minor things that I didn't notice in the original post.
>
> Signed-off-by: Daniel Mack <daniel@caiaq.de>
> Cc: Eric Miao <eric.y.miao@gmail.com>
Would be good if that one made it in, too.
In case your 'pending' branch is not being tracked by anyone, you can
also squash this into the original commit if you like.
Thanks,
Daniel
> ---
> arch/arm/mach-pxa/raumfeld.c | 53 +++++++++++++++++++----------------------
> 1 files changed, 25 insertions(+), 28 deletions(-)
>
> diff --git a/arch/arm/mach-pxa/raumfeld.c b/arch/arm/mach-pxa/raumfeld.c
> index f8457bb..7b33bca 100644
> --- a/arch/arm/mach-pxa/raumfeld.c
> +++ b/arch/arm/mach-pxa/raumfeld.c
> @@ -584,8 +584,6 @@ static struct pxafb_mach_info raumfeld_sharp_lcd_info = {
> .lcd_conn = LCD_COLOR_TFT_16BPP | LCD_PCLK_EDGE_FALL,
> };
>
> -static int gpio_display_enable = GPIO_DISPLAY_ENABLE;
> -
> static void __init raumfeld_lcd_init(void)
> {
> int ret;
> @@ -611,7 +609,7 @@ static void __init raumfeld_lcd_init(void)
> if (ret < 0)
> pr_warning("Unable to request GPIO_DISPLAY_ENABLE\n");
> else
> - gpio_direction_output(gpio_display_enable, 1);
> + gpio_direction_output(GPIO_DISPLAY_ENABLE, 1);
> }
>
> /**
> @@ -693,14 +691,23 @@ static struct spi_board_info controller_spi_devices[] __initdata = {
> * MMC for Marvell Libertas 8688 via SDIO
> */
>
> -static void raumfeld_mci_setpower(struct device *dev, unsigned int on)
> +static int raumfeld_mci_init(struct device *dev, irq_handler_t isr, void *data)
> +{
> + gpio_set_value(GPIO_W2W_RESET, 1);
> + gpio_set_value(GPIO_W2W_PDN, 1);
> +
> + return 0;
> +}
> +
> +static void raumfeld_mci_exit(struct device *dev, void *data)
> {
> - gpio_set_value(GPIO_W2W_RESET, on);
> - gpio_set_value(GPIO_W2W_PDN, on);
> + gpio_set_value(GPIO_W2W_RESET, 0);
> + gpio_set_value(GPIO_W2W_PDN, 0);
> }
>
> static struct pxamci_platform_data raumfeld_mci_platform_data = {
> - .setpower = raumfeld_mci_setpower,
> + .init = raumfeld_mci_init,
> + .exit = raumfeld_mci_exit,
> .detect_delay = 20,
> .gpio_card_detect = -1,
> .gpio_card_ro = -1,
> @@ -711,9 +718,6 @@ static struct pxamci_platform_data raumfeld_mci_platform_data = {
> * External power / charge logic
> */
>
> -static int gpio_charge_dc_ok;
> -static int gpio_charge_usb_susp;
> -
> static int power_supply_init(struct device *dev)
> {
> return 0;
> @@ -725,7 +729,7 @@ static void power_supply_exit(struct device *dev)
>
> static int raumfeld_is_ac_online(void)
> {
> - return !gpio_get_value(gpio_charge_dc_ok);
> + return !gpio_get_value(GPIO_CHARGE_DC_OK);
> }
>
> static int raumfeld_is_usb_online(void)
> @@ -787,21 +791,18 @@ static void __init raumfeld_power_init(void)
> else
> gpio_direction_output(GPIO_CHRG_PEN2, 1);
>
> - gpio_charge_dc_ok = GPIO_CHARGE_DC_OK;
> - gpio_charge_usb_susp = GPIO_CHARGE_USB_SUSP;
> -
> - ret = gpio_request(gpio_charge_dc_ok, "CABLE_DC_OK");
> + ret = gpio_request(GPIO_CHARGE_DC_OK, "CABLE_DC_OK");
> if (ret < 0)
> pr_warning("Unable to request GPIO_CHARGE_DC_OK\n");
>
> - ret = gpio_request(gpio_charge_usb_susp, "CHARGE_USB_SUSP");
> + ret = gpio_request(GPIO_CHARGE_USB_SUSP, "CHARGE_USB_SUSP");
> if (ret < 0)
> pr_warning("Unable to request GPIO_CHARGE_USB_SUSP\n");
> else
> - gpio_direction_output(gpio_charge_usb_susp, 0);
> + gpio_direction_output(GPIO_CHARGE_USB_SUSP, 0);
>
> - power_supply_resources[0].start = gpio_to_irq(gpio_charge_dc_ok);
> - power_supply_resources[0].end = gpio_to_irq(gpio_charge_dc_ok);
> + power_supply_resources[0].start = gpio_to_irq(GPIO_CHARGE_DC_OK);
> + power_supply_resources[0].end = gpio_to_irq(GPIO_CHARGE_DC_OK);
>
> ret = request_irq(gpio_to_irq(GPIO_CHARGE_DONE),
> &charge_done_irq, IORESOURCE_IRQ_LOWEDGE,
> @@ -920,11 +921,9 @@ static struct i2c_board_info raumfeld_pwri2c_board_info = {
> .platform_data = &max8660_pdata,
> };
>
> -static struct i2c_board_info raumfeld_connector_i2c_board_info[] __initdata = {
> - {
> - .type = "cs4270",
> - .addr = 0x48,
> - },
> +static struct i2c_board_info raumfeld_connector_i2c_board_info __initdata = {
> + .type = "cs4270",
> + .addr = 0x48,
> };
>
> static struct eeti_ts_platform_data eeti_ts_pdata = {
> @@ -1040,8 +1039,7 @@ static void __init raumfeld_connector_init(void)
> {
> pxa3xx_mfp_config(ARRAY_AND_SIZE(raumfeld_connector_pin_config));
> spi_register_board_info(ARRAY_AND_SIZE(connector_spi_devices));
> - i2c_register_board_info(0,
> - ARRAY_AND_SIZE(raumfeld_connector_i2c_board_info));
> + i2c_register_board_info(0, &raumfeld_connector_i2c_board_info, 1);
>
> platform_device_register(&smc91x_device);
>
> @@ -1053,8 +1051,7 @@ static void __init raumfeld_speaker_init(void)
> {
> pxa3xx_mfp_config(ARRAY_AND_SIZE(raumfeld_speaker_pin_config));
> spi_register_board_info(ARRAY_AND_SIZE(speaker_spi_devices));
> - i2c_register_board_info(0,
> - ARRAY_AND_SIZE(raumfeld_connector_i2c_board_info));
> + i2c_register_board_info(0, &raumfeld_connector_i2c_board_info, 1);
>
> platform_device_register(&smc91x_device);
> platform_device_register(&rotary_encoder_device);
> --
> 1.6.5.2
>
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH] ARM: pxa/raumfeld: board support cleanups
2009-12-06 10:28 [PATCH] ARM: pxa/raumfeld: board support cleanups Daniel Mack
2009-12-10 0:30 ` Daniel Mack
@ 2009-12-10 4:08 ` Eric Miao
2009-12-16 13:38 ` Eric Miao
1 sibling, 1 reply; 6+ messages in thread
From: Eric Miao @ 2009-12-10 4:08 UTC (permalink / raw)
To: linux-arm-kernel
On Sun, Dec 6, 2009 at 6:28 PM, Daniel Mack <daniel@caiaq.de> wrote:
> Some minor things that I didn't notice in the original post.
>
> Signed-off-by: Daniel Mack <daniel@caiaq.de>
> Cc: Eric Miao <eric.y.miao@gmail.com>
Merged into 'pending'. Will be pushed out til max8660 stuffs are merged.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] ARM: pxa/raumfeld: board support cleanups
2009-12-10 4:08 ` Eric Miao
@ 2009-12-16 13:38 ` Eric Miao
2009-12-16 14:49 ` Daniel Mack
0 siblings, 1 reply; 6+ messages in thread
From: Eric Miao @ 2009-12-16 13:38 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, Dec 10, 2009 at 12:08 PM, Eric Miao <eric.y.miao@gmail.com> wrote:
> On Sun, Dec 6, 2009 at 6:28 PM, Daniel Mack <daniel@caiaq.de> wrote:
>> Some minor things that I didn't notice in the original post.
>>
>> Signed-off-by: Daniel Mack <daniel@caiaq.de>
>> Cc: Eric Miao <eric.y.miao@gmail.com>
>
> Merged into 'pending'. Will be pushed out til max8660 stuffs are merged.
>
Daniel,
Do you know when will max8660 be merged? The window is about to
close, but nothing appear to be there about this max8660?
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] ARM: pxa/raumfeld: board support cleanups
2009-12-16 13:38 ` Eric Miao
@ 2009-12-16 14:49 ` Daniel Mack
2009-12-16 15:01 ` Liam Girdwood
0 siblings, 1 reply; 6+ messages in thread
From: Daniel Mack @ 2009-12-16 14:49 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Dec 16, 2009 at 09:38:35PM +0800, Eric Miao wrote:
> On Thu, Dec 10, 2009 at 12:08 PM, Eric Miao <eric.y.miao@gmail.com> wrote:
> > On Sun, Dec 6, 2009 at 6:28 PM, Daniel Mack <daniel@caiaq.de> wrote:
> >> Some minor things that I didn't notice in the original post.
> >>
> >> Signed-off-by: Daniel Mack <daniel@caiaq.de>
> >> Cc: Eric Miao <eric.y.miao@gmail.com>
> >
> > Merged into 'pending'. Will be pushed out til max8660 stuffs are merged.
> >
>
> Daniel,
>
> Do you know when will max8660 be merged? The window is about to
> close, but nothing appear to be there about this max8660?
I don't know. The driver has been queued in regulator-2.6.git:
http://git.kernel.org/?p=linux/kernel/git/broonie/regulator-2.6.git;a=commit;h=9c4d460f13b7d81abb26449a3920638889a3e5ed
Mark, Liam, any idea when things will hit the tree?
Thanks,
Daniel
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] ARM: pxa/raumfeld: board support cleanups
2009-12-16 14:49 ` Daniel Mack
@ 2009-12-16 15:01 ` Liam Girdwood
0 siblings, 0 replies; 6+ messages in thread
From: Liam Girdwood @ 2009-12-16 15:01 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, 2009-12-16 at 22:49 +0800, Daniel Mack wrote:
> On Wed, Dec 16, 2009 at 09:38:35PM +0800, Eric Miao wrote:
> > On Thu, Dec 10, 2009 at 12:08 PM, Eric Miao <eric.y.miao@gmail.com> wrote:
> > > On Sun, Dec 6, 2009 at 6:28 PM, Daniel Mack <daniel@caiaq.de> wrote:
> > >> Some minor things that I didn't notice in the original post.
> > >>
> > >> Signed-off-by: Daniel Mack <daniel@caiaq.de>
> > >> Cc: Eric Miao <eric.y.miao@gmail.com>
> > >
> > > Merged into 'pending'. Will be pushed out til max8660 stuffs are merged.
> > >
> >
> > Daniel,
> >
> > Do you know when will max8660 be merged? The window is about to
> > close, but nothing appear to be there about this max8660?
>
> I don't know. The driver has been queued in regulator-2.6.git:
>
> http://git.kernel.org/?p=linux/kernel/git/broonie/regulator-2.6.git;a=commit;h=9c4d460f13b7d81abb26449a3920638889a3e5ed
>
> Mark, Liam, any idea when things will hit the tree?
I'll be issuing a pull request tomorrow am.
Sorry about all this, there have been some "issues" lately with the twl
pmic rename that have slowed things down with regulator and mfd.
Liam
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2009-12-16 15:01 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-06 10:28 [PATCH] ARM: pxa/raumfeld: board support cleanups Daniel Mack
2009-12-10 0:30 ` Daniel Mack
2009-12-10 4:08 ` Eric Miao
2009-12-16 13:38 ` Eric Miao
2009-12-16 14:49 ` Daniel Mack
2009-12-16 15:01 ` Liam Girdwood
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).