aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-06-03mfd: ipaq-micro: Make mfd_cell array constKrzysztof Kozlowski1-1/+1
mfd_add_devices() expects array of struct mfd_cell to be const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Linus Walleij <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: ipaq-micro: Use devm_ioremap_resource()Jingoo Han1-6/+6
Use devm_ioremap_resource() because devm_request_and_ioremap() is obsoleted by devm_ioremap_resource(). Signed-off-by: Jingoo Han <[email protected]> Acked-by: Linus Walleij <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: Add driver for Atmel Microcontroller on iPaq h3xxxLinus Walleij4-0/+641
This adds a driver for the Atmel Microcontroller found on the iPAQ h3xxx series. This device handles some keys, the touchscreen, and the battery monitoring. This is a port of a driver from handhelds.org 2.6.21 kernel, written by Alessandro Gardich based on Andrew Christians original HAL-driver. It has been heavily cleaned and converted to mfd-core by Dmitry Artamonow and rewritten again for the v3.x series kernels by Linus Walleij, bringing back some of the functionality lost from Andrew's original driver. Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Alessandro Gardich <[email protected]> Signed-off-by: Dmitry Artamonow <[email protected]> Signed-off-by: Linus Walleij <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: syscon: Include linux/err.h to fix build errorTushar Behera1-0/+2
commit df73de9b0d412 ("mfd: syscon: Return -ENOSYS if CONFIG_MFD_SYSCON is not enabled") introduced fallbacks for APIs, but missed out on adding the header file. This would work only if linux/err.h is also included in the source code from where this file is included. It would be better to include linux/err.h in file to remove possible build errors. Without this patch, we get following and similar build errors if this header file is included in some source file and CONFIG_MFD_SYSCON is not enabled. include/linux/mfd/syscon.h: In function ‘syscon_node_to_regmap’: include/linux/mfd/syscon.h:30:2: error: implicit declaration of function ‘ERR_PTR’ [-Werror=implicit-function-declaration] return ERR_PTR(-ENOSYS); ^ include/linux/mfd/syscon.h:30:18: error: ‘ENOSYS’ undeclared (first use in this function) return ERR_PTR(-ENOSYS); ^ Signed-off-by: Tushar Behera <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: Add support for sun6i PRCM (Power/Reset/Clock Management) unitBoris BREZILLON3-0/+143
The PRCM (Power/Reset/Clock Management) block exposes several subdevices in different subsystems (clk, reset ...) Add basic support for the PRCM unit with clk (AR100, AHB0, and APB0 clks) and reset controller subdevices. Other subdevices might be added later (if needed). Signed-off-by: Boris BREZILLON <[email protected]> Acked-by: Maxime Ripard <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: sun6i-prcm: Document DT bindingsBoris BREZILLON1-0/+59
Document DT bindings of the PRCM (Power/Reset/Clock Management) unit. Signed-off-by: Boris BREZILLON <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: rtsx_usb: Make mfd_cell array constKrzysztof Kozlowski1-1/+1
mfd_add_devices() expects array of struct mfd_cell to be const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Roger Tseng <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: omap-usb-host: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by of_platform_populate() call. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: as3711: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by of_match_table field. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max14577: Make mfd_cell array constKrzysztof Kozlowski1-3/+3
mfd_add_devices() expects array of struct mfd_cell to be const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: lp3943: Make mfd_cell array constKrzysztof Kozlowski1-1/+1
mfd_add_devices() expects array of struct mfd_cell to be const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Milo Kim <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max14577: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id should be const as expected by both of_match_table field and of_match_device() call. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: sec-core: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by both of_match_table field and of_match_node() call. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: wm8400-core: Make mfd_cell array constKrzysztof Kozlowski1-1/+1
mfd_add_devices() expects array of struct mfd_cell to be const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max8998: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by both of_match_table field and of_match_node() call. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: db8500-prcmu: Make mfd_cell array constKrzysztof Kozlowski1-1/+1
mfd_add_devices() expects array of struct mfd_cell to be const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Linus Walleij <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max8907: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by of_match_table field. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max77693: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by of_match_table field. Signed-off-by: Krzysztof Kozlowski <[email protected]> Reviewed-by: Chanwoo Choi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: kempld-core: Make mfd_cell array constKrzysztof Kozlowski1-1/+1
The kempld_devs (array of mfd_cells) can be safely made const. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Kevin Strasser <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max8997: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by both of_match_table field and of_match_node() call. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max77686: Make of_device_id array constKrzysztof Kozlowski1-1/+1
Array of struct of_device_id may be be const as expected by of_match_table field. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: mc13xxx: Do not use platform data with devicetreeAlexander Shiyan1-12/+10
This patch removes platform data usage for codec and touchscreen when driver is used with devicetree. This fixes possible "null pointer dereference" error if DTS uses "fsl,mc13xxx-uses-codec" or "fsl,mc13xxx-uses-touch" options. Signed-off-by: Alexander Shiyan <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: twl6040: Correct HPPLL configuration for 19.2 and 38.4 MHz mclkPeter Ujfalusi1-8/+5
When the MCLK is 19.2 or 38.4 MHz the HPPLL need to be enabled and can be put in bypass mode. This will fix HPPLL use on boards with 19.2MHz mclk. Signed-off-by: Peter Ujfalusi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: tps6586x: Make of_device_id array constJingoo Han1-1/+1
Make of_device_id array const, because all OF functions handle it as const. Signed-off-by: Jingoo Han <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: tps6507x: Make of_device_id array constJingoo Han1-1/+1
Make of_device_id array const, because all OF functions handle it as const. Signed-off-by: Jingoo Han <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: tps65910: Make of_device_id array constJingoo Han1-1/+1
Make of_device_id array const, because all OF functions handle it as const. Signed-off-by: Jingoo Han <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: sm501: Make of_device_id array constJingoo Han1-1/+1
Make of_device_id array const, because all OF functions handle it as const. Signed-off-by: Jingoo Han <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: AXP20x: Add mfd driver for AXP20x PMICCarlo Caione4-0/+451
This patch introduces the preliminary support for PMICs X-Powers AXP202 and AXP209. The AXP209 and AXP202 are the PMUs (Power Management Unit) used by A10, A13 and A20 SoCs and developed by X-Powers, a sister company of Allwinner. The core enables support for two subsystems: - PEK (Power Enable Key) - Regulators Signed-off-by: Carlo Caione <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: syscon: Allow property as NULL in syscon_regmap_lookup_by_phandlePankaj Dubey1-1/+5
If we pass syscon device node itself as first parameter to this function there is no need to parse and find syscon device node. So by allowing "property" parameter as NULL allow syscon_regmap_lookup_by_phandle to consider passed argument "np" itself as a syscon device node "syscon_np". This will help us in avoiding addition of "syscon" property in a device node which points back to same device node in device tree. Signed-off-by: Pankaj Dubey <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: pm8921: Remove pm8xxx API now that sub-devices use regmapStephen Boyd2-202/+2
The pm8xxx read/write wrappers are no longer necessary now that all the sub-device drivers are using the regmap API. Remove it. Signed-off-by: Stephen Boyd <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: max14577: Fix IRQ handling after resume if this is not a wakeup sourceKrzysztof Kozlowski1-16/+13
During suspend the IRQ should be disabled even if this is not a wakeup source. This is a proper way of fixing the IRQ handling issue during resume (IRQ handler fails because I2C bus did not resume yet). When device is suspended and max14577 interrupt is signaled the irq chip will try to handle it regardless of wakeup source. Device could be woken up by different IRQ but still the IRQ handler will try to read the registers over I2C bus and fail because I2C bus won't be ready yet: max14577 2-0025: Failed to read IRQ status: -5 Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: sec-core: Fix IRQ handling after resume if this is not a wakeup sourceKrzysztof Kozlowski1-15/+13
During suspend the IRQ should be disabled even if this is not a wakeup source. This is a proper way of fixing the IRQ handling issue during resume (IRQ handler fails because I2C bus did not resume yet). When device is suspended and sec-core interrupt is signaled the irq chip will try to handle it regardless of wakeup source. Device could be woken up by different IRQ but still the IRQ handler will try to read the registers over I2C bus and fail because I2C bus won't be ready yet. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: sec-core: Remove duplicated device type from sec_pmic_devKrzysztof Kozlowski3-5/+5
The device type was stored in sec_pmic_dev state container twice: - unsigned long type (initialized from of_device_id or i2c_device_id) - int device_type (initialized as above or from board files when there is no DTS) The 'type' field was never used outside of probe so it can be safely removed. Change also the device_type in sec_pmic_dev and sec_platform_data to unsigned long to avoid any casts. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: twl6040: Move register patching earlier in probePeter Ujfalusi1-4/+3
Make sure that we patch the ACCCTL register as the first thing when the driver loads, thus configuring I2C fast mode and i2c access for dual access registers. Signed-off-by: Peter Ujfalusi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: twl6040: Optional clk32k clock handlingPeter Ujfalusi3-0/+14
In certain boards the source for the clk32k clock can be gated. In these boards the clk32k clock can be provided to the driver and it is going to be enabled/disabled when it is needed. If the clk32k clock is not provided the driver will assume that it is always running. Signed-off-by: Peter Ujfalusi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: twl6040: Select i2c fast mode as default with regmap patchPeter Ujfalusi2-2/+8
All boards using twl6040 configures the i2c bus to 400KHz. While twl6040's defaults to normal mode (100KHz). So far twl6040 has no problem with i2c communication in this configuration it is safer to select fast i2c mode. Signed-off-by: Peter Ujfalusi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: twl6040: Clear the interrupt ID register before requesting IRQPeter Ujfalusi1-0/+3
If for some reason the boot loader enabled the audpwron GPIO we will have pending IRQs to be handled. This seams to break twl6040 for some reason leading to non working i2c communication (i2c timeouts). Clearing the INTID register after we requested the audpwron GPIO (and set it to low) will ensure that the chip will operate normally in this case as well. Signed-off-by: Peter Ujfalusi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: core: Don't use devres functions before device is addedCharles Keepax1-4/+7
The supply aliases for the MFD devices were being added using devres but the device hasn't been added at this point and as such we can't use devres. The MFD already has a function that removes devices this patch uses the non-devres versions of the supply alias functions and adds an unregister in mfd_remove_devices_fn. Reported-by: Carlo Caione <[email protected]> Reported-by: Mark Brown <[email protected]> Signed-off-by: Charles Keepax <[email protected]> Reviewed-by: Mark Brown <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: rdc321x: Fix off-by-one for ngpio settingAxel Lin2-2/+2
The valid gpio is GPIO0 ~ GPIO58, so ngpio should be 59. This patch also renames RDC321X_MAX_GPIO to RDC321X_NUM_GPIO because it actually means the number of available GPIOs. Signed-off-by: Axel Lin <[email protected]> Acked-by: Linus Walleij <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: sec-core: Update sec_pmic documentationKrzysztof Kozlowski1-12/+17
Update the documentation for sec_pmic state container structure to reflect current code. Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd/rtc: s5m: Do not allocate RTC I2C dummy and regmap for unsupported chipsetsKrzysztof Kozlowski3-60/+71
The rtc-s5m driver does not support all of S2M and S5M chipsets supported by main MFD sec-core driver. For such chipsets unsupported by rtc-s5m, the MFD sec-core driver initialized regmap with default config. This config in such cases wouldn't work at all. The main MFD sec-core driver shouldn't initialize regmap for child drivers which is not used by them and even not valid. Move the allocation of RTC I2C dummy device and initialization of RTC regmap from main MFD sec-core driver to the rtc-s5m driver. The rtc-s5m driver will use proper regmap config for supported devices. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Alessandro Zummo <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: cros_ec: cleanup: cros_ec.c is GPL licensed, like all the others.Bill Richardson1-0/+3
This module has always been GPL licensed. It was just missing the explicit declaration to avoid tainting the kernel. Signed-off-by: Bill Richardson <[email protected]> Signed-off-by: Doug Anderson <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: lpc_ich: Enable GPIO for Panther PointGuenter Roeck1-0/+1
Panther Point PCH GPIO configuration is similar to V5 PCHs. Signed-off-by: Guenter Roeck <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: wm5110: Add missing isolation control registerCharles Keepax1-0/+2
The isolation control register is required when DCVDD is externally supplied add this in as a readable register. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: tps65218: Remove unused *rdev[] from struct tps65218Axel Lin1-1/+0
The *rdev[] is not used since commit 413be59e2f333 "regulator: tps65218: Remove unnecessary regulator_unregister call". Signed-off-by: Axel Lin <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: mc13xxx-core: Initialize the lock prior to using itFabio Estevam1-2/+2
After request_threaded_irq() is called there is a chance that an interrupt may occur before the 'mc13xxx->lock' is initialized, which will trigger a kernel oops. In order to prevent that, move the initialization of 'mc13xxx->lock' prior to requesting the interrupts. Suggested-by: Russell King <[email protected]> Signed-off-by: Fabio Estevam <[email protected]> Acked-by: Russell King <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: mc13xxx: Move definitions out of structuresAlexander Shiyan1-10/+12
Signed-off-by: Alexander Shiyan <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: abx500-core: Fix compiler warning larger stack frameJay Aurabind2-5/+9
On systems with CONFIG_FRAME_WARN=1024, compiler warns the allocation of an object of struct device on stack. Make the allocation dynamically to fix the warning. Also change the caller's return type to int so as to account for error handling. drivers/mfd/abx500-core.c: In function ‘abx500_dump_all_banks’: drivers/mfd/abx500-core.c:167:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=] Signed-off-by: Aurabindo J <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: Add sysfs attributes for Kontron PLD firmware revisionMichael Brunner2-21/+110
This patch adds attributes to the Kontron PLD driver to allow applications to retrieve firmware information. Additionally the format has been changed to conform with the representation in other Kontron software. Signed-off-by: Michael Brunner <[email protected]> Reviewed-by: Guenter Roeck <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2014-06-03mfd: bcm590xx: Fix modalias prefixAxel Lin1-1/+1
This is a i2c driver, so uses i2c prefix in modalias. Signed-off-by: Axel Lin <[email protected]> Signed-off-by: Lee Jones <[email protected]>