Messages in this thread | | | Date | Mon, 3 Dec 2012 16:27:42 +0900 | From | Mark Brown <> | Subject | Re: [PATCH 1/1] regulator: new driver for LP8755 |
| |
On Mon, Dec 03, 2012 at 04:24:43PM +0900, GShark Jeong wrote: > 2012/12/3 Mark Brown <broonie@opensource.wolfsonmicro.com> > > On Mon, Dec 03, 2012 at 01:44:24PM +0900, Daniel Jeong wrote:
> > > + if (ret < 0) > > > + goto out_i2c_error; > > > + dev_info(pchip->dev, "lp8755 : chip ID is 0x%x\n", regval);
> > This isn't actually checking anything except the I/O. Can the chip ID > > really vary?
> My configurations are already programmed in otp memory of chip as default > values. > So this comment for to others who are using different initial values with > default data. > I will drop it.
It seems like a better fix would be to add a check for the ID and fail if the OTP value doesn't match, that way the driver won't try to run on unsupported hardware.
| |