if (ret < 0)
return ret;
- if (v != BQ24190_REG_VPRS_PN_24190 &&
- v != BQ24190_REG_VPRS_PN_24192I) {
+ switch (v) {
+ case BQ24190_REG_VPRS_PN_24190:
+ case BQ24190_REG_VPRS_PN_24192:
+ case BQ24190_REG_VPRS_PN_24192I:
+ break;
+ default:
dev_err(bdi->dev, "Error unknown model: 0x%02x\n", v);
return -ENODEV;
}
static const struct i2c_device_id bq24190_i2c_ids[] = {
{ "bq24190" },
+ { "bq24192" },
{ "bq24192i" },
{ },
};
#ifdef CONFIG_OF
static const struct of_device_id bq24190_of_match[] = {
{ .compatible = "ti,bq24190", },
+ { .compatible = "ti,bq24192", },
{ .compatible = "ti,bq24192i", },
{ },
};