On Tue, Jul 05, 2011 at 08:07:00PM +0530, ashishj3 wrote: > +int da9052_set_bits(struct da9052 *da9052, unsigned char reg, > + unsigned char bit_mask) > +{ > + unsigned char val; > + int ret; > + > + if (reg > DA9052_MAX_REG_CNT) { > + dev_err(da9052->dev, "invalid reg %x\n", reg); > + return -EINVAL; > + } > + > + mutex_lock_interruptible(&da9052->io_lock);
Linus has now merged the regmap code (include/linux/regmap.h and drivers/base/regmap) which means that your register I/O code should probably be redone in terms of that - it shoud factor a lot of code out of the driver. _______________________________________________ linaro-dev mailing list linaro-dev@lists.linaro.org http://lists.linaro.org/mailman/listinfo/linaro-dev