Lines Matching full:rt5033

3  * MFD core driver for the Richtek RT5033.
5 * RT5033 comprises multiple sub-devices switcing charger, fuel gauge,
17 #include <linux/mfd/rt5033.h>
18 #include <linux/mfd/rt5033-private.h>
30 .name = "rt5033",
39 { .name = "rt5033-regulator", },
41 .name = "rt5033-charger",
42 .of_compatible = "richtek,rt5033-charger",
44 .name = "rt5033-led",
45 .of_compatible = "richtek,rt5033-led",
57 struct rt5033_dev *rt5033; in rt5033_i2c_probe() local
61 rt5033 = devm_kzalloc(&i2c->dev, sizeof(*rt5033), GFP_KERNEL); in rt5033_i2c_probe()
62 if (!rt5033) in rt5033_i2c_probe()
65 i2c_set_clientdata(i2c, rt5033); in rt5033_i2c_probe()
66 rt5033->dev = &i2c->dev; in rt5033_i2c_probe()
67 rt5033->irq = i2c->irq; in rt5033_i2c_probe()
68 rt5033->wakeup = true; in rt5033_i2c_probe()
70 rt5033->regmap = devm_regmap_init_i2c(i2c, &rt5033_regmap_config); in rt5033_i2c_probe()
71 if (IS_ERR(rt5033->regmap)) { in rt5033_i2c_probe()
73 return PTR_ERR(rt5033->regmap); in rt5033_i2c_probe()
76 ret = regmap_read(rt5033->regmap, RT5033_REG_DEVICE_ID, &dev_id); in rt5033_i2c_probe()
84 ret = regmap_add_irq_chip(rt5033->regmap, rt5033->irq, in rt5033_i2c_probe()
86 0, &rt5033_irq_chip, &rt5033->irq_data); in rt5033_i2c_probe()
89 rt5033->irq, ret); in rt5033_i2c_probe()
93 ret = devm_mfd_add_devices(rt5033->dev, -1, rt5033_devs, in rt5033_i2c_probe()
95 regmap_irq_get_domain(rt5033->irq_data)); in rt5033_i2c_probe()
97 dev_err(&i2c->dev, "Failed to add RT5033 child devices.\n"); in rt5033_i2c_probe()
101 device_init_wakeup(rt5033->dev, rt5033->wakeup); in rt5033_i2c_probe()
107 { "rt5033", },
113 { .compatible = "richtek,rt5033", },
120 .name = "rt5033",
128 MODULE_DESCRIPTION("Richtek RT5033 multi-function core driver");