On Thu, Apr 19, 2012 at 4:15 AM, Laxman Dewangan<ldewangan@xxxxxxxxxx> wrote:Thanks for review. ADD_COMMAND1 have the intrrupt flag bit. More details below.Using regmap for accessing register through i2c bus. This willReviewed-by: Grant Grundler<grundler@xxxxxxxxxxxx>
remove the code for caching registers, read-modify-write logics.
Also it will provide the debugfs feature to dump register
through regmap debugfs.
Signed-off-by: Laxman Dewangan<ldewangan@xxxxxxxxxx>
Laxman,
Thanks for reposting this patch. I was talking with Bryan Freed and it
looks like the caching of registers will change the usage of
ADD_COMMAND1. More details below.
+static bool is_volatile_reg(struct device *dev, unsigned int reg)Of these four, I think only ADD_COMMAND1 wasn't treated as volatile in
+{
+ switch (reg) {
+ case ISL29018_REG_ADD_DATA_LSB:
+ case ISL29018_REG_ADD_DATA_MSB:
+ case ISL29018_REG_ADD_COMMAND1:
+ case ISL29018_REG_TEST:
the old code. Am I overlooking something?
My concern is only about the additional I2C read traffic this patch
might generate. It's possible *some* bits in that register are
volatile and we could previously ignore them.