From: sameo@linux.intel.com (Samuel Ortiz)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/3] ab8500-mfd: add regulator support to ab8500 mfd device
Date: Wed, 14 Jul 2010 12:13:31 +0200 [thread overview]
Message-ID: <20100714101330.GD2771@sortiz-mobl> (raw)
In-Reply-To: <1279002090-11234-2-git-send-email-sundar.iyer@stericsson.com>
On Tue, Jul 13, 2010 at 11:51:28AM +0530, Sundar Iyer wrote:
> From: Sundar R Iyer <sundar.iyer@stericsson.com>
>
> Acked-by: Linus Walleij <linus.walleij@stericsson.com>
> Acked-By: Mattias Wallin <mattias.wallin@stericsson.com>
> Acked-By: Bengt JONSSON <bengt.g.jonsson@stericsson.com>
> Signed-off-by: Sundar R Iyer <sundar.iyer@stericsson.com>
Liam, I guess this should make it upstream through your regulator tree.
For the mfd part though:
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Cheers,
Samuel.
> ---
> drivers/mfd/ab8500-core.c | 4 +++-
> include/linux/mfd/ab8500.h | 6 ++++++
> include/linux/regulator/ab8500.h | 25 +++++++++++++++++++++++++
> 3 files changed, 34 insertions(+), 1 deletions(-)
> create mode 100644 include/linux/regulator/ab8500.h
>
> diff --git a/drivers/mfd/ab8500-core.c b/drivers/mfd/ab8500-core.c
> index f3d26fa..defa786 100644
> --- a/drivers/mfd/ab8500-core.c
> +++ b/drivers/mfd/ab8500-core.c
> @@ -16,6 +16,7 @@
> #include <linux/platform_device.h>
> #include <linux/mfd/core.h>
> #include <linux/mfd/ab8500.h>
> +#include <linux/regulator/ab8500.h>
>
> /*
> * Interrupt register offsets
> @@ -352,6 +353,7 @@ static struct mfd_cell ab8500_devs[] = {
> { .name = "ab8500-audio", },
> { .name = "ab8500-usb", },
> { .name = "ab8500-pwm", },
> + { .name = "ab8500-regulator", },
> };
>
> int __devinit ab8500_init(struct ab8500 *ab8500)
> @@ -411,7 +413,7 @@ int __devinit ab8500_init(struct ab8500 *ab8500)
> goto out_removeirq;
> }
>
> - ret = mfd_add_devices(ab8500->dev, -1, ab8500_devs,
> + ret = mfd_add_devices(ab8500->dev, 0, ab8500_devs,
> ARRAY_SIZE(ab8500_devs), NULL,
> ab8500->irq_base);
> if (ret)
> diff --git a/include/linux/mfd/ab8500.h b/include/linux/mfd/ab8500.h
> index b63ff3b..f5cec45 100644
> --- a/include/linux/mfd/ab8500.h
> +++ b/include/linux/mfd/ab8500.h
> @@ -76,6 +76,8 @@
> #define AB8500_NR_IRQS 104
> #define AB8500_NUM_IRQ_REGS 13
>
> +#define AB8500_NUM_REGULATORS 15
> +
> /**
> * struct ab8500 - ab8500 internal structure
> * @dev: parent device
> @@ -108,14 +110,18 @@ struct ab8500 {
> u8 oldmask[AB8500_NUM_IRQ_REGS];
> };
>
> +struct regulator_init_data;
> +
> /**
> * struct ab8500_platform_data - AB8500 platform data
> * @irq_base: start of AB8500 IRQs, AB8500_NR_IRQS will be used
> * @init: board-specific initialization after detection of ab8500
> + * @regulator: machine-specific constraints for regulators
> */
> struct ab8500_platform_data {
> int irq_base;
> void (*init) (struct ab8500 *);
> + struct regulator_init_data *regulator[AB8500_NUM_REGULATORS];
> };
>
> extern int ab8500_write(struct ab8500 *a8500, u16 addr, u8 data);
> diff --git a/include/linux/regulator/ab8500.h b/include/linux/regulator/ab8500.h
> new file mode 100644
> index 0000000..f509877
> --- /dev/null
> +++ b/include/linux/regulator/ab8500.h
> @@ -0,0 +1,25 @@
> +/*
> + * Copyright (C) ST-Ericsson SA 2010
> + *
> + * License Terms: GNU General Public License v2
> + *
> + * Author: Sundar Iyer <sundar.iyer@stericsson.com> for ST-Ericsson
> + *
> + */
> +
> +#ifndef __LINUX_MFD_AB8500_REGULATOR_H
> +#define __LINUX_MFD_AB8500_REGULATOR_H
> +
> +/* AB8500 regulators */
> +#define AB8500_LDO_AUX1 0
> +#define AB8500_LDO_AUX2 1
> +#define AB8500_LDO_AUX3 2
> +#define AB8500_LDO_INTCORE 3
> +#define AB8500_LDO_TVOUT 4
> +#define AB8500_LDO_AUDIO 5
> +#define AB8500_LDO_ANAMIC1 6
> +#define AB8500_LDO_ANAMIC2 7
> +#define AB8500_LDO_DMIC 8
> +#define AB8500_LDO_ANA 9
> +
> +#endif
> --
> 1.7.0
>
--
Intel Open Source Technology Centre
http://oss.intel.com/
WARNING: multiple messages have this Message-ID (diff)
From: Samuel Ortiz <sameo@linux.intel.com>
To: Sundar Iyer <sundar.iyer@stericsson.com>, lrg@slimlogic.co.uk
Cc: broonie@opensource.wolfsonmicro.com,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
STEricsson_nomadik_linux@list.st.com,
Linus Walleij <linus.walleij@stericsson.com>,
"Acked-By: Mattias Wallin" <mattias.wallin@stericsson.com>,
"Acked-By: Bengt JONSSON" <bengt.g.jonsson@stericsson.com>
Subject: Re: [PATCH 1/3] ab8500-mfd: add regulator support to ab8500 mfd device
Date: Wed, 14 Jul 2010 12:13:31 +0200 [thread overview]
Message-ID: <20100714101330.GD2771@sortiz-mobl> (raw)
In-Reply-To: <1279002090-11234-2-git-send-email-sundar.iyer@stericsson.com>
On Tue, Jul 13, 2010 at 11:51:28AM +0530, Sundar Iyer wrote:
> From: Sundar R Iyer <sundar.iyer@stericsson.com>
>
> Acked-by: Linus Walleij <linus.walleij@stericsson.com>
> Acked-By: Mattias Wallin <mattias.wallin@stericsson.com>
> Acked-By: Bengt JONSSON <bengt.g.jonsson@stericsson.com>
> Signed-off-by: Sundar R Iyer <sundar.iyer@stericsson.com>
Liam, I guess this should make it upstream through your regulator tree.
For the mfd part though:
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Cheers,
Samuel.
> ---
> drivers/mfd/ab8500-core.c | 4 +++-
> include/linux/mfd/ab8500.h | 6 ++++++
> include/linux/regulator/ab8500.h | 25 +++++++++++++++++++++++++
> 3 files changed, 34 insertions(+), 1 deletions(-)
> create mode 100644 include/linux/regulator/ab8500.h
>
> diff --git a/drivers/mfd/ab8500-core.c b/drivers/mfd/ab8500-core.c
> index f3d26fa..defa786 100644
> --- a/drivers/mfd/ab8500-core.c
> +++ b/drivers/mfd/ab8500-core.c
> @@ -16,6 +16,7 @@
> #include <linux/platform_device.h>
> #include <linux/mfd/core.h>
> #include <linux/mfd/ab8500.h>
> +#include <linux/regulator/ab8500.h>
>
> /*
> * Interrupt register offsets
> @@ -352,6 +353,7 @@ static struct mfd_cell ab8500_devs[] = {
> { .name = "ab8500-audio", },
> { .name = "ab8500-usb", },
> { .name = "ab8500-pwm", },
> + { .name = "ab8500-regulator", },
> };
>
> int __devinit ab8500_init(struct ab8500 *ab8500)
> @@ -411,7 +413,7 @@ int __devinit ab8500_init(struct ab8500 *ab8500)
> goto out_removeirq;
> }
>
> - ret = mfd_add_devices(ab8500->dev, -1, ab8500_devs,
> + ret = mfd_add_devices(ab8500->dev, 0, ab8500_devs,
> ARRAY_SIZE(ab8500_devs), NULL,
> ab8500->irq_base);
> if (ret)
> diff --git a/include/linux/mfd/ab8500.h b/include/linux/mfd/ab8500.h
> index b63ff3b..f5cec45 100644
> --- a/include/linux/mfd/ab8500.h
> +++ b/include/linux/mfd/ab8500.h
> @@ -76,6 +76,8 @@
> #define AB8500_NR_IRQS 104
> #define AB8500_NUM_IRQ_REGS 13
>
> +#define AB8500_NUM_REGULATORS 15
> +
> /**
> * struct ab8500 - ab8500 internal structure
> * @dev: parent device
> @@ -108,14 +110,18 @@ struct ab8500 {
> u8 oldmask[AB8500_NUM_IRQ_REGS];
> };
>
> +struct regulator_init_data;
> +
> /**
> * struct ab8500_platform_data - AB8500 platform data
> * @irq_base: start of AB8500 IRQs, AB8500_NR_IRQS will be used
> * @init: board-specific initialization after detection of ab8500
> + * @regulator: machine-specific constraints for regulators
> */
> struct ab8500_platform_data {
> int irq_base;
> void (*init) (struct ab8500 *);
> + struct regulator_init_data *regulator[AB8500_NUM_REGULATORS];
> };
>
> extern int ab8500_write(struct ab8500 *a8500, u16 addr, u8 data);
> diff --git a/include/linux/regulator/ab8500.h b/include/linux/regulator/ab8500.h
> new file mode 100644
> index 0000000..f509877
> --- /dev/null
> +++ b/include/linux/regulator/ab8500.h
> @@ -0,0 +1,25 @@
> +/*
> + * Copyright (C) ST-Ericsson SA 2010
> + *
> + * License Terms: GNU General Public License v2
> + *
> + * Author: Sundar Iyer <sundar.iyer@stericsson.com> for ST-Ericsson
> + *
> + */
> +
> +#ifndef __LINUX_MFD_AB8500_REGULATOR_H
> +#define __LINUX_MFD_AB8500_REGULATOR_H
> +
> +/* AB8500 regulators */
> +#define AB8500_LDO_AUX1 0
> +#define AB8500_LDO_AUX2 1
> +#define AB8500_LDO_AUX3 2
> +#define AB8500_LDO_INTCORE 3
> +#define AB8500_LDO_TVOUT 4
> +#define AB8500_LDO_AUDIO 5
> +#define AB8500_LDO_ANAMIC1 6
> +#define AB8500_LDO_ANAMIC2 7
> +#define AB8500_LDO_DMIC 8
> +#define AB8500_LDO_ANA 9
> +
> +#endif
> --
> 1.7.0
>
--
Intel Open Source Technology Centre
http://oss.intel.com/
next prev parent reply other threads:[~2010-07-14 10:13 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-13 6:21 [PATCH 0/3] ab8500-mfd: add regulator support Sundar Iyer
2010-07-13 6:21 ` Sundar Iyer
2010-07-13 6:21 ` [PATCH 1/3] ab8500-mfd: add regulator support to ab8500 mfd device Sundar Iyer
2010-07-13 6:21 ` Sundar Iyer
2010-07-13 9:49 ` Mark Brown
2010-07-13 9:49 ` Mark Brown
2010-07-14 10:13 ` Samuel Ortiz [this message]
2010-07-14 10:13 ` Samuel Ortiz
2010-07-15 10:29 ` Liam Girdwood
2010-07-15 10:29 ` Liam Girdwood
2010-07-13 6:21 ` [PATCH 2/3] regulator: add support for regulators on the ab8500 MFD Sundar Iyer
2010-07-13 6:21 ` Sundar Iyer
2010-07-13 9:55 ` Mark Brown
2010-07-13 9:55 ` Mark Brown
2010-07-13 6:21 ` [PATCH 3/3] ux500: add ab8500-regulators machine specific data Sundar Iyer
2010-07-13 6:21 ` Sundar Iyer
2010-07-13 10:00 ` Mark Brown
2010-07-13 10:00 ` Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100714101330.GD2771@sortiz-mobl \
--to=sameo@linux.intel.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.