* [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
@ 2009-07-29 4:36 balajitk
[not found] ` <1248842173-21821-1-git-send-email-balajitk-l0cyMroinI0@public.gmane.org>
0 siblings, 1 reply; 12+ messages in thread
From: balajitk @ 2009-07-29 4:36 UTC (permalink / raw)
To: linux-omap
Cc: tony, khilman, david-b, linux-i2c, sameo, wim, timo.t.kokkonen,
ben-linux, lrg, broonie, Rajendra Nayak
From: Rajendra Nayak <rnayak@ti.com>
This version of patch series enables RUN TIME selection of TWL4030 or TWL6030.
This patch adds initial support for creating twl6030 PMIC
specific voltage regulators in the twl mfd driver.
Board specific regulator configurations will have to be passed from
respective board files.
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
---
drivers/mfd/twl-core.c | 56 +++++++++++++++++++++++++++++++++++++++++-----
include/linux/i2c/twl.h | 18 +++++++++++----
2 files changed, 63 insertions(+), 11 deletions(-)
diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
index f505537..747289c 100644
--- a/drivers/mfd/twl-core.c
+++ b/drivers/mfd/twl-core.c
@@ -76,9 +76,9 @@
#define twl_has_gpio() false
#endif
-#if defined(CONFIG_REGULATOR_TWL4030) \
- || defined(CONFIG_REGULATOR_TWL4030_MODULE)
-#define twl_has_regulator() true
+#if defined(CONFIG_REGULATOR_TWL) \
+ || defined(CONFIG_REGULATOR_TWL_MODULE)
+#define twl_has_regulator() true
#else
#define twl_has_regulator() false
#endif
@@ -636,7 +636,7 @@ add_children(struct twl_platform_data *pdata, unsigned long features)
return PTR_ERR(child);
}
- if (twl_has_regulator()) {
+ if (twl_has_regulator() && is_class_twl4030()) {
/*
child = add_regulator(TWL4030_REG_VPLL1, pdata->vpll1);
if (IS_ERR(child))
@@ -659,7 +659,7 @@ add_children(struct twl_platform_data *pdata, unsigned long features)
return PTR_ERR(child);
}
- if (twl_has_regulator() && usb_transceiver) {
+ if (twl_has_regulator() && is_class_twl4030() && usb_transceiver) {
static struct regulator_consumer_supply usb1v5 = {
.supply = "usb1v5",
};
@@ -701,7 +701,8 @@ add_children(struct twl_platform_data *pdata, unsigned long features)
}
/* maybe add LDOs that are omitted on cost-reduced parts */
- if (twl_has_regulator() && !(features & TPS_SUBSET)) {
+ if (twl_has_regulator() && is_class_twl4030()
+ && !(features & TPS_SUBSET)) {
child = add_regulator(TWL4030_REG_VPLL2, pdata->vpll2);
if (IS_ERR(child))
return PTR_ERR(child);
@@ -727,6 +728,49 @@ add_children(struct twl_platform_data *pdata, unsigned long features)
return PTR_ERR(child);
}
+ /* twl6030 regulators */
+ if (twl_has_regulator() && is_class_twl4030()) {
+ child = add_regulator(TWL6030_REG_VMMC, pdata->vmmc);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VPP, pdata->vpp);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VUSIM, pdata->vusim);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VANA, pdata->vana);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VCXIO, pdata->vcxio);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VDAC, pdata->vdac);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VUSB, pdata->vusb);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VAUX1_6030, pdata->vaux1);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VAUX2_6030, pdata->vaux2);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+
+ child = add_regulator(TWL6030_REG_VAUX3_6030, pdata->vaux3);
+ if (IS_ERR(child))
+ return PTR_ERR(child);
+ }
+
return 0;
}
diff --git a/include/linux/i2c/twl.h b/include/linux/i2c/twl.h
index 53d9360..1f678ed 100644
--- a/include/linux/i2c/twl.h
+++ b/include/linux/i2c/twl.h
@@ -306,6 +306,7 @@ int twl_i2c_read(u8 mod_no, u8 *value, u8 reg, unsigned num_bytes);
#define TWL4030_INT_PWR_EDR2 0x6
#define TWL4030_INT_PWR_SIH_CTRL 0x7
+
/*----------------------------------------------------------------------*/
/* Power bus message definitions */
@@ -424,18 +425,25 @@ struct twl_platform_data {
struct twl_keypad_data *keypad;
struct twl_usb_data *usb;
- /* LDO regulators */
+ /* LDO regulators common to TWL4030/TWL6030 */
struct regulator_init_data *vdac;
+ struct regulator_init_data *vaux1;
+ struct regulator_init_data *vaux2;
+ struct regulator_init_data *vaux3;
+ /* TWL4030 LDO regulators */
struct regulator_init_data *vpll1;
struct regulator_init_data *vpll2;
struct regulator_init_data *vmmc1;
struct regulator_init_data *vmmc2;
struct regulator_init_data *vsim;
- struct regulator_init_data *vaux1;
- struct regulator_init_data *vaux2;
- struct regulator_init_data *vaux3;
struct regulator_init_data *vaux4;
-
+ /* TWL6030 LDO regulators */
+ struct regulator_init_data *vmmc;
+ struct regulator_init_data *vpp;
+ struct regulator_init_data *vusim;
+ struct regulator_init_data *vana;
+ struct regulator_init_data *vcxio;
+ struct regulator_init_data *vusb;
/* REVISIT more to come ... _nothing_ should be hard-wired */
};
--
1.5.4.7
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <1248842173-21821-1-git-send-email-balajitk-l0cyMroinI0@public.gmane.org>
@ 2009-08-03 14:23 ` Mark Brown
2009-08-04 7:45 ` Tony Lindgren
0 siblings, 1 reply; 12+ messages in thread
From: Mark Brown @ 2009-08-03 14:23 UTC (permalink / raw)
To: balajitk-l0cyMroinI0
Cc: linux-omap-u79uwXL29TY76Z2rM5mHXA, tony-4v6yS6AI5VpBDgjK7y7TUQ,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR,
david-b-yBeKhBN/0LDR7s880joybQ, linux-i2c-u79uwXL29TY76Z2rM5mHXA,
sameo-RWuK6r/cQWRpLGFMi4vTTA, wim-IQzOog9fTRqzQB+pC5nmwQ,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w,
ben-linux-elnMNo+KYs3YtjvyW6yDsg, lrg-kDsPt+C1G03kYMGBc/C6ZA,
Rajendra Nayak
On Wed, Jul 29, 2009 at 10:06:13AM +0530, balajitk-l0cyMroinI0@public.gmane.org wrote:
> - if (twl_has_regulator()) {
> + if (twl_has_regulator() && is_class_twl4030()) {
is_class_twl4030() feels like it should have better namespacing, though
having the part name in there means it's not actually an issue.
> @@ -306,6 +306,7 @@ int twl_i2c_read(u8 mod_no, u8 *value, u8 reg, unsigned num_bytes);
> #define TWL4030_INT_PWR_EDR2 0x6
> #define TWL4030_INT_PWR_SIH_CTRL 0x7
>
> +
> /*----------------------------------------------------------------------*/
>
> /* Power bus message definitions */
Random unrelated indentation change?
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
2009-08-03 14:23 ` Mark Brown
@ 2009-08-04 7:45 ` Tony Lindgren
[not found] ` <20090804074544.GG24334-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
0 siblings, 1 reply; 12+ messages in thread
From: Tony Lindgren @ 2009-08-04 7:45 UTC (permalink / raw)
To: Mark Brown
Cc: balajitk, linux-omap, khilman, david-b, linux-i2c, sameo, wim,
timo.t.kokkonen, ben-linux, lrg, Rajendra Nayak
* Mark Brown <broonie@opensource.wolfsonmicro.com> [090803 17:23]:
> On Wed, Jul 29, 2009 at 10:06:13AM +0530, balajitk@ti.com wrote:
>
> > - if (twl_has_regulator()) {
> > + if (twl_has_regulator() && is_class_twl4030()) {
>
> is_class_twl4030() feels like it should have better namespacing, though
> having the part name in there means it's not actually an issue.
How about twl_is_4030()?
> > @@ -306,6 +306,7 @@ int twl_i2c_read(u8 mod_no, u8 *value, u8 reg, unsigned num_bytes);
> > #define TWL4030_INT_PWR_EDR2 0x6
> > #define TWL4030_INT_PWR_SIH_CTRL 0x7
> >
> > +
> > /*----------------------------------------------------------------------*/
> >
> > /* Power bus message definitions */
>
> Random unrelated indentation change?
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <20090804074544.GG24334-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
@ 2009-08-04 7:56 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8884-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2009-08-04 13:24 ` Premi, Sanjeev
0 siblings, 2 replies; 12+ messages in thread
From: Shilimkar, Santosh @ 2009-08-04 7:56 UTC (permalink / raw)
To: Tony Lindgren, Mark Brown
Cc: Krishnamoorthy, Balaji T,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
> -----Original Message-----
> From: linux-omap-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org [mailto:linux-omap-
> owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org] On Behalf Of Tony Lindgren
> Sent: Tuesday, August 04, 2009 1:16 PM
> To: Mark Brown
> Cc: Krishnamoorthy, Balaji T; linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org; david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org; linux-
> i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org; wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org;
> timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org; ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org; lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org; Nayak,
> Rajendra
> Subject: Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to
> create twl6030 regulators
>
> * Mark Brown <broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org> [090803 17:23]:
> > On Wed, Jul 29, 2009 at 10:06:13AM +0530, balajitk-l0cyMroinI0@public.gmane.org wrote:
> >
> > > - if (twl_has_regulator()) {
> > > + if (twl_has_regulator() && is_class_twl4030()) {
> >
> > is_class_twl4030() feels like it should have better namespacing, though
> > having the part name in there means it's not actually an issue.
>
> How about twl_is_4030()?
The idea was to have a class of twl4030 IC's type IC's. There are many of them with just different name (TPS *)
... twl_class_is_4030().... What you say ?
Regards,
Santosh
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8884-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
@ 2009-08-04 8:16 ` Krishnamoorthy, Balaji T
0 siblings, 0 replies; 12+ messages in thread
From: Krishnamoorthy, Balaji T @ 2009-08-04 8:16 UTC (permalink / raw)
To: Shilimkar, Santosh, Tony Lindgren, Mark Brown
Cc: linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
> From: Shilimkar, Santosh
>
> > From: linux-omap-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org [mailto:linux-omap-
> > owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org] On Behalf Of Tony Lindgren
> >
> > * Mark Brown <broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org> [090803 17:23]:
> > > On Wed, Jul 29, 2009 at 10:06:13AM +0530, balajitk-l0cyMroinI0@public.gmane.org wrote:
> > >
> > > > - if (twl_has_regulator()) {
> > > > + if (twl_has_regulator() && is_class_twl4030()) {
> > >
> > > is_class_twl4030() feels like it should have better namespacing, though
> > > having the part name in there means it's not actually an issue.
> >
> > How about twl_is_4030()?
> The idea was to have a class of twl4030 IC's type IC's. There are many of them
> with just different name (TPS *)
> ... twl_class_is_4030().... What you say ?
twl_class_is_4030 should return TRUE for twl4030 / twl5030 / tps65950 /
tps65930 / tps65920
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
2009-08-04 7:56 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8884-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
@ 2009-08-04 13:24 ` Premi, Sanjeev
[not found] ` <B85A65D85D7EB246BE421B3FB0FBB59301D8BD1708-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
1 sibling, 1 reply; 12+ messages in thread
From: Premi, Sanjeev @ 2009-08-04 13:24 UTC (permalink / raw)
To: Shilimkar, Santosh, Tony Lindgren, Mark Brown
Cc: Krishnamoorthy, Balaji T, linux-omap@vger.kernel.org,
khilman@deeprootsystems.com, david-b@pacbell.net,
linux-i2c@vger.kernel.org, sameo@openedhand.com, wim@iguana.be,
timo.t.kokkonen@nokia.com, ben-linux@fluff.org,
lrg@slimlogic.co.uk, Nayak, Rajendra
-----Original Message-----
From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-owner@vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Tuesday, August 04, 2009 1:27 PM
To: Tony Lindgren; Mark Brown
Cc: Krishnamoorthy, Balaji T; linux-omap@vger.kernel.org; khilman@deeprootsystems.com; david-b@pacbell.net; linux-i2c@vger.kernel.org; sameo@openedhand.com; wim@iguana.be; timo.t.kokkonen@nokia.com; ben-linux@fluff.org; lrg@slimlogic.co.uk; Nayak, Rajendra
Subject: RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
> -----Original Message-----
> From: linux-omap-owner@vger.kernel.org [mailto:linux-omap-
> owner@vger.kernel.org] On Behalf Of Tony Lindgren
> Sent: Tuesday, August 04, 2009 1:16 PM
> To: Mark Brown
> Cc: Krishnamoorthy, Balaji T; linux-omap@vger.kernel.org;
> khilman@deeprootsystems.com; david-b@pacbell.net; linux-
> i2c@vger.kernel.org; sameo@openedhand.com; wim@iguana.be;
> timo.t.kokkonen@nokia.com; ben-linux@fluff.org; lrg@slimlogic.co.uk; Nayak,
> Rajendra
> Subject: Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to
> create twl6030 regulators
>
> * Mark Brown <broonie@opensource.wolfsonmicro.com> [090803 17:23]:
> > On Wed, Jul 29, 2009 at 10:06:13AM +0530, balajitk@ti.com wrote:
> >
> > > - if (twl_has_regulator()) {
> > > + if (twl_has_regulator() && is_class_twl4030()) {
> >
> > is_class_twl4030() feels like it should have better namespacing, though
> > having the part name in there means it's not actually an issue.
>
> How about twl_is_4030()?
The idea was to have a class of twl4030 IC's type IC's. There are many of them with just different name (TPS *)
... twl_class_is_4030().... What you say ?
Can I suggest: pmic_class_is_xxx() ?
Regards,
Santosh
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <B85A65D85D7EB246BE421B3FB0FBB59301D8BD1708-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
@ 2009-08-04 13:26 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8BFF-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
0 siblings, 1 reply; 12+ messages in thread
From: Shilimkar, Santosh @ 2009-08-04 13:26 UTC (permalink / raw)
To: Premi, Sanjeev, Tony Lindgren, Mark Brown
Cc: Krishnamoorthy, Balaji T,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
> -----Original Message-----
> From: Premi, Sanjeev
> Sent: Tuesday, August 04, 2009 6:54 PM
> To: Shilimkar, Santosh; Tony Lindgren; Mark Brown
> Cc: Krishnamoorthy, Balaji T; linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org; david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org; linux-
> i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org; wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org;
> timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org; ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org; lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org; Nayak,
> Rajendra
> Subject: RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to
> create twl6030 regulators
>
> -----Original Message-----
> From: linux-omap-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org [mailto:linux-omap-
> owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org] On Behalf Of Shilimkar, Santosh
> Sent: Tuesday, August 04, 2009 1:27 PM
> To: Tony Lindgren; Mark Brown
> Cc: Krishnamoorthy, Balaji T; linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org; david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org; linux-
> i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org; wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org;
> timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org; ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org; lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org; Nayak,
> Rajendra
> Subject: RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to
> create twl6030 regulators
>
> > -----Original Message-----
> > From: linux-omap-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org [mailto:linux-omap-
> > owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org] On Behalf Of Tony Lindgren
> > Sent: Tuesday, August 04, 2009 1:16 PM
> > To: Mark Brown
> > Cc: Krishnamoorthy, Balaji T; linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> > khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org; david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org; linux-
> > i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org; wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org;
> > timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org; ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org; lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org;
> Nayak,
> > Rajendra
> > Subject: Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to
> > create twl6030 regulators
> >
> > * Mark Brown <broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org> [090803 17:23]:
> > > On Wed, Jul 29, 2009 at 10:06:13AM +0530, balajitk-l0cyMroinI0@public.gmane.org wrote:
> > >
> > > > - if (twl_has_regulator()) {
> > > > + if (twl_has_regulator() && is_class_twl4030()) {
> > >
> > > is_class_twl4030() feels like it should have better namespacing,
> though
> > > having the part name in there means it's not actually an issue.
> >
> > How about twl_is_4030()?
> The idea was to have a class of twl4030 IC's type IC's. There are many of
> them with just different name (TPS *)
> ... twl_class_is_4030().... What you say ?
>
> Can I suggest: pmic_class_is_xxx() ?
Even better
Regards,
Santosh
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8BFF-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
@ 2009-08-04 13:42 ` Mark Brown
[not found] ` <20090804134247.GA32353-HF5t3jzXg/6ND3a5+9QAFujbO/Zr0HzV@public.gmane.org>
0 siblings, 1 reply; 12+ messages in thread
From: Mark Brown @ 2009-08-04 13:42 UTC (permalink / raw)
To: Shilimkar, Santosh
Cc: Premi, Sanjeev, Tony Lindgren, Krishnamoorthy, Balaji T,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
On Tue, Aug 04, 2009 at 06:56:13PM +0530, Shilimkar, Santosh wrote:
> > > > is_class_twl4030() feels like it should have better namespacing,
> > though
> > > > having the part name in there means it's not actually an issue.
> > > How about twl_is_4030()?
> > The idea was to have a class of twl4030 IC's type IC's. There are many of
> > them with just different name (TPS *)
> > ... twl_class_is_4030().... What you say ?
> > Can I suggest: pmic_class_is_xxx() ?
> Even better
That feels like it's got a more global namespace than it ought - this is
really only for this class of chip. It's also got a bit of an
assumption that there's only one PMIC in the system which isn't always
the case.
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <20090804134247.GA32353-HF5t3jzXg/6ND3a5+9QAFujbO/Zr0HzV@public.gmane.org>
@ 2009-08-04 13:58 ` Shilimkar, Santosh
2009-08-05 21:39 ` Mark Brown
0 siblings, 1 reply; 12+ messages in thread
From: Shilimkar, Santosh @ 2009-08-04 13:58 UTC (permalink / raw)
To: Mark Brown
Cc: Premi, Sanjeev, Tony Lindgren, Krishnamoorthy, Balaji T,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
> -----Original Message-----
> From: Mark Brown [mailto:broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org]
> Sent: Tuesday, August 04, 2009 7:13 PM
> To: Shilimkar, Santosh
> Cc: Premi, Sanjeev; Tony Lindgren; Krishnamoorthy, Balaji T; linux-
> omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org; david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org;
> linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org; wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org;
> timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org; ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org; lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org; Nayak,
> Rajendra
> Subject: Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to
> create twl6030 regulators
>
> On Tue, Aug 04, 2009 at 06:56:13PM +0530, Shilimkar, Santosh wrote:
>
> > > > > is_class_twl4030() feels like it should have better namespacing,
> > > though
> > > > > having the part name in there means it's not actually an issue.
>
> > > > How about twl_is_4030()?
>
> > > The idea was to have a class of twl4030 IC's type IC's. There are many
> of
> > > them with just different name (TPS *)
> > > ... twl_class_is_4030().... What you say ?
>
> > > Can I suggest: pmic_class_is_xxx() ?
>
> > Even better
>
> That feels like it's got a more global namespace than it ought - this is
> really only for this class of chip. It's also got a bit of an
> assumption that there's only one PMIC in the system which isn't always
> the case.
Do you have boards / use cases where more than one PM IC would be used _and_ it will use the same driver ?
Regards,
Santosh
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
2009-08-04 13:58 ` Shilimkar, Santosh
@ 2009-08-05 21:39 ` Mark Brown
[not found] ` <20090805213932.GD20853-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>
0 siblings, 1 reply; 12+ messages in thread
From: Mark Brown @ 2009-08-05 21:39 UTC (permalink / raw)
To: Shilimkar, Santosh
Cc: Premi, Sanjeev, Tony Lindgren, Krishnamoorthy, Balaji T,
linux-omap@vger.kernel.org, khilman@deeprootsystems.com,
david-b@pacbell.net, linux-i2c@vger.kernel.org,
sameo@openedhand.com, wim@iguana.be, timo.t.kokkonen@nokia.com,
ben-linux@fluff.org, lrg@slimlogic.co.uk, Nayak, Rajendra
On Tue, Aug 04, 2009 at 07:28:22PM +0530, Shilimkar, Santosh wrote:
> Do you have boards / use cases where more than one PM IC would be used _and_ it will use the same driver ?
I don't personally but it's certainly something that I would consider
realistic (if not mainstream).
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <20090805213932.GD20853-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>
@ 2009-08-06 7:27 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5D8155B-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
0 siblings, 1 reply; 12+ messages in thread
From: Shilimkar, Santosh @ 2009-08-06 7:27 UTC (permalink / raw)
To: Mark Brown
Cc: Premi, Sanjeev, Tony Lindgren, Krishnamoorthy, Balaji T,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
> -----Original Message-----
> From: Mark Brown [mailto:broonie-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org]
> Sent: Thursday, August 06, 2009 3:10 AM
> To: Shilimkar, Santosh
> Cc: Premi, Sanjeev; Tony Lindgren; Krishnamoorthy, Balaji T;
> linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org;
> david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org; linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org; wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org;
> timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org; ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org;
> lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org; Nayak, Rajendra
> Subject: Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd
> driver to create twl6030 regulators
>
> On Tue, Aug 04, 2009 at 07:28:22PM +0530, Shilimkar, Santosh wrote:
>
> > Do you have boards / use cases where more than one PM IC
> would be used _and_ it will use the same driver ?
>
> I don't personally but it's certainly something that I would consider
> realistic (if not mainstream).
So what you suggest here.
Regards,
Santosh
--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5D8155B-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
@ 2009-08-06 8:11 ` Mark Brown
0 siblings, 0 replies; 12+ messages in thread
From: Mark Brown @ 2009-08-06 8:11 UTC (permalink / raw)
To: Shilimkar, Santosh
Cc: Premi, Sanjeev, Tony Lindgren, Krishnamoorthy, Balaji T,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org,
david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
sameo-RWuK6r/cQWRpLGFMi4vTTA@public.gmane.org,
wim-IQzOog9fTRqzQB+pC5nmwQ@public.gmane.org,
timo.t.kokkonen-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org,
ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
lrg-kDsPt+C1G03kYMGBc/C6ZA@public.gmane.org, Nayak, Rajendra
On Thu, Aug 06, 2009 at 12:57:26PM +0530, Shilimkar, Santosh wrote:
> So what you suggest here.
Some of the earlier names like twl_is_*() seemed OK; given that the
driver is called twl everywhere I don't see much problem with the tps
variants using that scheme too.
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2009-08-06 8:11 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-29 4:36 [RFC][PATCH v2 4/4] OMAP4: PMIC: Update TWL mfd driver to create twl6030 regulators balajitk
[not found] ` <1248842173-21821-1-git-send-email-balajitk-l0cyMroinI0@public.gmane.org>
2009-08-03 14:23 ` Mark Brown
2009-08-04 7:45 ` Tony Lindgren
[not found] ` <20090804074544.GG24334-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
2009-08-04 7:56 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8884-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2009-08-04 8:16 ` Krishnamoorthy, Balaji T
2009-08-04 13:24 ` Premi, Sanjeev
[not found] ` <B85A65D85D7EB246BE421B3FB0FBB59301D8BD1708-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2009-08-04 13:26 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5CD8BFF-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2009-08-04 13:42 ` Mark Brown
[not found] ` <20090804134247.GA32353-HF5t3jzXg/6ND3a5+9QAFujbO/Zr0HzV@public.gmane.org>
2009-08-04 13:58 ` Shilimkar, Santosh
2009-08-05 21:39 ` Mark Brown
[not found] ` <20090805213932.GD20853-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>
2009-08-06 7:27 ` Shilimkar, Santosh
[not found] ` <EAF47CD23C76F840A9E7FCE10091EFAB02B5D8155B-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2009-08-06 8:11 ` Mark Brown
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).