Lines Matching refs:wm831x
20 struct wm831x *wm831x; member
26 static int wm831x_backup_read_voltage(struct wm831x *wm831x, in wm831x_backup_read_voltage() argument
32 ret = wm831x_auxadc_read_uv(wm831x, src); in wm831x_backup_read_voltage()
43 static void wm831x_config_backup(struct wm831x *wm831x) in wm831x_config_backup() argument
45 struct wm831x_pdata *wm831x_pdata = wm831x->dev->platform_data; in wm831x_config_backup()
50 dev_warn(wm831x->dev, in wm831x_config_backup()
71 dev_err(wm831x->dev, "Invalid backup voltage limit %dmV\n", in wm831x_config_backup()
88 dev_err(wm831x->dev, "Invalid backup current limit %duA\n", in wm831x_config_backup()
92 ret = wm831x_reg_unlock(wm831x); in wm831x_config_backup()
94 dev_err(wm831x->dev, "Failed to unlock registers: %d\n", ret); in wm831x_config_backup()
98 ret = wm831x_set_bits(wm831x, WM831X_BACKUP_CHARGER_CONTROL, in wm831x_config_backup()
106 dev_err(wm831x->dev, in wm831x_config_backup()
109 wm831x_reg_lock(wm831x); in wm831x_config_backup()
117 struct wm831x *wm831x = devdata->wm831x; in wm831x_backup_get_prop() local
120 ret = wm831x_reg_read(wm831x, WM831X_BACKUP_CHARGER_CONTROL); in wm831x_backup_get_prop()
133 ret = wm831x_backup_read_voltage(wm831x, WM831X_AUX_BKUP_BATT, in wm831x_backup_get_prop()
164 struct wm831x *wm831x = dev_get_drvdata(pdev->dev.parent); in wm831x_backup_probe() local
165 struct wm831x_pdata *wm831x_pdata = wm831x->dev->platform_data; in wm831x_backup_probe()
173 devdata->wm831x = wm831x; in wm831x_backup_probe()
180 wm831x_config_backup(wm831x); in wm831x_backup_probe()