Am Mittwoch, den 24.07.2013, 18:07 +0100 schrieb Mark Brown: > On Wed, Jul 24, 2013 at 06:34:42PM +0200, Philipp Zabel wrote: > > > + ret = regmap_read(da9063->regmap, DA9063_REG_CHIP_ID, &model); > > + if (ret < 0) { > > + dev_err(da9063->dev, "Cannot read chip model id.\n"); > > + return -EIO; > > + } > > + > > + ret = regmap_read(da9063->regmap, DA9063_REG_CHIP_VARIANT, &revision); > > + if (ret < 0) { > > + dev_err(da9063->dev, "Cannot read chip revision id.\n"); > > + return -EIO; > > + } > > Is it possible to valiate these at all?
Yes, I think so. Chip id is 0x61, and revision is 3 for da9063. > > +static int __init da9063_i2c_init(void) > > +{ > > + int ret; > > + > > + ret = i2c_add_driver(&da9063_i2c_driver); > > + if (ret != 0) > > + pr_err("Failed to register da9063 I2C driver\n"); > > + > > + return ret; > > +} > > +subsys_initcall(da9063_i2c_init); > > You should really be able to use module_i2c_driver() for modern systems, > probe deferral should resolve the init order issues. Ok, will fix that. regards Philipp -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/