- 27 Aug, 2019 2 commits
-
-
Lee Jones authored
Avoids: ../drivers/mfd/rk808.c:771:1: warning: symbol 'rk8xx_pm_ops' \ was not declared. Should it be static? Fixes: 5752bc43 ("mfd: rk808: Mark pm functions __maybe_unused") Reviewed-by:
Arnd Bergmann <arnd@arndb.de> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Arnd Bergmann authored
The newly added suspend/resume functions are only used if CONFIG_PM is enabled: drivers/mfd/rk808.c:752:12: error: 'rk8xx_resume' defined but not used [-Werror=unused-function] drivers/mfd/rk808.c:732:12: error: 'rk8xx_suspend' defined but not used [-Werror=unused-function] Mark them as __maybe_unused so the compiler can silently drop them when they are not needed. Fixes: 586c1b41 ("mfd: rk808: Add RK817 and RK809 support") Signed-off-by:
Arnd Bergmann <arnd@arndb.de> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
- 10 Aug, 2019 2 commits
-
-
Gustavo A. R. Silva authored
Mark switch cases where we are expecting to fall through. This patch fixes the following warnings: drivers/mfd/omap-usb-host.c: In function 'usbhs_runtime_resume': drivers/mfd/omap-usb-host.c:303:7: warning: this statement may fall through [-Wimplicit-fallthrough=] if (!IS_ERR(omap->hsic480m_clk[i])) { ^ drivers/mfd/omap-usb-host.c:313:3: note: here case OMAP_EHCI_PORT_MODE_TLL: ^~~~ drivers/mfd/omap-usb-host.c: In function 'usbhs_runtime_suspend': drivers/mfd/omap-usb-host.c:345:7: warning: this statement may fall through [-Wimplicit-fallthrough=] if (!IS_ERR(omap->hsic480m_clk[i])) ^ drivers/mfd/omap-usb-host.c:349:3: note: here case OMAP_EHCI_PORT_MODE_TLL: ^~~~ Reported-by:
Stephen Rothwell <sfr@canb.auug.org.au> Reviewed-by:
Kees Cook <keescook@chromium.org> Signed-off-by:
Gustavo A. R. Silva <gustavo@embeddedor.com>
-
Gustavo A. R. Silva authored
Mark switch cases where we are expecting to fall through. This patch fixes the following warnings: drivers/mfd/db8500-prcmu.c: In function 'dsiclk_rate': drivers/mfd/db8500-prcmu.c:1592:7: warning: this statement may fall through [-Wimplicit-fallthrough=] div *= 2; ~~~~^~~~ drivers/mfd/db8500-prcmu.c:1593:2: note: here case PRCM_DSI_PLLOUT_SEL_PHI_2: ^~~~ drivers/mfd/db8500-prcmu.c:1594:7: warning: this statement may fall through [-Wimplicit-fallthrough=] div *= 2; ~~~~^~~~ drivers/mfd/db8500-prcmu.c:1595:2: note: here case PRCM_DSI_PLLOUT_SEL_PHI: ^~~~ Reported-by:
Stephen Rothwell <sfr@canb.auug.org.au> Reviewed-by:
Kees Cook <keescook@chromium.org> Reviewed-by:
Linus Walleij <linus.walleij@linaro.org> Signed-off-by:
Gustavo A. R. Silva <gustavo@embeddedor.com>
-
- 02 Jul, 2019 22 commits
-
-
Axel Lin authored
Since devm_regmap_init_mmio_clk can fail, add return value checking. Signed-off-by:
Axel Lin <axel.lin@ingics.com> Acked-by:
Chen Feng <puck.chen@hisilicon.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Charles Keepax authored
GPL-2.0-only is the preferred way of expressing v2 of the GPL, so switch to that. Remove some redundant copyright notices and correct some instances where the wrong comment type has been used in header files. Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Charles Keepax authored
Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Andy Shevchenko authored
ida instances allocate some internal memory for ->free_bitmap in addition to the base 'struct ida'. Use ida_destroy() to release that memory at module_exit(). Fixes: 4b45efe8 ("mfd: Add support for Intel Sunrisepoint LPSS devices") Signed-off-by:
Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Andy Shevchenko authored
Intel Elkhart Lake has the same LPSS than Intel Broxton. Add the new IDs to the list of supported devices. Signed-off-by:
Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Lubomir Rintel authored
<asm/olpc.h> provides machine_is_olpc() stub for CONFIG_OLPC=n, compiler should just optimize the unneeded bits away. Signed-off-by:
Lubomir Rintel <lkundrak@v3.sk> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Gwendal Grignou authored
With this patch, the cros_ec_ctl driver will register the legacy accelerometer driver (named cros_ec_accel_legacy) if it fails to register sensors through the usual path cros_ec_sensors_register(). This legacy device is present on Chromebook devices with older EC firmware only supporting deprecated EC commands: - Glimmer based devices [Intel SOC using LPC transport] - Veyron minnie devices [ARM SOC using SPI transport] Tested-by:
Gwendal Grignou <gwendal@chromium.org> Signed-off-by:
Enric Balletbo i Serra <enric.balletbo@collabora.com> Reviewed-by:
Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by:
Gwendal Grignou <gwendal@chromium.org> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Stefan Mavrodiev authored
RK805 has SLEEP signal, which can put the device into SLEEP or OFF mode. The default is SLEEP mode. However, when the kernel performs power-off (actually the ATF) the device will not go fully off and this will result in higher power consumption and inability to wake the device with RTC alarm. The solution is to enable pm_power_off_prepare function, which will configure SLEEP pin for OFF function. Signed-off-by:
Stefan Mavrodiev <stefan@olimex.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Stefan Mavrodiev authored
The function pointer pm_power_off may point to function from other module (PSCI for example). If rk808 is removed, pm_power_off is overwritten to NULL and the system cannot be powered off. This patch checks if pm_power_off points to a module function. Signed-off-by:
Stefan Mavrodiev <stefan@olimex.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Pi-Hsun Shih authored
System Companion Processor (SCP) is Cortex M4 co-processor on some MediaTek platform that can run EC-style firmware. Since a SCP and EC would both exist on a system, and use the cros_ec_dev driver, we need to differentiate between them for the userspace, or they would both be registered at /dev/cros_ec, causing a conflict. Signed-off-by:
Pi-Hsun Shih <pihsun@chromium.org> Acked-by:
Enric Balletbo i Serra <enric.balletbo@collabora.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Richard Fitzgerald authored
This patch adds all the core support and defines for the Cirrus Logic CS42L92, CS47L92 and CS47L93 smart audio CODECs. Registers or fields are named MADERA_* if it is part of the common hardware platform and does not conflict with any other Madera codecs. It is named CS47L15_* if it is unique to CS47L15 and conflicts with definitions on other codecs. Signed-off-by:
Stuart Henderson <stuarth@opensource.cirrus.com> Signed-off-by:
Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Richard Fitzgerald authored
This patch adds all the core support and defines for the Cirrus Logic CS47L15 smart audio CODEC. Registers or fields are named MADERA_* if it is part of the common hardware platform and does not conflict with any other Madera codecs. It is named CS47L15_* if it is unique to CS47L15 and conflicts with definitions on other codecs. Signed-off-by:
Richard Fitzgerald <rf@opensource.cirrus.com> Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Charles Keepax authored
Currently we are relying on the exact match of the regulator name to find MICVDD, we should add an explicit supply mapping to allow this to be found more reliably. Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Stuart Henderson authored
regmap_read won't set val to anything if an ACKed bus fails. Signed-off-by:
Stuart Henderson <stuarth@opensource.cirrus.com> Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Arnd Bergmann authored
When the driver is used with a subdevice that is disabled in the kernel configuration, clang gets a little confused about the control flow and fails to notice that n_subdevs is only uninitialized when subdevs is NULL, and we check for that, leading to a false-positive warning: drivers/mfd/arizona-core.c:1423:19: error: variable 'n_subdevs' is uninitialized when used here [-Werror,-Wuninitialized] subdevs, n_subdevs, NULL, 0, NULL); ^~~~~~~~~ drivers/mfd/arizona-core.c:999:15: note: initialize the variable 'n_subdevs' to silence this warning int n_subdevs, ret, i; ^ = 0 Ideally, we would rearrange the code to avoid all those early initializations and have an explicit exit in each disabled case, but it's much easier to chicken out and add one more initialization here to shut up the warning. Signed-off-by:
Arnd Bergmann <arnd@arndb.de> Reviewed-by:
Nathan Chancellor <natechancellor@gmail.com> Signed-off-by:
Charles Keepax <ckeepax@opensource.cirrus.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Robert Hancock authored
The logic for setting the of_node on devices created by mfd did not set the fwnode pointer to match, which caused fwnode-based APIs to malfunction on these devices since the fwnode pointer was null. Fix this. Signed-off-by:
Robert Hancock <hancock@sedsystems.ca> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Andy Shevchenko authored
Easier to find and maintain if the device tables sorted by ID. Do it here for intel-lpss MFD driver. Signed-off-by:
Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Alexandre Belloni authored
The RTC core already has error messages in case of failure, there is no need to have another message in the driver. Signed-off-by:
Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Leonard Crestez authored
Allow overwriting the values in BD718XX_REG_PWRONCONFIG0 and BD718XX_REG_PWRONCONFIG1 via devicetree. Read values in milliseconds and attempt to round them to something supported by the hardware. Keep existing values (from bootloader or OTP) if property is not present. Signed-off-by:
Leonard Crestez <leonard.crestez@nxp.com> Reviewed-By:
Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> [Lee: Fixed-up merge/API conflict] Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Leonard Crestez authored
The reset button on imx8mm-evk is tied to PWRON_B pin of bd71847 and the long press duration is set to zero from OTP. The linux driver overrides those values and breaks reset from button. Overwriting OTP or bootloader configuration with some hardcoded defaults is not desirable, keep already programmed values instead. Signed-off-by:
Leonard Crestez <leonard.crestez@nxp.com> Acked-By:
Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Gwendal Grignou authored
Register driver when EC indicates has precise lid angle calculation code running. Fix incorrect extra resource allocation in cros_ec_sensors_register(). Signed-off-by:
Gwendal Grignou <gwendal@chromium.org> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Daniel Gomez authored
MODULE_DEVICE_TABLE(of, <of_match_table>) should be called to complete DT OF mathing mechanism and register it. Before this patch: modinfo ./drivers/mfd/madera.ko | grep alias After this patch: modinfo ./drivers/mfd/madera.ko | grep alias alias: of:N*T*Ccirrus,wm1840C* alias: of:N*T*Ccirrus,wm1840 alias: of:N*T*Ccirrus,cs47l91C* alias: of:N*T*Ccirrus,cs47l91 alias: of:N*T*Ccirrus,cs47l90C* alias: of:N*T*Ccirrus,cs47l90 alias: of:N*T*Ccirrus,cs47l85C* alias: of:N*T*Ccirrus,cs47l85 alias: of:N*T*Ccirrus,cs47l35C* alias: of:N*T*Ccirrus,cs47l35 Reported-by:
Javier Martinez Canillas <javier@dowhile0.org> Signed-off-by:
Daniel Gomez <dagmcr@gmail.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
- 01 Jul, 2019 1 commit
-
-
Evan Green authored
For ECs that support it, the EC returns the number of slp_s0 transitions and whether or not there was a timeout in the resume response. Expose the last resume result to usermode via debugfs so that usermode can detect and report S0ix timeouts. Signed-off-by:
Evan Green <evgreen@chromium.org> Acked-by:
Lee Jones <lee.jones@linaro.org> Signed-off-by:
Enric Balletbo i Serra <enric.balletbo@collabora.com>
-
- 27 Jun, 2019 3 commits
-
-
Tony Xie authored
The RK809 and RK817 are a Power Management IC (PMIC) for multimedia and handheld devices. They contains the following components: - Regulators - RTC - Clocking Both RK809 and RK817 chips are using a similar register map, so we can reuse the RTC and Clocking functionality. Most of regulators have a some implementation also. Signed-off-by:
Tony Xie <tony.xie@rock-chips.com> Acked-by:
Stephen Boyd <sboyd@kernel.org> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Matti Vaittinen authored
ROHM BD70528MWV is an ultra-low quiescent current general purpose single-chip power management IC for battery-powered portable devices. Add MFD core which enables chip access for following subdevices: - regulators/LED drivers - battery-charger - gpios - 32.768kHz clk - RTC - watchdog Signed-off-by:
Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Matti Vaittinen authored
Split the bd718x7.h to ROHM common and bd718x7 specific parts so that we do not need to add same things in every new ROHM PMIC header. Please note that this change requires changes also in bd718x7 sub-device drivers for regulators and clk. Signed-off-by:
Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> Acked-by:
Mark Brown <broonie@kernel.org> Acked-by:
Stephen Boyd <sboyd@kernel.org> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
- 24 Jun, 2019 3 commits
-
-
Dan Carpenter authored
It's not okay to cast a "u32 *" to "unsigned long *" when you are doing a for_each_set_bit() loop because that will break on big endian systems. Fixes: 386145601b82 ("mfd: stmfx: Uninitialized variable in stmfx_irq_handler()") Reported-by:
Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Tested-by:
Amelie Delaunay <amelie.delaunay@st.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Suzuki K Poulose authored
The driver_find_device() accepts a match function pointer to filter the devices for lookup, similar to bus/class_find_device(). However, there is a minor difference in the prototype for the match parameter for driver_find_device() with the now unified version accepted by {bus/class}_find_device(), where it doesn't accept a "const" qualifier for the data argument. This prevents us from reusing the generic match functions for driver_find_device(). For this reason, change the prototype of the driver_find_device() to make the "match" parameter in line with {bus/class}_find_device() and adjust its callers to use the const qualifier. Also, we could now promote the "data" parameter to const as we pass it down as a const parameter to the match functions. Cc: Corey Minyard <minyard@acm.org> Cc: Russell King <linux@armlinux.org.uk> Cc: Thierry Reding <thierry.reding@gmail.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: "Rafael J. Wysocki" <rafael@kernel.org> Cc: Will Deacon <will.deacon@arm.com> Cc: Joerg Roedel <joro@8bytes.org> Cc: Peter Oberparleiter <oberpar@linux.ibm.com> Cc: Sebastian Ott <sebott@linux.ibm.com> Cc: David Airlie <airlied@linux.ie> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: Nehal Shah <nehal-bakulchandra.shah@amd.com> Cc: Shyam Sundar S K <shyam-sundar.s-k@amd.com> Cc: Lee Jones <lee.jones@linaro.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by:
Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Suzuki K Poulose authored
Nobody uses the exported helper syscon_regmap_lookup_by_pdevname, to lookup a device by name. Let us remove it. Suggested-by:
Arnd Bergman <arnd@arnd.de> Cc: Arnd Bergman <arnd@arnd.de> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: "Rafael J. Wysocki" <rafael@kernel.org> Signed-off-by:
Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 19 Jun, 2019 3 commits
-
-
Thomas Gleixner authored
Based on 2 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation # extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 4122 file(s). Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Reviewed-by:
Enrico Weigelt <info@metux.net> Reviewed-by:
Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by:
Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.deSigned-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Thomas Gleixner authored
Based on 1 normalized pattern(s): license terms gnu general public license version 2 extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 11 file(s). Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Reviewed-by:
Allison Randal <allison@lohutok.net> Reviewed-by:
Enrico Weigelt <info@metux.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081202.373849232@linutronix.deSigned-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Thomas Gleixner authored
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details you should have received a copy of the gnu general public license along with this program if not see http www gnu org licenses extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 503 file(s). Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Reviewed-by:
Alexios Zavras <alexios.zavras@intel.com> Reviewed-by:
Allison Randal <allison@lohutok.net> Reviewed-by:
Enrico Weigelt <info@metux.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190602204653.811534538@linutronix.deSigned-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 17 Jun, 2019 2 commits
-
-
Dan Carpenter authored
The problem is that on 64bit systems then we don't clear the higher bits of the "pending" variable. So when we do: ack = pending & ~BIT(STMFX_REG_IRQ_SRC_EN_GPIO); if (ack) { the if (ack) condition relies on uninitialized data. The fix it that I've changed "pending" from an unsigned long to a u32. I changed "n" as well, because that's a number in the 0-10 range and it fits easily inside an int. We do need to add a cast to "pending" when we use it in the for_each_set_bit() loop, but that doesn't cause a problem, it's fine. Fixes: 06252ade ("mfd: Add ST Multi-Function eXpander (STMFX) core driver") Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Acked-by:
Amelie Delaunay <amelie.delaunay@st.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
Keerthy authored
Add support for 4-phase LP87561 combination. Data Sheet: https://www.ti.com/lit/ds/symlink/lp87561-q1.pdfSigned-off-by:
Keerthy <j-keerthy@ti.com> Signed-off-by:
Lee Jones <lee.jones@linaro.org>
-
- 06 Jun, 2019 1 commit
-
-
Dan Murphy authored
Add the LM36274 register support to the ti-lmu MFD driver. Signed-off-by:
Dan Murphy <dmurphy@ti.com> Acked-by:
Lee Jones <lee.jones@linaro.org> Acked-by:
Pavel Machek <pavel@ucw.cz> Signed-off-by:
Jacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 05 Jun, 2019 1 commit
-
-
Thomas Gleixner authored
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published bythe free software foundation extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 5 file(s). Signed-off-by:
Thomas Gleixner <tglx@linutronix.de> Reviewed-by:
Armijn Hemel <armijn@tjaldur.nl> Reviewed-by:
Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190531190116.345887520@linutronix.deSigned-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-