diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-03-28 16:56:35 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-03-28 16:56:35 -0400 |
commit | 30304e5a79d424eb2c8707b3ff0e9b8bf6ab3e8f (patch) | |
tree | 63968fb97b86861e31922515395feef8a110f884 /drivers/mfd/da9052-i2c.c | |
parent | 750f77064a290beb162352077b52c61b04bcae0e (diff) | |
parent | b8589e2a8065b8e7773742b60ae96b63b757bb69 (diff) |
Merge tag 'mfd_3.4-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6
Pull MFD changes from Samuel Ortiz:
- 4 new drivers: Freescale i.MX on-chip Anatop, Ricoh's RC5T583 and
TI's TPS65090 and TPS65217.
- New variants support (8420, 8520 ab9540), cleanups and bug fixes for
the abx500 and db8500 ST-E chipsets.
- Some minor fixes and update for the wm8994 from Mark.
- The beginning of a long term TWL cleanup effort coming from the TI
folks.
- Various fixes and cleanups for the s5m, TPS659xx, pm860x, and MAX8997
drivers.
Fix up trivial conflicts due to duplicate patches and header file
cleanups (<linux/device.h> removal etc).
* tag 'mfd_3.4-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6: (97 commits)
gpio/twl: Add DT support to gpio-twl4030 driver
gpio/twl: Allocate irq_desc dynamically for SPARSE_IRQ support
mfd: Detach twl6040 from the pmic mfd driver
mfd: Replace twl-* pr_ macros by the dev_ equivalent and do various cleanups
mfd: Micro-optimization on twl4030 IRQ handler
mfd: Make twl4030 SIH SPARSE_IRQ capable
mfd: Move twl-core IRQ allocation into twl[4030|6030]-irq files
mfd: Remove references already defineid in header file from twl-core
mfd: Remove unneeded header from twl-core
mfd: Make twl-core not depend on pdata->irq_base/end
ARM: OMAP2+: board-omap4-*: Do not use anymore TWL6030_IRQ_BASE in board files
mfd: Return twl6030_mmc_card_detect IRQ for board setup
Revert "mfd: Add platform data for MAX8997 haptic driver"
mfd: Add support for TPS65090
mfd: Add some da9052-i2c section annotations
mfd: Build rtc5t583 only if I2C config is selected to y.
mfd: Add anatop mfd driver
mfd: Fix compilation error in tps65910.h
mfd: Add 8420 variant to db8500-prcmu
mfd: Add 8520 PRCMU variant to db8500-prcmu
...
Diffstat (limited to 'drivers/mfd/da9052-i2c.c')
-rw-r--r-- | drivers/mfd/da9052-i2c.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/mfd/da9052-i2c.c b/drivers/mfd/da9052-i2c.c index 44b97c70a61..36b88e39549 100644 --- a/drivers/mfd/da9052-i2c.c +++ b/drivers/mfd/da9052-i2c.c | |||
@@ -74,24 +74,27 @@ static int __devinit da9052_i2c_probe(struct i2c_client *client, | |||
74 | 74 | ||
75 | ret = da9052_i2c_enable_multiwrite(da9052); | 75 | ret = da9052_i2c_enable_multiwrite(da9052); |
76 | if (ret < 0) | 76 | if (ret < 0) |
77 | goto err; | 77 | goto err_regmap; |
78 | 78 | ||
79 | ret = da9052_device_init(da9052, id->driver_data); | 79 | ret = da9052_device_init(da9052, id->driver_data); |
80 | if (ret != 0) | 80 | if (ret != 0) |
81 | goto err; | 81 | goto err_regmap; |
82 | 82 | ||
83 | return 0; | 83 | return 0; |
84 | 84 | ||
85 | err_regmap: | ||
86 | regmap_exit(da9052->regmap); | ||
85 | err: | 87 | err: |
86 | kfree(da9052); | 88 | kfree(da9052); |
87 | return ret; | 89 | return ret; |
88 | } | 90 | } |
89 | 91 | ||
90 | static int da9052_i2c_remove(struct i2c_client *client) | 92 | static int __devexit da9052_i2c_remove(struct i2c_client *client) |
91 | { | 93 | { |
92 | struct da9052 *da9052 = i2c_get_clientdata(client); | 94 | struct da9052 *da9052 = i2c_get_clientdata(client); |
93 | 95 | ||
94 | da9052_device_exit(da9052); | 96 | da9052_device_exit(da9052); |
97 | regmap_exit(da9052->regmap); | ||
95 | kfree(da9052); | 98 | kfree(da9052); |
96 | 99 | ||
97 | return 0; | 100 | return 0; |
@@ -107,7 +110,7 @@ static struct i2c_device_id da9052_i2c_id[] = { | |||
107 | 110 | ||
108 | static struct i2c_driver da9052_i2c_driver = { | 111 | static struct i2c_driver da9052_i2c_driver = { |
109 | .probe = da9052_i2c_probe, | 112 | .probe = da9052_i2c_probe, |
110 | .remove = da9052_i2c_remove, | 113 | .remove = __devexit_p(da9052_i2c_remove), |
111 | .id_table = da9052_i2c_id, | 114 | .id_table = da9052_i2c_id, |
112 | .driver = { | 115 | .driver = { |
113 | .name = "da9052", | 116 | .name = "da9052", |