Searched refs:max77686 (Results 1 - 14 of 14) sorted by relevance

/linux-4.1.27/drivers/mfd/
H A Dmax77686.c2 * max77686.c - mfd core driver for the Maxim 77686/802
33 #include <linux/mfd/max77686.h>
34 #include <linux/mfd/max77686-private.h>
41 { .name = "max77686-pmic", },
42 { .name = "max77686-rtc", },
43 { .name = "max77686-clk", },
151 .name = "max77686-pmic",
170 .name = "max77686-rtc",
198 .compatible = "maxim,max77686",
211 struct max77686_dev *max77686 = NULL; max77686_i2c_probe() local
222 max77686 = devm_kzalloc(&i2c->dev, max77686_i2c_probe()
224 if (!max77686) max77686_i2c_probe()
232 max77686->type = (unsigned long)match->data; max77686_i2c_probe()
234 max77686->type = id->driver_data; max77686_i2c_probe()
236 i2c_set_clientdata(i2c, max77686); max77686_i2c_probe()
237 max77686->dev = &i2c->dev; max77686_i2c_probe()
238 max77686->i2c = i2c; max77686_i2c_probe()
240 max77686->irq = i2c->irq; max77686_i2c_probe()
242 if (max77686->type == TYPE_MAX77686) { max77686_i2c_probe()
246 rtc_regmap = &max77686->rtc_regmap; max77686_i2c_probe()
253 rtc_regmap = &max77686->regmap; max77686_i2c_probe()
258 max77686->regmap = devm_regmap_init_i2c(i2c, config); max77686_i2c_probe()
259 if (IS_ERR(max77686->regmap)) { max77686_i2c_probe()
260 ret = PTR_ERR(max77686->regmap); max77686_i2c_probe()
261 dev_err(max77686->dev, "Failed to allocate register map: %d\n", max77686_i2c_probe()
266 ret = regmap_read(max77686->regmap, MAX77686_REG_DEVICE_ID, &data); max77686_i2c_probe()
268 dev_err(max77686->dev, max77686_i2c_probe()
273 if (max77686->type == TYPE_MAX77686) { max77686_i2c_probe()
274 max77686->rtc = i2c_new_dummy(i2c->adapter, I2C_ADDR_RTC); max77686_i2c_probe()
275 if (!max77686->rtc) { max77686_i2c_probe()
276 dev_err(max77686->dev, max77686_i2c_probe()
280 i2c_set_clientdata(max77686->rtc, max77686); max77686_i2c_probe()
282 max77686->rtc_regmap = max77686_i2c_probe()
283 devm_regmap_init_i2c(max77686->rtc, max77686_i2c_probe()
285 if (IS_ERR(max77686->rtc_regmap)) { max77686_i2c_probe()
286 ret = PTR_ERR(max77686->rtc_regmap); max77686_i2c_probe()
287 dev_err(max77686->dev, max77686_i2c_probe()
294 ret = regmap_add_irq_chip(max77686->regmap, max77686->irq, max77686_i2c_probe()
297 &max77686->irq_data); max77686_i2c_probe()
303 ret = regmap_add_irq_chip(*rtc_regmap, max77686->irq, max77686_i2c_probe()
306 &max77686->rtc_irq_data); max77686_i2c_probe()
312 ret = mfd_add_devices(max77686->dev, -1, cells, n_devs, NULL, 0, NULL); max77686_i2c_probe()
321 regmap_del_irq_chip(max77686->irq, max77686->rtc_irq_data); max77686_i2c_probe()
323 regmap_del_irq_chip(max77686->irq, max77686->irq_data); max77686_i2c_probe()
325 if (max77686->type == TYPE_MAX77686) max77686_i2c_probe()
326 i2c_unregister_device(max77686->rtc); max77686_i2c_probe()
333 struct max77686_dev *max77686 = i2c_get_clientdata(i2c); max77686_i2c_remove() local
335 mfd_remove_devices(max77686->dev); max77686_i2c_remove()
337 regmap_del_irq_chip(max77686->irq, max77686->rtc_irq_data); max77686_i2c_remove()
338 regmap_del_irq_chip(max77686->irq, max77686->irq_data); max77686_i2c_remove()
340 if (max77686->type == TYPE_MAX77686) max77686_i2c_remove()
341 i2c_unregister_device(max77686->rtc); max77686_i2c_remove()
347 { "max77686", TYPE_MAX77686 },
356 struct max77686_dev *max77686 = i2c_get_clientdata(i2c); max77686_suspend() local
359 enable_irq_wake(max77686->irq); max77686_suspend()
370 disable_irq(max77686->irq); max77686_suspend()
378 struct max77686_dev *max77686 = i2c_get_clientdata(i2c); max77686_resume() local
381 disable_irq_wake(max77686->irq); max77686_resume()
383 enable_irq(max77686->irq); max77686_resume()
393 .name = "max77686",
H A DMakefile118 obj-$(CONFIG_MFD_MAX77686) += max77686.o
/linux-4.1.27/drivers/clk/
H A Dclk-max77686.c2 * clk-max77686.c - Clock driver for Maxim 77686
27 #include <linux/mfd/max77686.h>
28 #include <linux/mfd/max77686-private.h>
33 #include <dt-bindings/clock/maxim,max77686.h>
68 { "max77686-clk", 0},
75 .name = "max77686-clk",
H A Dclk-max77802.c19 * This driver is based on clk-max77686.c
26 #include <linux/mfd/max77686-private.h>
H A Dclk-max-gen.c19 * This driver is based on clk-max77686.c
/linux-4.1.27/drivers/rtc/
H A Drtc-max77686.c23 #include <linux/mfd/max77686-private.h>
59 struct max77686_dev *max77686; member in struct:max77686_rtc_info
126 ret = regmap_update_bits(info->max77686->rtc_regmap, max77686_rtc_update()
151 ret = regmap_bulk_read(info->max77686->rtc_regmap, max77686_rtc_read_time()
179 ret = regmap_bulk_write(info->max77686->rtc_regmap, max77686_rtc_set_time()
207 ret = regmap_bulk_read(info->max77686->rtc_regmap, max77686_rtc_read_alarm()
226 ret = regmap_read(info->max77686->regmap, MAX77686_REG_STATUS2, &val); max77686_rtc_read_alarm()
254 ret = regmap_bulk_read(info->max77686->rtc_regmap, max77686_rtc_stop_alarm()
267 ret = regmap_bulk_write(info->max77686->rtc_regmap, max77686_rtc_stop_alarm()
293 ret = regmap_bulk_read(info->max77686->rtc_regmap, max77686_rtc_start_alarm()
314 ret = regmap_bulk_write(info->max77686->rtc_regmap, max77686_rtc_start_alarm()
343 ret = regmap_bulk_write(info->max77686->rtc_regmap, max77686_rtc_set_alarm()
409 ret = regmap_bulk_write(info->max77686->rtc_regmap, MAX77686_RTC_CONTROLM, data, 2); max77686_rtc_init_reg()
422 struct max77686_dev *max77686 = dev_get_drvdata(pdev->dev.parent); max77686_rtc_probe() local
435 info->max77686 = max77686; max77686_rtc_probe()
436 info->rtc = max77686->rtc; max77686_rtc_probe()
449 info->rtc_dev = devm_rtc_device_register(&pdev->dev, "max77686-rtc", max77686_rtc_probe()
460 if (!max77686->rtc_irq_data) { max77686_rtc_probe()
466 info->virq = regmap_irq_get_virq(max77686->rtc_irq_data, max77686_rtc_probe()
511 { "max77686-rtc", 0 },
517 .name = "max77686-rtc",
H A DMakefile92 obj-$(CONFIG_RTC_DRV_MAX77686) += rtc-max77686.o
H A Drtc-max77802.c23 #include <linux/mfd/max77686-private.h>
/linux-4.1.27/drivers/regulator/
H A Dmax77686.c2 * max77686.c - Regulator driver for the Maxim 77686
35 #include <linux/mfd/max77686.h>
36 #include <linux/mfd/max77686-private.h>
117 static unsigned int max77686_map_normal_mode(struct max77686_data *max77686, max77686_map_normal_mode() argument
124 if (test_bit(id, max77686->gpio_enabled)) max77686_map_normal_mode()
135 struct max77686_data *max77686 = rdev_get_drvdata(rdev); max77686_set_suspend_disable() local
146 max77686->opmode[id] = val; max77686_set_suspend_disable()
154 struct max77686_data *max77686 = rdev_get_drvdata(rdev); max77686_set_suspend_mode() local
167 val = max77686_map_normal_mode(max77686, id); max77686_set_suspend_mode()
181 max77686->opmode[id] = val; max77686_set_suspend_mode()
190 struct max77686_data *max77686 = rdev_get_drvdata(rdev); max77686_ldo_set_suspend_mode() local
201 val = max77686_map_normal_mode(max77686, id); max77686_ldo_set_suspend_mode()
215 max77686->opmode[id] = val; max77686_ldo_set_suspend_mode()
221 struct max77686_data *max77686 = rdev_get_drvdata(rdev); max77686_enable() local
227 if (max77686->opmode[id] == MAX77686_OFF_PWRREQ) max77686_enable()
228 max77686->opmode[id] = max77686_map_normal_mode(max77686, id); max77686_enable()
232 max77686->opmode[id] << shift); max77686_enable()
264 struct max77686_data *max77686 = config->driver_data; max77686_of_parse_cb() local
280 set_bit(desc->id, max77686->gpio_enabled); max77686_of_parse_cb()
508 struct max77686_data *max77686; max77686_pmic_probe() local
514 max77686 = devm_kzalloc(&pdev->dev, sizeof(struct max77686_data), max77686_pmic_probe()
516 if (!max77686) max77686_pmic_probe()
521 config.driver_data = max77686; max77686_pmic_probe()
522 platform_set_drvdata(pdev, max77686); max77686_pmic_probe()
528 max77686->opmode[id] = MAX77686_NORMAL; max77686_pmic_probe()
543 {"max77686-pmic", 0},
550 .name = "max77686-pmic",
H A Dmax77693.c21 * This driver is based on max77686.c
H A Dmax77802.c34 #include <linux/mfd/max77686.h>
35 #include <linux/mfd/max77686-private.h>
/linux-4.1.27/include/linux/mfd/
H A Dmax77686-private.h2 * max77686-private.h - Voltage regulator driver for the Maxim 77686/802
460 extern int max77686_irq_init(struct max77686_dev *max77686);
461 extern void max77686_irq_exit(struct max77686_dev *max77686);
462 extern int max77686_irq_resume(struct max77686_dev *max77686);
H A Dmax77686.h2 * max77686.h - Driver for the Maxim 77686/802
H A Dmax77693-private.h560 extern int max77693_irq_init(struct max77693_dev *max77686);
561 extern void max77693_irq_exit(struct max77693_dev *max77686);
562 extern int max77693_irq_resume(struct max77693_dev *max77686);

Completed in 331 milliseconds