Commit Graph

480382 Commits

Author SHA1 Message Date
Dmitry Eremin-Solenikov 1a5fb99de4 mfd: tc6393xb: Fail ohci suspend if full state restore is required
Some boards with TC6393XB chip require full state restore during system
resume thanks to chip's VCC being cut off during suspend (Sharp SL-6000
tosa is one of them). Failing to do so would result in ohci Oops on
resume due to internal memory contentes being changed. Fail ohci suspend
on tc6393xb is full state restore is required.

Recommended workaround is to unbind tmio-ohci driver before suspend and
rebind it after resume.

Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:52 +00:00
Andy Shevchenko bde3e706a6 mfd: lpc_sch: Don't call mfd_remove_devices()
MFD core already cares about failing registration. It will remove successfully
registered devices in case of error. Thus, no need to repeatedly call
mfd_remove_devices().

Fixes: 5829e9b64e (mfd: lpc_sch: Accomodate partial population of the MFD devices)
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:52 +00:00
Joe Perches 1753b40f5c mfd: wm8350-core: Fix probable mask then right shift defect
Precedence of & and >> is not the same and is not left to right.
shift has higher precedence and should be done after the mask.

Add parentheses around the mask.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:51 +00:00
Guenter Roeck 7d082baa34 mfd: ab8500-sysctrl: Drop ab8500_restart
ab8500_restart is not called from anywhere in the kernel, so drop it.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:50 +00:00
Lee Jones 6bdf891a17 mfd: db8500-prcmu: Provide sane error path values
Also rid superfluous gotos and label.

Cc: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:50 +00:00
Pramod Gurav 51a7e02bb6 mfd: db8500-prcmu: Check return of devm_ioremap for error
Error check around return value of devm_ioremap is missing. Add the same
to avoid NULL pointer dereference.

Signed-off-by: Pramod Gurav <pramod.gurav@smartplayin.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:49 +00:00
Tony Lindgren 1b9b46d05f mfd: twl4030-power: Fix regression with missing compatible flag
Commit e7cd1d1eb1 ("mfd: twl4030-power: Add generic reset
configuration") accidentally removed the compatible flag for
"ti,twl4030-power" that should be there as documented in the
binding.

If "ti,twl4030-power" only the poweroff configuration is done
by the driver.

Fixes: e7cd1d1eb1 ("mfd: twl4030-power: Add generic reset configuration")
Cc: stable@vger.kernel.org # v3.16+
Reported-by: "Dr. H. Nikolaus Schaller" <hns@goldelico.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:48 +00:00
Micky Ching 5cb5d9616a mfd: rtsx: Fix PM suspend for 5227 & 5249
Fix rts5227&5249 failed send buffer cmd after suspend,
PM_CTRL3 should reset before send any buffer cmd after suspend.
Otherwise, buffer cmd will failed, this will lead resume fail.

Signed-off-by: Micky Ching <micky_ching@realsil.com.cn>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:48 +00:00
Krzysztof Kozlowski 130dd5b039 mfd/regulator: dt-bindings: max77686: Document regulators off in suspend
Add information which regulators can be disabled during system suspend.

Suggested-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:47 +00:00
Javier Martinez Canillas 6ce286f182 Revert "mfd: sec-core: Prepare regulators for suspend state to reduce power-consumption"
This reverts commit b7cde7078d
("mfd: sec-core: Prepare regulators for suspend state to reduce power-consumption")

Commit b7cde7078d called regulator_suspend_prepare() to prepare the
regulators for a suspend state. But it did from the device pm suspend
handler while the regulator suspend prepare function iterates over all
regulators and not only the one managed by this device so it doesn't
seems to be correct to call it from within a device driver.

It is better to call the regulator suspend prepare/finish functions
from platform code instead so this patch reverts the mentioned commit.

Suggested-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Reviewed-by: Chanwoo Choi <cw00.choi@samsung.com>
Reviewed-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:47 +00:00
Krzysztof Kozlowski efa3ca414b mfd: max77693: Map charger device to its own of_node
Add a "maxim,max77693-charger" of_compatible to the mfd_cell so the MFD
child device (the charger) will have its own of_node set. This will be
used by the max77693 charger driver in next patches to obtain battery
configuration from DTS.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:46 +00:00
Will Sheppard 6f467e5f0c mfd: arizona-spi: Add lines after declarations - checkpatch catch
This was found whilst running checkpatch.pl on arizona-spi.

WARNING: Missing a blank line after declarations
+       struct arizona *arizona = spi_get_drvdata(spi);
+       arizona_dev_exit(arizona);

Signed-off-by: Will Sheppard <wsheppard@embedded-bits.co.uk>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:45 +00:00
Krzysztof Kozlowski 6cbac55368 mfd: max77693: Remove unused define
Remove old MAX77693_NUM_IRQ_MUIC_REGS define. Not used anywhere.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:45 +00:00
Boris Brezillon 590b7795b3 mfd: Add documentation for atmel-hlcdc DT bindings
The HLCDC IP available on some Atmel SoCs (i.e. at91sam9n12, at91sam9x5
family or sama5d3 family) exposes 2 subdevices:
- a display controller (controlled by a DRM driver)
- a PWM chip

This patch adds documentation for atmel-hlcdc DT bindings.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Tested-by: Anthony Harivel <anthony.harivel@emtrion.de>
Tested-by: Ludovic Desroches <ludovic.desroches@atmel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:44 +00:00
Boris Brezillon 2c86e9fb72 mfd: Add atmel-hlcdc driver
The HLCDC IP available on some Atmel SoCs (i.e. at91sam9n12, at91sam9x5
family or sama5d3 family) exposes 2 subdevices:
- a display controller (controlled by a DRM driver)
- a PWM chip

The MFD device provides a regmap and several clocks (those connected
to this hardware block) to its subdevices.

This way concurrent accesses to the iomem range are handled by the regmap
framework, and each subdevice can safely access HLCDC registers.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Tested-by: Anthony Harivel <anthony.harivel@emtrion.de>
Tested-by: Ludovic Desroches <ludovic.desroches@atmel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:43 +00:00
Johan Hovold 6e3f62f079 mfd: core: Fix platform-device id generation
Make sure to always honour multi-function devices registered with
PLATFORM_DEVID_NONE (-1) or PLATFORM_DEVID_AUTO (-2) as id base. In this
case it does not make sense to append the cell id to the mfd-id base and
potentially change the requested behaviour.

Specifically this will allow multi-function devices to be registered
with PLATFORM_DEVID_AUTO while still having non-zero cell ids.

Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:43 +00:00
Johan Hovold 16b5fe2966 HID: hid-sensor-hub: Use mfd_add_hotplug_devices() helper
Use mfd_add_hotplug_devices() helper to register the subdevices.

Compile-only tested.

Signed-off-by: Johan Hovold <johan@kernel.org>
Acked-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:42 +00:00
Johan Hovold 1ab589c72e mfd: Use mfd_add_hotplug_devices() helper
Use mfd_add_hotplug_devices helper to register the subdevices.

Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:42 +00:00
Pankaj Dubey bdb0066df9 mfd: syscon: Decouple syscon interface from platform devices
Currently a syscon entity can be only registered directly through a
platform device that binds to a dedicated syscon driver. However in
certain use cases it is desirable to make a device used with another
driver a syscon interface provider.

For example, certain SoCs (e.g. Exynos) contain system controller
blocks which perform various functions such as power domain control,
CPU power management, low power mode control, but in addition contain
certain IP integration glue, such as various signal masks,
coprocessor power control, etc. In such case, there is a need to have
a dedicated driver for such system controller but also share registers
with other drivers. The latter is where the syscon interface is helpful.

In case of DT based platforms, this patch decouples syscon object from
syscon platform driver, and allows to create syscon objects first time
when it is required by calling of syscon_regmap_lookup_by APIs and keep
a list of such syscon objects along with syscon provider device_nodes
and regmap handles.

For non-DT based platforms, this patch keeps syscon platform driver
structure so that syscon can be probed and such non-DT based drivers
can use syscon_regmap_lookup_by_pdev API and access regmap handles.
Once all users of "syscon_regmap_lookup_by_pdev" migrated to DT based,
we can completely remove platform driver of syscon, and keep only helper
functions to get regmap handles.

Suggested-by: Arnd Bergmann <arnd@arndb.de>
Suggested-by: Tomasz Figa <tomasz.figa@gmail.com>
Tested-by: Vivek Gautam <gautam.vivek@samsung.com>
Tested-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:41 +00:00
Jaewon Kim ee828d0261 mfd: max77693: Update DT binding to support haptic
This patch add haptic DT binding documentation and example
to support haptic driver in max77693 Multifunction device.

Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com>
Acked-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:40 +00:00
Jaewon Kim d1bafd78fc mfd: max77693: Add haptic of_compatible in mfd_cell
This patch add haptic of_compatible in order to use the haptic
device driver using Devicetree.

Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com>
Acked-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:40 +00:00
Jaewon Kim efbf49224a mfd: max77693: Initialize haptic register map
This patch add regmap_haptic initialization to use haptic register map
in haptic device driver.

Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com>
Acked-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:39 +00:00
Johannes Pointner 11d0d30093 mfd: tps65217: Add compatible string for subdevices
Adds of_compatible strings to mfd_cells for sub devices of the tps65217.

Signed-off-by: Johannes Pointner <johannes.pointner@br-automation.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 16:18:38 +00:00
Lee Jones a9e2e4733c Immutable branch between MFD, Regulator and Clk, due for v3.19
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJUdKaZAAoJEFGvii+H/HdhPj8P/1Jl60LnYPozG0eu6+rNaLDj
 AL8bNLWh0pANQzpYstE4aHDmrEWTArJ37eIet6BrPN/nv/ej2DR7hgK7Eh8h4P1t
 2LtBpxCT3f/Md92iBTLa/bMFm4VuuT/GiOurb1vR9BtTyH1bD8ftmXwhmzHskBuT
 wK0lfdvLEMRI2YIkgnLcuto07kMAIbLAQ4TANWvnHL2XLGd0/aPn68q3jNgwPjgf
 ufi5/eV8y+M/oopYPjU4Mt4W5fOTCZ6yINsp3tkOhPk9G28wJSmAiDkm9bn7KVrz
 Jwy60tpO9Z2+kff62uMjcWvMEvnMcrfQJ3cGm+Si64DuM+s2hmWpA/rXeO+Ep7VX
 jk3aiYXkFmUfgFXz7qMhFEERXu4nwhSGgdbEZWRmG8rcSaS3KnBNDaSvZOOH2mCq
 8iQmMzSMDK6CnW2wIr+2AsrrizPEPrvMOs7GLiUiyXlOjkUSR1XjJ6HlIfXKiMYg
 bWliacyGm3v+K3g41u9ULHNmLi779SlsUrH+Z6NARN5kRKXvsPntDA+8em11euvt
 7h1/wyPpjvJi8Cj5VJzinh4l/9t9O2GNeDuKExuOnaRHoOhzGkFwwMBgUkEdb5lX
 1il7JIXb/MfrwDbd4EZ/G0Ju2icFOfuwCAjad0upBfGkU11zJEa/KozN1ymjq/bD
 whTJLra7D6P0E8DBdS/0
 =WTv4
 -----END PGP SIGNATURE-----

Merge branches 'ib-mfd-gpio-i2c-3.19', 'ib-mfd-iio-3.19' and 'ib-mfd-regulator-v3.19', tag 'ib-mfd-regulator-clk-v3.19' into ibs-for-mfd-merged

Immutable branch between MFD, Regulator and Clk, due for v3.19
2014-11-25 16:18:03 +00:00
Chanwoo Choi 159a5e9204 mfd: s2mps11: Add binding documentation for Samsung S2MPS13 PMIC
This patch adds the binding documentation for Samsung S2MPS13 PMIC
which is similiar with existing S2MPS14 PMIC. S2MPS13 has the different number
of regulators from S2MPS14 and RTC/Clock is the same with the S2MPS14.

Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 15:55:12 +00:00
Chanwoo Choi f928b53d74 clk: s2mps11: Add the support for S2MPS13 PMIC clock
This patch adds the support for S2MPS13 PMIC clock which is same with existing
S2MPS14 RTC IP. But, S2MPS13 uses all of clocks (32khz_{ap|bt|cp}).

Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Acked-by: Michael Turquette <mturquette@linaro.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 15:55:11 +00:00
Chanwoo Choi 76b9840b24 regulator: s2mps11: Add support S2MPS13 regulator device
This patch adds S2MPS13 regulator device to existing S2MPS11 device driver.
The S2MPS13 has just different number of regulators from S2MPS14.
The S2MPS13 regulator device includes LDO[1-40] and BUCK[1-10].

Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Acked-by: Mark Brown <broonie@kernel.org>
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 15:55:06 +00:00
Chanwoo Choi 3bc2ee91a4 mfd: sec-core: Add support for S2MPS13 device
This patch adds the support for Samsung S2MPS13 PMIC device to the sec-core MFD
driver. The S2MPS13 is very similar with existing S2MPS14 and includes PMIC/
RTC/CLOCK devices.

Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Acked-by: Sangbeom Kim <sbkim73@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-25 15:55:01 +00:00
Dan Carpenter 2fc2b4846c mfd: dln2: A couple endian fixes
Sparse catches a couple endian bugs.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Octavian Purdila <octavian.purdila@intel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-19 17:12:59 +00:00
Octavian Purdila 00ee7a37fd mfd: dln2: Add a limit check for invalid echo
The echo field in dln2_transfer_complete comes directly from an USB
transfer and we should not trust it is valid.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-19 17:12:50 +00:00
Octavian Purdila 9331642812 i2c: dln2: Simplify return flow for dln2_i2c_enable
This fixes the following kbuild test robot warning:

>> drivers/i2c/busses/i2c-dln2.c:70:1-4: WARNING: end returns can be simplified if negative or 0 value

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Reported-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Acked-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-19 17:12:37 +00:00
Octavian Purdila 7ca2b1c672 mfd: dln2: Fix _dln2_transfer return code
If wait_for_completion_interruptible_timeout returns a positive value
it may be propagated as the return value of _dln2_transfer. This
contradicts the documentation of the function and exposes unnecessary
internals to the callers.

This patch makes sure to set the return value to 0 in that case.

Reported-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-19 17:12:19 +00:00
Jacob Pan 8019f69627 iio/axp288_adc: remove THIS_MODULE owner
This is no longer needed in that platform driver_register will do it.

Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Acked-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-18 15:34:22 +00:00
Jacob Pan ff3bbc5c63 mfd/axp20x: avoid irq numbering collision
IRQ numbers in axp20x devices are defined with high-order bit first
in each IRQ enable/status registers. On Intel platforms it is more
common to number IRQs with least significant bit first. Therefore,
sharing IRQ# between the two is very difficult. Since AXP288 is a
customized PMIC for Intel platform and the amount of shared IRQs are
very small, we use separate IRQ numbering. This also fixes collision
and a duplicate in WBTO interrupt.

e.g. For the 16 interrupts controlled in IRQ enabled registers 1 & 2,
on axp20x for ARM, the PMIC local IRQ numbers and register bits are
mapped as:
IRQ#:  0  1  2  3  4  5  6  7      8  9 10 11 12 13 14 15
---------------------------------------------------------
ARM:   7  6  5  4  3  2  1  0      7  6  5  4  3  2  1  0
Intel: 0  1  2  3  4  5  6  7      0  1  2  3  4  5  6  7

Signed-off-by: Todd Brandt <todd.e.brandt@linux.intel.com>
Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Acked-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-18 15:34:13 +00:00
Aaron Lu 29ec0a25c8 iio: adc: Add module device table for autoloading
Add the module device id table so that the driver can be automatically
loaded once the platform device is created.

Signed-off-by: Aaron Lu <aaron.lu@intel.com>
Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Acked-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-18 15:33:52 +00:00
Daniel Baluta 6732127f62 gpio: add support for the Diolan DLN-2 USB GPIO driver
This patch adds GPIO and IRQ support for the Diolan DLN-2 GPIO module.

Information about the USB protocol interface can be found in the
Programmer's Reference Manual [1], see section 2.9 for the GPIO
module commands and responses.

[1] https://www.diolan.com/downloads/dln-api-manual.pdf

Signed-off-by: Daniel Baluta <daniel.baluta@intel.com>
Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-10 16:30:09 +00:00
Laurentiu Palcu db23e5001f i2c: add support for Diolan DLN-2 USB-I2C adapter
This patch adds support for the Diolan DLN-2 I2C master module. Due
to hardware limitations it does not support SMBUS quick commands.

Information about the USB protocol interface can be found in the
Programmer's Reference Manual [1], see section 6.2.2 for the I2C
master module commands and responses.

[1] https://www.diolan.com/downloads/dln-api-manual.pdf

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Acked-by: Wolfram Sang <wsa@the-dreams.de>
Reviewed-by: Johan Hovold <johan@kernel.org>
[Lee: Fixed some whitespace issues in Kconfig]
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-10 16:30:07 +00:00
Octavian Purdila 338a128142 mfd: Add support for Diolan DLN-2 devices
This patch implements the USB part of the Diolan USB-I2C/SPI/GPIO
Master Adapter DLN-2. Details about the device can be found here:

https://www.diolan.com/i2c/i2c_interface.html.

Information about the USB protocol can be found in the Programmer's
Reference Manual [1], see section 1.7.

Because the hardware has a single transmit endpoint and a single
receive endpoint the communication between the various DLN2 drivers
and the hardware will be muxed/demuxed by this driver.

Each DLN2 module will be identified by the handle field within the DLN2
message header. If a DLN2 module issues multiple commands in parallel
they will be identified by the echo counter field in the message header.

The DLN2 modules can use the dln2_transfer() function to issue a
command and wait for its response. They can also register a callback
that is going to be called when a specific event id is generated by
the device (e.g. GPIO interrupts). The device uses handle 0 for
sending events.

[1] https://www.diolan.com/downloads/dln-api-manual.pdf

Signed-off-by: Octavian Purdila <octavian.purdila@intel.com>
Reviewed-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-10 16:30:05 +00:00
Johan Hovold a7975473cc mfd: core: Add helper function to register hotplug devices
Hot-pluggable multi-function devices should always be registered with
PLATFORM_DEVID_AUTO to avoid name collisions on the platform bus. This
helper also hides the memory map and irq parameters, which aren't used
by hot-pluggable (e.g. USB-based) devices.

Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-11-10 16:30:03 +00:00
Romain Perier a4b4e0461e of: Add standard property for poweroff capability
Several drivers create their own devicetree property when they register
poweroff capabilities. This is for example the case for mfd, regulator
or power drivers which define "vendor,system-power-controller" property.
This patch adds support for a standard property "poweroff-source"
which marks the device as able to shutdown the system.

Signed-off-by: Romain Perier <romain.perier@gmail.com>
Acked-by: Grant Likely <grant.likely@linaro.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
2014-10-22 16:59:36 +01:00
Linus Torvalds f114040e3e Linux 3.18-rc1 2014-10-19 18:08:38 -07:00
Linus Torvalds 4d3639ac3c ARM: SoC fixes for -rc1
A batch of fixes that have come in during the merge window.
 
 Some of them are defconfig updates for things that have now landed,
 some errata additions and a few general scattered fixes.
 
 There's also a qcom DT update that adds support for SATA on AP148,
 and basic support for Sony Xperia Z1 and CM-QS600 platforms that seemed
 isolated enough that we could merge it even if it's late.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJURCIHAAoJEIwa5zzehBx3Y9wP/1u9tcUjJs+AXD5RSRvabd50
 sN2oDk6cg3NzIvy9gzpmDXpHq9T0k/ce37a/NW/Rvyhq17u+g2EoC4XfR/8xeWAe
 uijbWzqmfhONSAPXc9+fwqjtdNKBj7e+4mtRSsdvMjduu6bpqAvhKEtRhCQeaKbv
 COjERAvDviAtW7Bpn/8j1ZVYJ0Yng5C7lT00GKNGXoGJ8aA9E4Yu3fhzBPitpkhX
 deLBHo7Ku32J9umoSqViQ5Ba25wCDESPPjLOYmKScj0pTlduywKerW4i5Bk8Pbo2
 ZJ/sA/glpSXqksAjbcdhzn2jntVz6a2e1ur7fibS+h73q2fRx3Gr8O02TiRl8nwZ
 VlbOFq/lovn+fFu7as5hoM5F4f/agHLuQBKYnuZvJ5OoXDO0vlo1+smEWw/4ta+f
 GVVxMOPcRaEiOoez+iJxQzoQGNFz3D5Ei9UMX6xkwpixBR3kx/m5WYhP/IO+qx4/
 Nkn0yAoRYfgx3zclqAhmqHkvbvcKrnYnHa4mV0xhhh6Mm0QOwZcKdfXCrQqrW8sm
 Jr5Dh6Ehha+i9Hp/eabVf/Tfr8BibSa/FYoMaP9pj++Ol5jJlYcwa+59jrnJ42t2
 GZEQKuWhl3DFCrMA/DPg968eNPOVunS039BJ0Se29Y3u6ulZSkl473OicueNJSEd
 XNGDyuHhhtBVJzQjzJ3z
 =V3Rv
 -----END PGP SIGNATURE-----

Merge tag 'arm-soc-fixes-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc

Pull ARM SoC fixes from Olof Johansson:
 "A batch of fixes that have come in during the merge window.

  Some of them are defconfig updates for things that have now landed,
  some errata additions and a few general scattered fixes.

  There's also a qcom DT update that adds support for SATA on AP148, and
  basic support for Sony Xperia Z1 and CM-QS600 platforms that seemed
  isolated enough that we could merge it even if it's late"

* tag 'arm-soc-fixes-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
  MAINTAINERS: corrected bcm2835 search
  ARM: dts: Explicitly set dr_mode on exynos5420-arndale-octa
  ARM: dts: Explicitly set dr_mode on exynos Peach boards
  ARM: dts: qcom: add CM-QS600 board
  ARM: dts: qcom: Add initial DTS file for Sony Xperia Z1 phone
  ARM: dts: qcom: Add SATA support on IPQ8064/AP148
  MAINTAINERS: Update Santosh Shilimkar's email id
  ARM: sunxi_defconfig: enable CONFIG_REGULATOR
  ARM: dts: Disable smc91x on n900 until bootloader dependency is removed
  ARM: omap2plus_defconfig: Enable ARM erratum 430973 for omap3
  ARM: exynos_defconfig: enable USB gadget support
  ARM: exynos_defconfig: Enable Maxim 77693 and I2C GPIO drivers
  ARM: mm: Fix ifdef around cpu_*_do_[suspend, resume] ops
  ARM: EXYNOS: Fix build with PM_SLEEP=n and ARM_EXYNOS_CPUIDLE=n
  ARM: SAMSUNG: Restore Samsung PM Debug functionality
  ARM: dts: Fix pull setting in sd4_width8 pin group for exynos4x12
  ARM: exynos_defconfig: Enable SBS battery support
  ARM: exynos_defconfig: Enable Control Groups support
  ARM: exynos_defconfig: Enable Atmel maXTouch support
  ARM: exynos_defconfig: Enable MAX77802
2014-10-19 17:43:06 -07:00
Linus Torvalds ab074ade9c Merge git://git.infradead.org/users/eparis/audit
Pull audit updates from Eric Paris:
 "So this change across a whole bunch of arches really solves one basic
  problem.  We want to audit when seccomp is killing a process.  seccomp
  hooks in before the audit syscall entry code.  audit_syscall_entry
  took as an argument the arch of the given syscall.  Since the arch is
  part of what makes a syscall number meaningful it's an important part
  of the record, but it isn't available when seccomp shoots the
  syscall...

  For most arch's we have a better way to get the arch (syscall_get_arch)
  So the solution was two fold: Implement syscall_get_arch() everywhere
  there is audit which didn't have it.  Use syscall_get_arch() in the
  seccomp audit code.  Having syscall_get_arch() everywhere meant it was
  a useless flag on the stack and we could get rid of it for the typical
  syscall entry.

  The other changes inside the audit system aren't grand, fixed some
  records that had invalid spaces.  Better locking around the task comm
  field.  Removing some dead functions and structs.  Make some things
  static.  Really minor stuff"

* git://git.infradead.org/users/eparis/audit: (31 commits)
  audit: rename audit_log_remove_rule to disambiguate for trees
  audit: cull redundancy in audit_rule_change
  audit: WARN if audit_rule_change called illegally
  audit: put rule existence check in canonical order
  next: openrisc: Fix build
  audit: get comm using lock to avoid race in string printing
  audit: remove open_arg() function that is never used
  audit: correct AUDIT_GET_FEATURE return message type
  audit: set nlmsg_len for multicast messages.
  audit: use union for audit_field values since they are mutually exclusive
  audit: invalid op= values for rules
  audit: use atomic_t to simplify audit_serial()
  kernel/audit.c: use ARRAY_SIZE instead of sizeof/sizeof[0]
  audit: reduce scope of audit_log_fcaps
  audit: reduce scope of audit_net_id
  audit: arm64: Remove the audit arch argument to audit_syscall_entry
  arm64: audit: Add audit hook in syscall_trace_enter/exit()
  audit: x86: drop arch from __audit_syscall_entry() interface
  sparc: implement is_32bit_task
  sparc: properly conditionalize use of TIF_32BIT
  ...
2014-10-19 16:25:56 -07:00
Olof Johansson 57764512ce Merge tag 'qcom-dt-for-3.18-3' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/linux-qcom into fixes
Merge "qcom DT changes for v3.18-3" from Kumar Gala:

Qualcomm ARM Based Device Tree Updates for v3.18-3

* Added Board support for CM-QS600 and Sony Xperia Z1 phone
* Added SATA support on IPQ8064/AP148

* tag 'qcom-dt-for-3.18-3' of git://git.kernel.org/pub/scm/linux/kernel/git/galak/linux-qcom:
  ARM: dts: qcom: add CM-QS600 board
  ARM: dts: qcom: Add initial DTS file for Sony Xperia Z1 phone
  ARM: dts: qcom: Add SATA support on IPQ8064/AP148
2014-10-19 13:39:08 -07:00
Olof Johansson e29c64865f 2nd Samsung fixes for v3.18
- Explicitly set dr_mode on exynos5800-peach-pi, exynos5420-peach-pit
   and exynos5420-arndale-octa boards, because the USB dwc3 controller
   will not work properly without dr_mode as host on above boards if
   the USB host and gadget are enabled in kernel configuration both.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.11 (GNU/Linux)
 
 iQIcBAABAgAGBQJUQFJ6AAoJEA0Cl+kVi2xqW/wP/2sWvJRYaPgDvFk2NsTn12Tl
 zdhbVRhnq/nskQ0Hg/YZ5QZMWbYo+gHUXuRrvGS6qRHLiQKdpLS1HvVZny+tG+j/
 iJZiPNrjFPAjHe0os2agiiD+Y6HWcEwWC/VZIWXreHSlY8+4em6xmcyMpu9Mpzhp
 GswN5eAU2suLZiliwBlCrcwuDsaYMmlM7fSdtVE7L9KWB27IGCwILHcPQR5wVfsO
 0n3osqsZZvYv3b/VYkBeiOcAaGjAF1H0y12/hZ/kVHV35vAiNzUjxvWLHNZSuSXb
 EMYnDuJfa2PnaEd8m9KfgDifvcaovhZeHreqtkGrumJAVJMVxa8R4/xWaKUnLOaB
 Cn7HlZP/MFhLPoFREVV/70jbjikdhEueD5J7W3C1c8wUpnwmOORCt/raXnK+ABuq
 h52wkl32Hc1QqO+RprHHCJNYHpGlysjMyiXRvy8qGQHhdWtk/1ttbhLPZMBoEN5h
 auCi55EN/W5gGnfD+mWmN6aAjreyesWflhShrcqFWn748MSDa/w4Qh17/w3HtLbd
 ED0GHJHf/hA6c0ixnLsMrgBj1rXpOdweZEN0HLWdAGDVC3RBdH74kDtyy3yJiAfI
 QdMw14dZc9Adk4gxs34xSvmFxJHlHjXTmhzO/2inhNMwENbkD+UOzQ36x4Skpc37
 hE9imV/9FjCr8UA0aBi6
 =Arc+
 -----END PGP SIGNATURE-----

Merge tag 'samsung-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung into fixes

Pull more fixes from Kukjin Kim:

2nd Samsung fixes for v3.18
- Explicitly set dr_mode on exynos5800-peach-pi, exynos5420-peach-pit
  and exynos5420-arndale-octa boards, because the USB dwc3 controller
  will not work properly without dr_mode as host on above boards if
  the USB host and gadget are enabled in kernel configuration both.

* tag 'samsung-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung:
  ARM: dts: Explicitly set dr_mode on exynos5420-arndale-octa
  ARM: dts: Explicitly set dr_mode on exynos Peach boards

Signed-off-by: Olof Johansson <olof@lixom.net>
2014-10-19 13:34:52 -07:00
Scott Branden 9209bec4f8 MAINTAINERS: corrected bcm2835 search
Corrected bcm2835 maintainer info by using N: to specify any files with
bcm2835 in are directed to the proper maintainer.
Also corrected minor mispelling of ARCHITECTURE in 2 comment locations.

Signed-off-by: Scott Branden <sbranden@broadcom.com>
Signed-off-by: Stephen Warren <swarren@wwwdotorg.org>
Signed-off-by: Olof Johansson <olof@lixom.net>
2014-10-19 13:34:00 -07:00
Linus Torvalds 61ed53deb1 Add support for Haswell NTB split BARs, a debugfs entry for basic
debugging info, and some code clean-ups.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABAgAGBQJUQQXsAAoJEG5mS6x6i9IjtlcP/1kB9TzJ0XGGEhIMv98X989X
 jzOuDHandfhfB6f0ch+1HUOji34Ig+hX2GmKRnUMOJJvXTdwEl9qpbEo3tUNl6S+
 pMf0oNzuMJGfrWsHbDa7MkCdnm6aLQrK/NxwHWY42g5yB2gc6vgcr6vD4bFEODBC
 fPgQIuogbLlVexFJFuVH6XbxNUhEXWiKf4vdq2m3tlgatLpe5NdVPQrq3qu8PLRa
 sbyNHWgCAVussI2LJI2t4dJwIUMnGFGTWBVNpxQo6ceWxziRFGg9Yo5068NnWU6j
 nDGL/TiQTM+Zp51U39Sd6eg5apnQMgrHTXumghSRDLnFe+odiVsRXX5IEqEAqXJS
 g6Et+sh7/CPO/nWM2dpIH5sxKuV4HAV7cSGsGjQD0pw6gKW8CT0rQI4gWufkorKH
 oR2etKjywN9j9+ofUN4w4FfKPlxeTgKp+zVbtTlUMOveJ4NIYBDDMvUS9KS9ZyMt
 s2X5/EJ864higC0VhTU/DxfqGc/g3+nz/EtWynxn9q2VPWlz/Zp0lLWvx4J4qGjP
 g4Pbv6EzWZqR1pia9L5alwR9nEYtn+bkwFKvvygp0tA+bor0G75qoRVy75KhUIPn
 1oQllKGiFhSLlNq9q6OMnlLv/BMXgvSnm7NL291/TY2RWfiWatlwGaMvnmkLWKKm
 wskyofD4yYOs4UJXgUJ8
 =JVjj
 -----END PGP SIGNATURE-----

Merge tag 'ntb-3.18' of git://github.com/jonmason/ntb

Pull ntb (non-transparent bridge) updates from Jon Mason:
 "Add support for Haswell NTB split BARs, a debugfs entry for basic
  debugging info, and some code clean-ups"

* tag 'ntb-3.18' of git://github.com/jonmason/ntb:
  ntb: Adding split BAR support for Haswell platforms
  ntb: use errata flag set via DID to implement workaround
  ntb: conslidate reading of PPD to move platform detection earlier
  ntb: move platform detection to separate function
  NTB: debugfs device entry
2014-10-19 12:58:22 -07:00
Linus Torvalds 278f1d0730 Merge branch 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux
Pull i2c updates from Wolfram Sang:
 "Highlights from the I2C subsystem for 3.18:

   - new drivers for Axxia AM55xx, and Hisilicon hix5hd2 SoC.

   - designware driver gained AMD support, exynos gained exynos7 support

  The rest is usual driver stuff.  Hopefully no lowlights this time"

* 'i2c/for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
  i2c: i801: Add Device IDs for Intel Sunrise Point PCH
  i2c: hix5hd2: add i2c controller driver
  i2c-imx: Disable the clock on probe failure
  i2c: designware: Add support for AMD I2C controller
  i2c: designware: Rework probe() to get clock a bit later
  i2c: designware: Default to fast mode in case of ACPI
  i2c: axxia: Add I2C driver for AXM55xx
  i2c: exynos: add support for HSI2C module on Exynos7
  i2c: mxs: detect No Slave Ack on SELECT in PIO mode
  i2c: cros_ec: Remove EC_I2C_FLAG_10BIT
  i2c: cros-ec-tunnel: Add of match table
  i2c: rcar: remove sign-compare flaw
  i2c: ismt: Use minimum descriptor size
  i2c: imx: Add arbitration lost check
  i2c: rk3x: Remove unlikely() annotations
  i2c: rcar: check for no IRQ in rcar_i2c_irq()
  i2c: rcar: make rcar_i2c_prepare_msg() *void*
  i2c: rcar: simplify check for last message
  i2c: designware: add support of platform data to set I2C mode
  i2c: designware: add support of I2C standard mode
2014-10-19 12:50:44 -07:00
Linus Torvalds d590c6cdd9 sound fixes for 3.18-rc1
Here are a collection of small fixes after 3.18 merge.  The urgent
 one is the fix for kernel panics with linked PCM substream triggered
 by the recent nonatomic PCM ops support.  Other two fixes (emu10k1 and
 bebob) are stable fixes, and one easy PCI ID addition for a new Intel
 HD-audio controller.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iQIcBAABAgAGBQJUQDOmAAoJEGwxgFQ9KSmkkKQP/R4WO6FaoIKqQOuSDrFlrqo5
 sxjQrsqLL1jYvZpJjwgfthEsL7n+6ERqXAGul6V90iXWAm1yKfVoyJY30O2p5vVb
 9klS9geh/fZ0183FbnkLuUe3/CtEiZv3UBpR/YVCEx2fYQ5CKRZ2d2tug21vDTa9
 ce2OQrxsRoWRIsi1jvpu1NgxJ0FUqj/iXNMu8aGttFyZQkg3vJ9HggMkIgT4+25p
 mCq3YMcCjZN/lSwg6/uYt1IW/zdfQ3MRA+pppGj9+hIynBrvaiFlhda1HmBLj5cy
 fIIntVBO5aBOUL6ze2D2vdRWOFUr61gjvV3U91gvJn1TEYa3Nj3Lig/E0pCE6iba
 4YdZK5v4Wbug9Zk4iyPmFV+Zii6YxLmnrF+AA09pBgNtdzmcrZci6AFNjbXP4seB
 RCXg0Ymu68pbjLkqJqLvw8Ts6CIPN7LjcEbYCgB/kSFfQmkWP4Ab1KWfKsNw3pok
 PR51l4N/ZhvFbXlLAf5ke11DgEt4LALP3cD0QpbnBneXqwUIS9OQ5+nckh5VKYnF
 41UHgVIZfxnq8Gqv3AuvZf+ocYXjINDH7glBVm3uLZwEK8bnVNpaLzpd07IePOiR
 qCVNWGzvOwHgd+vAVvJ35r0O76fyiKOtATPDZZz66QXxvkd5GPVZNJseD3lIkzyg
 jAWBp53zesgQCLv1Naj7
 =jf99
 -----END PGP SIGNATURE-----

Merge tag 'sound-fix-3.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
 "Here are a collection of small fixes after 3.18 merge.

  The urgent one is the fix for kernel panics with linked PCM substream
  triggered by the recent nonatomic PCM ops support.  Other two fixes
  (emu10k1 and bebob) are stable fixes, and one easy PCI ID addition for
  a new Intel HD-audio controller"

* tag 'sound-fix-3.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
  ALSA: hda_intel: Add Device IDs for Intel Sunrise Point PCH
  ALSA: emu10k1: Fix deadlock in synth voice lookup
  ALSA: pcm: Fix referred substream in snd_pcm_action_group() unlock loop
  ALSA: bebob: Fix failure to detect source of clock for Terratec Phase 88
2014-10-19 12:45:36 -07:00
Linus Torvalds fb378df57d Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Pull second round of input updates from Dmitry Torokhov:
 "Mostly simple bug fixes, although we do have one brand new driver for
  Microchip AR1021 i2c touchscreen.

  Also there is the change to stop trying to use i8042 active
  multiplexing by default (it is still possible to activate it via
  i8042.nomux=0 on boxes that implement it)"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: xpad - add Thrustmaster as Xbox 360 controller vendor
  Input: xpad - add USB ID for Thrustmaster Ferrari 458 Racing Wheel
  Input: max77693-haptic - fix state check in imax77693_haptic_disable()
  Input: xen-kbdfront - free grant table entry in xenkbd_disconnect_backend
  Input: alps - fix v4 button press recognition
  Input: i8042 - disable active multiplexing by default
  Input: i8042 - add noloop quirk for Asus X750LN
  Input: synaptics - gate forcepad support by DMI check
  Input: Add Microchip AR1021 i2c touchscreen
  Input: cros_ec_keyb - add of match table
  Input: serio - avoid negative serio device numbers
  Input: avoid negative input device numbers
  Input: automatically set EV_ABS bit in input_set_abs_params
  Input: adp5588-keys - cancel workqueue in failure path
  Input: opencores-kbd - switch to using managed resources
  Input: evdev - fix EVIOCG{type} ioctl
2014-10-19 12:40:24 -07:00