On Sun, Aug 31, 2008 at 01:39:21PM -0700, David Brownell wrote: > On Saturday 30 August 2008, Felipe Balbi wrote: > > +static int lp5521_configure(struct i2c_client *client) > > +{ > > + int ret = 0; > > + > > + /* Enable chip and set light to logarithmic mode*/ > > + ret |= lp5521_write(client, LP5521_REG_ENABLE, 0xc0); > > + > > + /* setting all color pwms to direct control mode */ > > + ret |= lp5521_write(client, LP5521_REG_OP_MODE, 0x3f); > > + > > + /* setting current to 4.7 mA for all channels */ > > + ret |= lp5521_write(client, LP5521_REG_R_CNTRL, LP5521_CURRENT_4m7); > > + ret |= lp5521_write(client, LP5521_REG_G_CNTRL, LP5521_CURRENT_4m7); > > + ret |= lp5521_write(client, LP5521_REG_B_CNTRL, LP5521_CURRENT_4m7); > > + > > + /* Enable auto-powersave, set charge pump to auto, red to battery */ > > + ret |= lp5521_write(client, LP5521_REG_MISC, 0x3c); > > + > > This highlights one reason many of these drivers haven't gone > upstream: embedding non-general assumptions. In this case it > should be simple enough to define platform data to represent > various options like these ... Also dropped. The author should take a look at this. I'm putting him in the loop. Mathias, any comments on this ?? -- balbi -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html