Lines Matching refs:lp873
29 struct lp873x *lp873; in lp873x_probe() local
33 lp873 = devm_kzalloc(&client->dev, sizeof(*lp873), GFP_KERNEL); in lp873x_probe()
34 if (!lp873) in lp873x_probe()
37 lp873->dev = &client->dev; in lp873x_probe()
39 lp873->regmap = devm_regmap_init_i2c(client, &lp873x_regmap_config); in lp873x_probe()
40 if (IS_ERR(lp873->regmap)) { in lp873x_probe()
41 ret = PTR_ERR(lp873->regmap); in lp873x_probe()
42 dev_err(lp873->dev, in lp873x_probe()
47 ret = regmap_read(lp873->regmap, LP873X_REG_OTP_REV, &otpid); in lp873x_probe()
49 dev_err(lp873->dev, "Failed to read OTP ID\n"); in lp873x_probe()
53 lp873->rev = otpid & LP873X_OTP_REV_OTP_ID; in lp873x_probe()
55 i2c_set_clientdata(client, lp873); in lp873x_probe()
57 ret = mfd_add_devices(lp873->dev, PLATFORM_DEVID_AUTO, lp873x_cells, in lp873x_probe()