aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2010-10-29mfd: Fix resource reclaim for max8998Axel Lin1-0/+4
Properly free irq and unregister max8998->rtc device in max8998_i2c_probe() error path and max8998_i2c_remove(). Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Remove unneeded ret value checking for max8998 register updatesAxel Lin1-2/+0
i2c_smbus_write_byte_data() returns zero or negative value, therefore no need to check if ret is greater than zero or not. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add free max8998->ono irq in max8998_irq_exit()Axel Lin1-0/+3
Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix resource reclaim in pcf50633_remove()Axel Lin1-0/+2
Calling sysfs_remove_group() to remove sysfs entries and unregister bl_pdev in pcf50633_remove(). Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Harald Welte <laforge@gnumonks.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29omap4: pandaboard: fix up mmc card detect logicMenon, Nishanth1-3/+12
For MMC1 Controller, card detect interrupt source is twl6030 which is non-gpio. The card detect call back function provides card present/absent status by reading MMC Control register present on twl6030. This functionality was introduced in mfd tree on track to kernel.org Sync pandaboard to the same and make mmc work. Cc: Tony Lindgren <tony@atomide.com> Cc: Madhusudhan Chikkature <madhu.cr@ti.com> Cc: Adrian Hunter <adrian.hunter@nokia.com> Cc: Samuel Ortiz <sameo@linux.intel.com> Acked-by: Kishore Kadiyala <kishore.kadiyala@ti.com> Signed-off-by: Nishanth Menon <nm@ti.com> Tested-by: Jarkko Nikula <jhnikula@gmail.com> Acked-by: Madhusudhan Chikkature <madhu.cr@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix ezx_pcap_probe error pathAxel Lin1-0/+1
return -ENOMEM if create_singlethread_workqueue failed. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix off-by-one value range checking for tps6507xAxel Lin1-1/+1
If bytes == (TPS6507X_MAX_REGISTER + 1), we have a buffer overflow when doing memcpy(&msg[1], src, bytes). Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Remove __devinitdata from tc6393xb_mmc_resourcesMarek Vasut1-1/+1
This static struct resource tc6393xb_mmc_resources[] is used in resume function, therefore the data can not be wiped after init. Also, this causes a section mismatch. Signed-off-by: Marek Vasut <marek.vasut@gmail.com> Acked-by: Ian Molton <ian@mnementh.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add WM831x SPI supportMark Brown3-0/+244
Implement support for controlling WM831x and WM832x devices using SPI. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Factor out WM831x I2C I/O from the core driverMark Brown6-139/+171
In preparation for the addition of SPI support for the WM831x move the I2C specific code into a separate file with a separate Kconfig option so the I2C support can be excluded from the build. Also update the 1133-EV1 PMIC module support for SMDK6410 to use the new symbol. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Remove DEBUG defines from mc13xxx-coreSamuel Ortiz1-2/+0
DEBUG and VERBOSE_DEBUG are not used. Reported-by: David Jander <david@protonic.nl> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix jz4740_adc_set_enabledAxel Lin1-1/+1
When enabled is false, clear BIT(engine) of JZ_REG_ADC_ENABLE register. Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add TPS658621C device IDAndrew Chew1-1/+3
The interface for this device should be identical to that of the TPS658521A. Signed-off-by: Andrew Chew <achew@nvidia.com> Acked-by: Mike Rapoport <mike@compulab.co.il> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix twl-irq function declaration warningsG, Manjunath Kondaiah3-0/+13
Fixes following sparse warnings for twl4030 and twl6030 irq files. drivers/mfd/twl4030-irq.c:783:5: warning: symbol 'twl4030_init_irq' was not declared. Should it be static? drivers/mfd/twl4030-irq.c:863:5: warning: symbol 'twl4030_exit_irq' was not declared. Should it be static? drivers/mfd/twl4030-irq.c:873:5: warning: symbol 'twl4030_init_chip_irq' was not declared. Should it be static? drivers/mfd/twl6030-irq.c:226:5: warning: symbol 'twl6030_init_irq' was not declared. Should it be static? drivers/mfd/twl6030-irq.c:290:5: warning: symbol 'twl6030_exit_irq' was not declared. Should it be static? Signed-off-by: G, Manjunath Kondaiah <manjugk@ti.com> Cc: linux-arm-kernel@lists.infradead.org Cc: Tony Lindgren <tony@atomide.com> Cc: Nishanth Menon <nm@ti.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29regulator: max8998 BUCK1/2 voltage change with use of GPIOsLukasz Majewski1-21/+193
max8998_pmic_probe: - modified to check if valid pins are defined at platform data - maximal voltage values (predefined at platform data) are uploaded to max8998 device max8998_set_voltage_buck: - BUCK1/2 voltages change between values already defined - Checks if valid GPIO pins are passed from platform data - If requested voltage cannot be satisfied from already defined values, then one of free slots is used - Predefined maximum voltages (as defined at platform data) are always available Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Voltages and GPIOs platform_data definitions for max8998Lukasz Majewski1-0/+12
Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29regulator: max8998 BUCK1/2 internal voltages and indexes definedLukasz Majewski2-8/+14
BUCK1/2 internal voltages and indexes defined in the struct max8998_data max_get_voltage_register now uses index values to chose proper register More generic BUCK1/2 registers names provided Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Support for ICs compliant with max8998Lukasz Majewski2-2/+14
Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29regulator: Separate set_voltage for max8998 ldo and buckLukasz Majewski1-3/+40
Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix TWL4030 COR bit polarity for BCI SIH blockGrazvydas Ignotas1-1/+2
The chip TRM documentation contradicts itself about this bit, page 174 of swcu050e says bit should be 0 for clear-on-read behavior, while page 487 says it should be 1. Testing shows it should be 1, so set the .set_cor flag accordingly. This is needed for upcoming BCI charging driver to function. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add devices platform data when the cell data size is not 0Brian Harring1-4/+6
When the cell data_size is 0, the resulting platform_data pointer will be set to ZERO_SIZE_PTR. That could be misleading for device drivers running a NULL check on thei platform_data pointer before dereferencing it. Signed-off-by: Brian Harring <ferringb@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add twl4030_bci platform_data backGrazvydas Ignotas1-0/+17
Now that we have twl4030 charger driver, add back it's platform_data (which was removed by f7ea2dc59ed46dcd0f1cfaccda02211f4507207b as unused). Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29rtc: Add support for the rtc found in the MC13892 PMICUwe Kleine-König4-433/+443
The mfd driver for MC13783 recently got support for MC13892 and was renamed accordingly from mc13783-core to mc13xxx-core. Do the same for rtc-mc13783. The only relevant change is to use platform id's to tell the platform bus that this driver is responsible for mc13892-rtc devices, too. Acked-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Adding twl6030 mmc card detect support for MMC1kishore kadiyala4-3/+112
Adding card detect callback function and card detect configuration function for MMC1 Controller on OMAP4. Card detect configuration function does initial configuration of the MMC Control & PullUp-PullDown registers of Phoenix. For MMC1 Controller, card detect interrupt source is twl6030 which is non-gpio. The card detect call back function provides card present/absent status by reading MMC Control register present on twl6030. Since OMAP4 doesn't use any GPIO line as used in OMAP3 for card detect, the suspend/resume initialization which was done in omap_hsmmc_gpio_init previously is moved to the probe thus making it generic for both OMAP3 & OMAP4. Cc: Tony Lindgren <tony@atomide.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Madhusudhan Chikkature <madhu.cr@ti.com> Cc: Adrian Hunter <adrian.hunter@nokia.com> Signed-off-by: Kishore Kadiyala <kishore.kadiyala@ti.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add mc13892 support to mc13xxxUwe Kleine-König6-882/+1113
mc13892 is the companion PMIC for Freescale's i.MX51. It's similar enough to mc13782 to support it in a single driver. This patch introduces enough compatibility cruft to keep all users of the superseded mc13783 driver unchanged. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Remove deprecated mc13783 functionsUwe Kleine-König1-18/+0
The last user is gone since v2.6.34-rc1~40 Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Remove obsolete mc13783 private dataUwe Kleine-König1-18/+9
The regulator driver was converted to get the needed data directly from platform_data by a10099b (regulator/mc13783: various cleanups) so regulators and num_regulators can go away. Then apart from the flag indicating that the adc does a conversion, flags is only a copy of the flags member of platform_data. This flag isn't needed to be returned by mc13783_get_flags, so mc13783_get_flags now gets the flags from platform_data, too and the driver private member is renamed for clearity. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29gpio: Add VIA VX855 GPIO driverDaniel Drake3-0/+345
This is needed for supporting the upcoming VX855 camera and OLPC DCON drivers, as well as the advanced viafb features on non-OLPC hardware based on this chip. Based on earlier work by Harald Welte. Signed-off-by: Daniel Drake <dsd@laptop.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add VIA VX855 multi-function device supportDaniel Drake3-0/+157
This device has GPIO, SPI and I2C capabilities. The hardware can be found in the OLPC XO-1.5 laptop. Based on earlier work by Harald Welte. Signed-off-by: Daniel Drake <dsd@laptop.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Allow for bypass of cell resource conflict checkDaniel Drake2-3/+8
The upcoming VIA VX855 MFD driver needs to communicate resources to subdevices where the resources may be claimed by ACPI. Add a flag to mfd_cell to request that resources are not policed. Signed-off-by: Daniel Drake <dsd@laptop.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29input: Monitor both onkey up and down eventHaojian Zhuang2-21/+62
Remove original 3-second ONKEY event. Detect ONKEY changing event directly. So both UP and DOWN event of ONKEY in max8925 are monitered. Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29leds: Remove auto blink in 88pm860xHaojian Zhuang1-93/+26
88pm860x supports auto-blink LED in hardware. It messed with timer trigger. Now disable the auto-blink function. Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Cc: Richard Purdie <rpurdie@rpsys.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add WM8325 supportMark Brown1-0/+14
The WM8325 is a PMIC for low power, high performance applications. From a software point of view the device is identical to the WM8320, all the differences are at the hardware level. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Declare abx500_remove_ops()Mark Brown1-0/+1
Otherwise sparse warns about a public symbol with no declaration and the compiler can't spot if the callers and users have different signatures for the function. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Fix twl-core sparse warningG, Manjunath Kondaiah1-1/+1
Fixes below sparse warning. drivers/mfd/twl-core.c:258:20: warning: symbol 'twl_map' was not declared. Should it be static? Signed-off-by: G, Manjunath Kondaiah <manjugk@ti.com> Cc: linux-arm-kernel@lists.infradead.org Cc: Tony Lindgren <tony@atomide.com> Cc: Nishanth Menon <nm@ti.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Use DMA for timberdale's ks8842Richard Röjfors1-0/+14
This patch defines platform data for the ks8842 int the timberdale MFD. The platform data contains DMA channels to be used by the driver. Signed-off-by: Richard Röjfors <richard.rojfors@pelagicore.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add PM support to STMPE devicesSundar Iyer1-0/+32
Add PM helpers to STMPE and add support to enable wakeup from low power states Acked-by: Rabin VINCENT <rabin.vincent@stericsson.com> Acked-by: Linus WALLEIJ <linus.walleij@stericsson.com> Signed-off-by: Sundar Iyer <sundar.iyer@stericsson.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29gpio: Fix stmpe error pathVasiliy Kulikov1-2/+4
Free allocated memory. Call stmpe_disable() if it was enabled. Signed-off-by: Vasiliy Kulikov <segooon@gmail.com> Acked-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Rabin Vincent <rabin.vincent@stericsson.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: msp430 expects I2C to be built-inSamuel Ortiz1-1/+1
msp430 being a bool, it will only work with I2C=y Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Update kconfig for ab8500 core driverArun Murthy1-1/+1
This patch add a dependancy for ab8500-core driver so as to depend on u8500 platform. This patch also fixes the build issues(powerpc_allyesconfig) for the patch 03f582a93ecca6e9584b622570022abf08ed03ec (misc: Add ab8500 pwm driver) Signed-off-by: Arun Murthy <arun.murthy@stericsson.com> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Add basic tps6586x interrupt supportGary King3-2/+233
Add support for enabling and disabling tps6586x subdevice interrupts Signed-off-by: Gary King <gking@nvidia.com> Acked-by: Mike Rapoport <mike@compulab.co.il> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: AB8500 register access via PRCMU I2CMattias Wallin4-4/+121
This patch adds the choice of accessing the AB8500 registers via prcmu I2C. Access either via SPI or I2C is supported. Signed-off-by: Mattias Wallin <mattias.wallin@stericsson.com> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: AB8500 debugfsMattias Wallin4-0/+666
This patch adds the possibility to read and write registers via the debug_fs. It also adds ranges of registers sorted by bank which makes it possible to read all defined registers in a bank. Signed-off-by: Mattias Wallin <mattias.wallin@stericsson.com> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Reviewed-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Update chip id of 88pm8607Haojian Zhuang2-3/+6
Chipid of 88pm8607 is 0x40 or 0x50. Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29misc: Add ab8500 pwm driverArun Murthy4-1/+190
This patch adds a Pulse Width Modulation driver for Analog Baseband Chip AB8500. Signed-off-by: Arun Murthy <arun.murthy@stericsson.com> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Acked-by: Mike Rapoport <mike@compulab.co.il> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mfd: Align ab8500 with the abx500 interfaceMattias Wallin6-209/+296
This patch makes the ab8500 mixed signal chip expose the same interface for register access as the ab3100, ab3550 and ab5500 chip. The ab8500_read() and ab8500_write() is removed and replaced with abx500_get_register_interruptible() and abx500_set_register_interruptible(). Signed-off-by: Mattias Wallin <mattias.wallin@stericsson.com> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29gpio: Handle stmpe-gpio platform data with no gpio baseVirupax Sadashivpetimath1-2/+0
This patch removes the requirement that gpio base be supplied in platform data. Signed-off-by: Virupax Sadashivpetimath <virupax.sadashivpetimath@stericsson.com> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Acked-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mmc: Allow 2 byte requests in 4-bit mode for tmio_mmcYusuke Goda3-5/+23
Adjust the tmio_mmc block size check to accept 2-byte requests in 4-bit mode if the hardware supports it. Tested with the SDHI hardware block included in sh7724. Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com> Signed-off-by: Matt Fleming <matt@console-pimps.org> Acked-by: Magnus Damm <damm@opensource.se> Tested-by: Arnd Hannemann <arnd@arndnet.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29ARM: mach-shmobile: ap4evb: Fix hotplug for SDHI1Arnd Hannemann1-0/+19
On AP4EVB the card detect pin of the top SD/MMC slot is not directly connected to the tmio/mmcif controller but to a GPIO pin, so polling needs to be done for SDHI1 and MMCIF in order to support hotplug for that slot. SHDI1 and MMCIF share that slot, and the used controller is selected by a DIP switch. This patch adds a helper function to check if a card is present in that particular slot, registers this function with SDHI1 and MMCIF and enables polling for SDHI1. Signed-off-by: Arnd Hannemann <arnd@arndnet.de> Tested-by: Yusuke Goda <yusuke.goda.sx@renesas.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2010-10-29mmc: Allow the platform to specify the sh_mmcif get_cd handlerArnd Hannemann2-0/+13
In some platforms (e.g. AP4EVB) the card detect pin of a slot is not directly connected to the sh_mmcif controller, so that polling needs to be used. To overcome the overhead induced by querying the controller on each poll cycle, card detection can be handled in the platform code more efficiently. This patch exposes a get_cd hook for that purpose. Signed-off-by: Arnd Hannemann <arnd@arndnet.de> Tested-by: Yusuke Goda <yusuke.goda.sx@renesas.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>