Subject: [PATCH V1 3/3] REGULATOR: da9052: Add new DA9053 BC chip variant

Add support for a new BC variant of the DA9053 PMIC.

There is one difference between it and the AA, BA and BB.

Signed-off-by: Anthony Olech <[email protected]>
---

This patch is relative to linux-next repository tag next-20140219

This patch depends on patch number 1 of this patch
series being applied first or it will not compile.

drivers/regulator/da9052-regulator.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/regulator/da9052-regulator.c b/drivers/regulator/da9052-regulator.c
index 889c7c9..599f2ad 100644
--- a/drivers/regulator/da9052-regulator.c
+++ b/drivers/regulator/da9052-regulator.c
@@ -354,6 +354,7 @@ static inline struct da9052_regulator_info *find_regulator_info(u8 chip_id,
case DA9053_AA:
case DA9053_BA:
case DA9053_BB:
+ case DA9053_BC:
for (i = 0; i < ARRAY_SIZE(da9053_regulator_info); i++) {
info = &da9053_regulator_info[i];
if (info->reg_desc.id == id)
--
end-of-patch 3/3 for PATCH V1


2014-02-19 23:20:39

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH V1 3/3] REGULATOR: da9052: Add new DA9053 BC chip variant

On Wed, Feb 19, 2014 at 04:32:47PM +0000, Opensource [Anthony Olech] wrote:
> Add support for a new BC variant of the DA9053 PMIC.

Acked-by: Mark Brown <[email protected]>

> There is one difference between it and the AA, BA and BB.

Which is...? :)


Attachments:
(No filename) (253.00 B)
signature.asc (836.00 B)
Digital signature
Download all attachments
Subject: RE: [PATCH V1 3/3] REGULATOR: da9052: Add new DA9053 BC chip variant

> -----Original Message-----
> From: Mark Brown [mailto:[email protected]]
> Sent: 19 February 2014 16:48
> To: Opensource [Anthony Olech]
> Cc: Liam Girdwood; Lee Jones; [email protected]; Samuel Ortiz;
> David Dajun Chen
> Subject: Re: [PATCH V1 3/3] REGULATOR: da9052: Add new DA9053 BC chip
> variant
> On Wed, Feb 19, 2014 at 04:32:47PM +0000, Opensource [Anthony Olech]
> wrote:
> > Add support for a new BC variant of the DA9053 PMIC.
> Acked-by: Mark Brown <[email protected]>
> > There is one difference between it and the AA, BA and BB.
> Which is...? :)
Hi Mark,

it is easier to see in the diff -C15 output, that the BC chip does not need
a 'safe read':

--- drivers/mfd/da9052-i2c.c Thu Feb 20 09:20:43 2014
***************
*** 63,92 ****
--- 63,93 ----
static int da9052_i2c_fix(struct da9052 *da9052, unsigned char reg)
{
int val;

switch (da9052->chip_id) {
case DA9052:
case DA9053_AA:
case DA9053_BA:
case DA9053_BB:
/* A dummy read to a safe register address. */
if (!i2c_safe_reg(reg))
return regmap_read(da9052->regmap,
DA9052_PARK_REGISTER,
&val);
break;
+ case DA9053_BC:
default:
/*
* For other chips parking of I2C register
* to a safe place is not required.
*/
break;
}

return 0;
}

Tony Olech