aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2015-06-22mfd: arizona: Add stub for wm5102_patch()Richard Fitzgerald1-0/+8
For the WM5102 there is a dependency in the core code on wm5102_patch() which only exists when CONFIG_MFD_WM5102 is defined. To avoid having to sprinkle #ifdefs around the code it is given an alternative empty stub version when CONFIG_MFD_WM5102 is deselected Signed-off-by: Richard Fitzgerald <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: Check ACPI device companion before checking resourcesLorenzo Pieralisi1-3/+5
Current code in mfd-core calls into ACPI to check resources even on a system that booted with a DT (on kernels with both DT and ACPI support compiled in). This triggers ACPI exceptions since we may end up calling the ACPI interpreter when it has not been initialized: "ACPI Exception: AE_BAD_PARAMETER, Thread 2064154624 could not acquire Mutex [0x1] (20150410/utmutex-285)" This patch fixes the issues by adding a check for an ACPI companion device before carrying out ACPI resources checks to avoid calling the ACPI interpreter if the fwnode representing the device is an OF one. Cc: Sudeep Holla <[email protected]> Signed-off-by: Lorenzo Pieralisi <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22Documentation: Add WM8998/WM1814 device tree bindingsRichard Fitzgerald1-4/+9
Signed-off-by: Richard Fitzgerald <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Split INx_MODE into two fieldsRichard Fitzgerald3-12/+28
Later arizona silicon has the single/differential selector in a different register, and IN1_MODE only selects between analogue or digital. Prepare for this by splitting the INx_MODE definition into two fields. Signed-off-by: Richard Fitzgerald <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: wm5110: Add delay before releasing reset lineCharles Keepax1-0/+10
On the wm5110 it is important the reset line is held for slightly longer to ensure the device starts up well. This patch adds a 5mS delay for this. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Add better support for system suspendCharles Keepax2-16/+78
Allow the chip to completely power off if we enter runtime suspend and there is no jack detection active. This is helpful for systems where system suspend might remove the supplies to the CODEC, without informing us. Note the powering off is done in runtime suspend rather than system suspend, because we need to hold reset until the first time DCVDD is powered anyway (which would be in runtime resume), and we might as well save the extra power. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: wm5110: Set DCVDD voltage to 1.175V before entering sleep modeCharles Keepax1-0/+52
The low power sleep mode on wm5110 requires that the LDO1 regulator be set to 1.175V prior to entering sleep, then returned to 1.2V after exiting sleep mode. This patch apply these regulator settings. Signed-off-by: Charles Keepax <[email protected]> Acked-by: Mark Brown <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: wm5110: Add register patch required for low power sleepCharles Keepax1-0/+39
Some register settings must be applied before the first time low power sleep mode is entered on the wm5110 to ensure optimium performance. These settings require SYSCLK to be enabled whilst they are being applied. This patch applies the settings using the recently factored out boot time SYSCLK functionality. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Factor out SYSCLK enable from wm5102 hardware patchCharles Keepax1-20/+57
wm5102 applies a custom hardware boot sequence, for this the SYSCLK needs to be enabled. This patch factors out the code that enables SYSCLK for this sequence such that it can be used for other boot time operations that require SYSCLK. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Fix formating/style issues in arizona_apply_hardware_patchCharles Keepax1-20/+17
In preparation for some refactoring fixup some minor style, formating and code clarity issues. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: wm5102: Ensure we always boot the device fullyCharles Keepax1-10/+40
The wm5102 uses a custom boot sequence and the standard boot sequence is disabled. However, the standard boot sequence must be run at least once after a cold boot (caused by either a hard reset or removal of AVDD). Unfortunately the register WRITE_SEQUENCER_CTRL_3 is not affected by the hardware reset. This means if the device has been previously booted but the AVDD supply has never been removed, arizona_dev_init will reset the chip but the boot sequence will not run, which can cause numerous problems. The solution is to manually clear this register and then boot the chip again, which is what this patch does. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Factor out hard reset into helper functionsCharles Keepax1-8/+17
This patch adds functions for enabling and disabling the physical reset line. This will be helpful in future refactoring. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Use devres to manage reset GPIOCharles Keepax1-6/+4
This also handily fixes a leak of the GPIO in arizona_dev_exit. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22MAINTAINERS: Add Arnd Bergmann as Syscon reviewerLee Jones1-0/+7
The System Configuration (syscon) driver is an important one, which effects many ARM-SoC based platforms. I'm adding Arnd as a primary reviewer as he is highly competent in this area and has a keen interest in ARM-SoC. Acked-by: Arnd Bergmann <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22MAINTAINERS: Extend Samsung MFD drivers entry and add Krzysztof KozlowskiKrzysztof Kozlowski1-1/+7
Extend the entry for Samsung MFD drivers for PMIC devices (Power Management Integrated Circuit) with bindings documentation, clock (clk-s2mps11.c) and RTC drivers (rtc-s5m.c). These PMIC devices are used on many Exynos-based boards like Arndale Octa (S2MPS11), Gear 2 (S2MPS14). Add Krzysztof Kozlowski as a supporter for reviewing them. I am not the author of these drivers. However I have recently contributed to most of them and I have access to datasheets and hardware. Cc: Sangbeom Kim <[email protected]> CC: Mike Turquette <[email protected]> CC: Stephen Boyd <[email protected]> CC: Alessandro Zummo <[email protected]> CC: Alexandre Belloni <[email protected]> CC: Liam Girdwood <[email protected]> CC: Mark Brown <[email protected]> Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: Allow compile test of GPIO consumers if !GPIOLIBGeert Uytterhoeven1-2/+4
The GPIO subsystem provides dummy GPIO consumer functions if GPIOLIB is not enabled. Hence drivers that depend on GPIOLIB, but use GPIO consumer functionality only, can still be compiled if GPIOLIB is not enabled. Relax the dependency on GPIOLIB if COMPILE_TEST is enabled, where appropriate. Signed-off-by: Geert Uytterhoeven <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: max77686: Remove unused struct max77686_opmode_dataJavier Martinez Canillas1-5/+0
The defined struct max77686_opmode_data isn't used neither by the max77686 mfd driver nor the drivers for its sub-devices. Signed-off-by: Javier Martinez Canillas <[email protected]> Reviewed-by: Chanwoo Choi <[email protected]> Reviewed-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: twl4030-power: Fix pmic for boards that need AC charger disabledTony Lindgren2-7/+39
I noticed the PMIC configuration on 37xx-evm won't actually shut down the voltages during off-idle. Turns out 37xx-evm needs the AC charger state transitions disabled like we are doing for SDP and LDP in the legacy booting case. Let's fix this for device tree based booting by setting up the quirk flag based on the compatible flag. And let's also use the existing define for STARTON_CHG. Note that SDP and EVM do not have the PMIC clken wired to gate the the oscillator while LDP has. Signed-off-by: Tony Lindgren <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: documentation: dt: max77686: Fix typoFabio Estevam1-1/+1
Fix typo in 'Multifunction'. Signed-off-by: Fabio Estevam <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: arizona: Remove redundant register syncCharles Keepax1-8/+0
This soft reset used to be located after the register patch had been applied, but has since moved to before the patch is applied. At the new location there is no requirement to do a register sync as no register writes will have happened yet. Signed-off-by: Charles Keepax <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: documentation: dt: Add documentation for the mfd Maxim max77693Jacek Anaszewski1-0/+67
This patch adds device tree binding documentation for the flash cell of the Maxim max77693 multifunctional device. Signed-off-by: Jacek Anaszewski <[email protected]> Signed-off-by: Andrzej Hajda <[email protected]> Acked-by: Kyungmin Park <[email protected]> Acked-by: Sakari Ailus <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22mfd: Constify regmap and irq configuration dataKrzysztof Kozlowski22-29/+29
Constify in various drivers configuration data which is not modified: - regmap_irq_chip, - individual regmap_irq's in array, - regmap_config, - irq_domain_ops, Signed-off-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Lee Jones <[email protected]>
2015-06-22Merge branches 'ib-mfd-watchdog-rtc-4.2', 'ib-mfd-regulator-4.2' and ↵Lee Jones249-2161/+4885
'ib-mfd-i2c-input-chrome-4.2' into ibs-for-mfd-merged
2015-06-22mfd: cros_ec: Staticise some newly introduced structuresLee Jones1-4/+4
Signed-off-by: Lee Jones <[email protected]>
2015-06-22Merge remote-tracking branches 'regulator/topic/of', 'regulator/topic/pwm', ↵Mark Brown8-25/+1588
'regulator/topic/qcom' and 'regulator/topic/soft-start' into regulator-next
2015-06-22Merge remote-tracking branches 'regulator/topic/lp8755', ↵Mark Brown7-209/+320
'regulator/topic/max14577', 'regulator/topic/max77693', 'regulator/topic/max77843' and 'regulator/topic/max8973' into regulator-next
2015-06-22Merge remote-tracking branches 'regulator/topic/da9063', ↵Mark Brown8-20/+68
'regulator/topic/doc', 'regulator/topic/fan53555', 'regulator/topic/gpio' and 'regulator/topic/ilim' into regulator-next
2015-06-22Merge remote-tracking branches 'regulator/topic/88pm8607', ↵Mark Brown7-7/+875
'regulator/topic/arizona', 'regulator/topic/cleanup' and 'regulator/topic/da9062' into regulator-next
2015-06-22Merge remote-tracking branch 'regulator/topic/core' into regulator-nextMark Brown1-21/+26
2015-06-22Merge remote-tracking branches 'regulator/fix/doc', 'regulator/fix/max77686' ↵Mark Brown5-12/+19
and 'regulator/fix/wm831x' into regulator-linus
2015-06-22Merge remote-tracking branch 'regulator/fix/core' into regulator-linusMark Brown1-2/+2
2015-06-22crypto: marvell/cesa - remove COMPILE_TEST dependencyBoris Brezillon1-1/+1
The CESA driver calls phys_to_virt() which is not available on all architectures. Remove the depency on COMPILE_TEST to prevent building this driver on non ARM architectures. Signed-off-by: Boris Brezillon <[email protected]> Reported-by: Paul Gortmaker <[email protected]> Suggested-by: Herbert Xu <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: algif_aead - Temporarily disable all AEAD algorithmsHerbert Xu2-1/+8
As the AEAD conversion is still ongoing, we do not yet wish to export legacy AEAD implementations to user-space, as their calling convention will change. This patch actually disables all AEAD algorithms because some of them (e.g., cryptd) will need to be modified to propagate this flag. Subsequent patches will reenable them on an individual basis. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: af_alg - Forbid the use internal algorithmsHerbert Xu1-1/+4
The bit CRYPTO_ALG_INTERNAL was added to stop af_alg from accessing internal algorithms. However, af_alg itself was never modified to actually stop that bit from being used by the user. Therefore the user could always override it by specifying the relevant bit in the type and/or mask. This patch silently discards the bit in both type and mask. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: echainiv - Only hold RNG during initialisationHerbert Xu1-22/+6
This patch changes the RNG allocation so that we only hold a reference to the RNG during initialisation. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: seqiv - Add compatibility support without RNGHerbert Xu1-25/+25
When seqiv is used in compatibility mode, this patch allows it to function even when an RNG Is not available. It also changes the RNG allocation for the new explicit seqiv interface so that we only hold a reference to the RNG during initialisation. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: eseqiv - Offer normal cipher functionality without RNGHerbert Xu1-19/+12
The RNG may not be available during early boot, e.g., the relevant modules may not be included in the initramfs. As the RNG Is only needed for IPsec, we should not let this prevent use of ciphers without IV generators, e.g., for disk encryption. This patch postpones the RNG allocation to the init function so that one failure during early boot does not make the RNG unavailable for all subsequent users of the same cipher. More importantly, it lets the cipher live even if RNG allocation fails. Of course we no longer offer IV generation and which will fail with an error if invoked. But all other cipher capabilities will function as usual. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: chainiv - Offer normal cipher functionality without RNGHerbert Xu1-26/+29
The RNG may not be available during early boot, e.g., the relevant modules may not be included in the initramfs. As the RNG Is only needed for IPsec, we should not let this prevent use of ciphers without IV generators, e.g., for disk encryption. This patch postpones the RNG allocation to the init function so that one failure during early boot does not make the RNG unavailable for all subsequent users of the same cipher. More importantly, it lets the cipher live even if RNG allocation fails. Of course we no longer offer IV generation and which will fail with an error if invoked. But all other cipher capabilities will function as usual. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: user - Add CRYPTO_MSG_DELRNGHerbert Xu2-1/+12
This patch adds a new crypto_user command that allows the admin to delete the crypto system RNG. Note that this can only be done if the RNG is currently not in use. The next time it is used a new system RNG will be allocated. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: user - Move cryptouser.h to uapiHerbert Xu1-0/+0
The header file cryptouser.h only contains information that is exported to user-space. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: rng - Do not free default RNG when it becomes unusedHerbert Xu2-4/+32
Currently we free the default RNG when its use count hits zero. This was OK when the IV generators would latch onto the RNG at instance creation time and keep it until the instance is torn down. Now that IV generators only keep the RNG reference during init time this scheme causes the default RNG to come and go at a high frequencey. This is highly undesirable as we want to keep a single RNG in use unless the admin wants it to be removed. This patch changes the scheme so that the system RNG once allocated is never removed unless a specifically requested. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22crypto: skcipher - Allow givencrypt to be NULLHerbert Xu1-1/+1
Currently for skcipher IV generators they must provide givencrypt as that is the whole point. We are currently replacing skcipher IV generators with explicit IV generators. In order to maintain backwards compatibility, we need to allow the IV generators to still function as a normal skcipher when the RNG Is not present (e.g., in the initramfs during boot). IOW everything but givencrypt and givdecrypt will still work but those two will fail. Therefore this patch assigns a default givencrypt that simply returns an error should it be NULL. Signed-off-by: Herbert Xu <[email protected]>
2015-06-22Merge branches 'x86/apic', 'x86/asm', 'x86/mm' and 'x86/platform' into ↵Ingo Molnar643-5867/+9094
x86/core, to merge last updates Signed-off-by: Ingo Molnar <[email protected]>
2015-06-21hwmon: add driver for Microchip TC74Maciej S. Szmigiero4-0/+208
Add hwmon driver for the Microchip TC74. The TC74 is a single-input 8-bit I2C temperature sensor, with +-2 degrees centigrade accuracy. Signed-off-by: Maciej Szmigiero <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2015-06-21Linux 4.1Linus Torvalds1-1/+1
2015-06-21clocksource: Increase dependencies of timer-stm32 to limit build wreckagePaul Gortmaker1-2/+2
This driver leaks out into arch/parisc builds that don't have CONFIG_GENERIC_CLOCKEVENTS, leading to the following (truncated) wreckage: CC drivers/clocksource/timer-stm32.o drivers/clocksource/timer-stm32.c:38:28: error: field 'evtdev' has incomplete type drivers/clocksource/timer-stm32.c:44:19: warning: 'enum clock_event_mode' declared inside parameter list drivers/clocksource/timer-stm32.c:44:19: warning: its scope is only this definition or declaration, which is probably not what you want drivers/clocksource/timer-stm32.c:43:62: error: parameter 1 ('mode') has incomplete type drivers/clocksource/timer-stm32.c:43:13: error: function declaration isn't a prototype drivers/clocksource/timer-stm32.c: In function 'stm32_clock_event_set_mode': drivers/clocksource/timer-stm32.c:47:3: error: type defaults to 'int' in declaration of '__mptr' drivers/clocksource/timer-stm32.c:47:3: warning: initialization from incompatible pointer type drivers/clocksource/timer-stm32.c:51:7: error: 'CLOCK_EVT_MODE_PERIODIC' undeclared (first use in this function) drivers/clocksource/timer-stm32.c:51:7: note: each undeclared identifier is reported only once for each function it appears in drivers/clocksource/timer-stm32.c:56:7: error: 'CLOCK_EVT_MODE_ONESHOT' undeclared (first use in this function) Tighten up the dependencies to limit where it gets built by copying the style of the Kconfig line for CLKSRC_EFM32 a few lines above. Signed-off-by: Paul Gortmaker <[email protected]> Cc: Linus Walleij <[email protected]> Cc: Chanwoo Choi <[email protected]> Cc: Maxime Coquelin <[email protected]> Cc: Daniel Lezcano <[email protected]> Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Thomas Gleixner <[email protected]>
2015-06-21x86/hpet: Use proper hpet device number for MSI allocationThomas Gleixner1-5/+6
hpet_assign_irq() is called with hpet_device->num as "hardware interrupt number", but hpet_device->num is initialized after the interrupt has been assigned, so it's always 0. As a consequence only the first MSI allocation succeeds, the following ones fail because the "hardware interrupt number" already exists. Move the initialization of dev->num and other fields before the call to hpet_assign_irq(), which is the ordering before the offending commit which introduced that regression. Fixes: "3cb96f0c9733 x86/hpet: Enhance HPET IRQ to support hierarchical irqdomains" Reported-by: Sergey Senozhatsky <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Link: http://lkml.kernel.org/r/alpine.DEB.2.11.1506211635010.4107@nanos Cc: Jiang Liu <[email protected]> Cc: Borislav Petkov <[email protected]>
2015-06-21crypto: sahara - propagate the error on clk_disable_unprepare() failureFabio Estevam1-4/+9
clk_prepare_enable() may fail, so we should better check its return value and propagate it in the case of error. Signed-off-by: Fabio Estevam <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
2015-06-21crypto: rsa - fix invalid select for AKCIPHERTadeusz Struk1-1/+1
Should be CRYPTO_AKCIPHER instead of AKCIPHER Reported-by: Andreas Ruprecht <[email protected]> Signed-off-by: Tadeusz Struk <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
2015-06-21crypto: picoxcell - Update to the current clk APIMichael van der Westhuizen1-4/+4
The picoXcell hardware crypto accelerator driver was using an older version of the clk framework, and not (un)preparing the clock before enabling/disabling it. This change uses the handy clk_prepare_enable function to interact with the current clk framework correctly. Signed-off-by: Michael van der Westhuizen <[email protected]> Signed-off-by: Herbert Xu <[email protected]>