- 11 Dec, 2020 2 commits
-
-
Zheng Yongjun authored
Replace a comma between expression statements by a semicolon. Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com> Link: https://lore.kernel.org/r/20201211084510.2264-1-zhengyongjun3@huawei.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Fabio Estevam authored
Since 5.10-rc1 i.MX is a devicetree-only platform, so simplify the code by removing the unused non-DT support. Signed-off-by: Fabio Estevam <festevam@gmail.com> Link: https://lore.kernel.org/r/20201210212748.5849-1-festevam@gmail.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 10 Dec, 2020 1 commit
-
-
Marek Szyprowski authored
Add proper modalias structures to let this driver load automatically if compiled as module, because max14577 MFD driver creates MFD cells with such compatible strings. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> Link: https://lore.kernel.org/r/20201210112139.5370-1-m.szyprowski@samsung.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 08 Dec, 2020 2 commits
-
-
Mark Brown authored
This patch fixes a couple of bugs in the DA9121 driver. One in an uninialised string I forgot to remove when changing to of_parse_cb() The other is an index for an optional DT property which overflows Adam Ward (2): regulator: da9121: Remove uninitialised string variable regulator: da9121: Fix index used for DT property drivers/regulator/da9121-regulator.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) -- 1.9.1
-
Dan Carpenter authored
There is a missing "return ret;" on this error path so we call "da9121_check_device_type(i2c, chip);" which will end up dereferencing "chip->regmap" and lead to an Oops. Fixes: c860476b ("regulator: da9121: Add device variant regmaps") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/X85soGKnWAjPUA7a@mwandaSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 07 Dec, 2020 2 commits
-
-
Adam Ward authored
Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/2cf324b68d37c4059c7995e8cab5fc9a608ea65d.1607361013.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Erroneously left in when switched to using of_parse_cb() Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/c7a9e947a9582fe0150d860b5eab7e093cd832bb.1607361013.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 04 Dec, 2020 3 commits
-
-
Vinod Koul authored
Add support from RPMH regulators found in PM8350 and PM8350c PMICs Signed-off-by: Vinod Koul <vkoul@kernel.org> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20201203071244.2652297-2-vkoul@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Vinod Koul authored
Add PM8350 and PM8350C compatibles for these PMICs found in some Qualcomm platforms. Signed-off-by: Vinod Koul <vkoul@kernel.org> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20201203071244.2652297-1-vkoul@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Arnd Bergmann authored
When CONFIG_GPIOLIB is disabled, the declarations from linux/gpio/consumer.h are not visible: drivers/regulator/da9121-regulator.c:371:14: error: implicit declaration of function 'fwnode_gpiod_get_index' [-Werror,-Wimplicit-function-declaration] ena_gpiod = fwnode_gpiod_get_index(of_fwnode_handle(np), "enable", 0, ^ drivers/regulator/da9121-regulator.c:372:7: error: use of undeclared identifier 'GPIOD_OUT_HIGH' GPIOD_OUT_HIGH | ^ drivers/regulator/da9121-regulator.c:373:7: error: use of undeclared identifier 'GPIOD_FLAGS_BIT_NONEXCLUSIVE' GPIOD_FLAGS_BIT_NONEXCLUSIVE, Include this explicitly to help compile testing. Fixes: 46c413d5 ("regulator: da9121: Add support for device variants via devicetree") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Link: https://lore.kernel.org/r/20201204165229.3754763-1-arnd@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 03 Dec, 2020 1 commit
-
-
Zou Wei authored
Fix the following sparse warnings: drivers/regulator/da9121-regulator.c:55:21: warning: symbol 'da9121_10A_2phase_current' was not declared. Should it be static? drivers/regulator/da9121-regulator.c:63:21: warning: symbol 'da9121_6A_2phase_current' was not declared. Should it be static? drivers/regulator/da9121-regulator.c:71:21: warning: symbol 'da9121_5A_1phase_current' was not declared. Should it be static? drivers/regulator/da9121-regulator.c:79:21: warning: symbol 'da9121_3A_1phase_current' was not declared. Should it be static? drivers/regulator/da9121-regulator.c:151:32: warning: symbol 'status_event_handling' was not declared. Should it be static? Signed-off-by: Zou Wei <zou_wei@huawei.com> Acked-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/1606994795-36182-1-git-send-email-zou_wei@huawei.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 02 Dec, 2020 1 commit
-
-
Adam Ward authored
Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/24b2d8b0c3536408369add034221b1141e58bbfc.1606908582.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 01 Dec, 2020 10 commits
-
-
Adam Ward authored
Adds interrupt handler for variants, and notifications for events; over temperature/voltage/current. Because the IRQs are triggered by persisting status, they must be masked and the status polled until clear, before the IRQ can be enabled again. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/fe21796bbcbadff84a472a4cc581ae8fafc7f8f5.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Adds get/set for mode, and mapping from REGULATOR_MODE_* to select PFM/PWM/Auto operation. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/7844c8f6facb6f7c0649381629cc75ccad14723d.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
This commit adds support for getting/setting current for all supported variants. Limits are adjusted per variant to match HW implementation. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/9aa80b909893dbe609730919ed595c6a8ac26606.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Add function which iterates the regulator descriptors for the confirmed variant ID and registers each buck. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/1fd53c3ab032ef3c8a92f80a2247381db1c09ced.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Add devicetree configuration and device variant parameters. Use the latter to enable the check and use of parameters specific to dual buck variants. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/5849ce60595aef1018bdde7dcfb54a7397597545.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Descriptors for bucks in all variants, ready for of_regulator_match Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/8f7a11d59e5ac3ba1bfd448bcfc905efc99b7874.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Add ability to probe device and validate configuration, then apply a regmap configuration for a single or dual buck device accordingly. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/068c6b8d5e1b4e221e899e4c914c429429a2ec7d.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Add basic support for configuration to reference variants of this device, and track the selected variant within the driver. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/aaabd3063593e5172fa6b605884d475df64e6d65.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Add header file for Dialog Semiconductor DA9121 regulator and related devices, mostly autogenerated from the chip design databases, and update driver to replace local defines with those from header. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/3527d84448d1e6ddc0fcb883ae564880f75a6cb0.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Adam Ward authored
Update bindings for the Dialog Semiconductor DA9121 voltage regulator to add device variants. Because several variants have multiple regulators, and to regard potential to add GPIO support in future, the 'regulators' sub-node is added, following the precedent set by other multi-regulator devices, including the DA9211 family. This breaks compatibility with the original submission by Vincent Whitchurch - but as this is still in for-next, the alignment could be made before upstreaming occurs. Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com> Link: https://lore.kernel.org/r/0606d3ded5fef4c38760246146f197db4ce3a374.1606755367.git.Adam.Ward.opensource@diasemi.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 30 Nov, 2020 2 commits
-
-
Jagan Teki authored
Add NXP PF8100/PF8121A/PF8200 regulator driver. PF8100/PF8121A/PF8200 is PMIC designed for highperformance consumer applications. It features seven high efficiency buck, four linear and one vsnvs regulators. Tested in Engicam i.Core MX8M Mini SOM platform boards. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Signed-off-by: Jagan Teki <jagan@amarulasolutions.com> Link: https://lore.kernel.org/r/20201130112329.104614-2-jagan@amarulasolutions.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Jagan Teki authored
Add NXP PF8100/PF8121A/PF8200 regulators bindings. Signed-off-by: Jagan Teki <jagan@amarulasolutions.com> Link: https://lore.kernel.org/r/20201130112329.104614-1-jagan@amarulasolutions.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 26 Nov, 2020 3 commits
-
-
Vinod Koul authored
Add support from RPMH regulators found in SDX55 platform Signed-off-by: Vinod Koul <vkoul@kernel.org> Link: https://lore.kernel.org/r/20201126093018.1085594-2-vkoul@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Vinod Koul authored
Add PMX55 compatibles for PMIC found in SDX55 platform Signed-off-by: Vinod Koul <vkoul@kernel.org> Link: https://lore.kernel.org/r/20201126093018.1085594-1-vkoul@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Claudiu Beznea authored
Selectors lower than linear_min_sel should not be considered invalid. Thus return zero in case _regulator_list_voltage(), regulator_list_hardware_vsel() or regulator_list_voltage_table() receives such selectors as argument. Fixes: bdcd1177 ("regulator: core: validate selector against linear_min_sel") Reported-by: Jon Hunter <jonathanh@nvidia.com> Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com> Link: https://lore.kernel.org/r/1606325147-606-1-git-send-email-claudiu.beznea@microchip.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 25 Nov, 2020 1 commit
-
-
Michael Klein authored
Signed-off-by: Michael Klein <michael@fossekall.de> Link: https://lore.kernel.org/r/20201124183730.2250690-2-michael@fossekall.deSigned-off-by: Mark Brown <broonie@kernel.org>
-
- 23 Nov, 2020 6 commits
-
-
Cristian Marussi authored
Add a simple regulator based on SCMI Voltage Domain Protocol. Signed-off-by: Cristian Marussi <cristian.marussi@arm.com> ---- v6 --> v7 - add proper blank lines between semantic blocks - fix return value on error path of scmi_reg_is_enabled() - use generic Failure message on err path of info_get() - fix comment containing apostrophe v3 --> v4 - using of_match_full_name core regulator flag - avoid coccinelle falde complaints about pointer-sized allocations v2 --> v3 - remove multiple linear mappings support - removed duplicated voltage name printout - added a few comments - simplified return path in scmi_reg_set_voltage_sel() v1 --> v2 - removed duplicate regulator naming - removed redundant .get/set_voltage ops: only _sel variants implemented - removed condexpr on fail path to increase readability v0 --> v1 - fixed init_data constraint parsing - fixes for v5.8 (linear_range.h) - fixed commit message content and subject line format - factored out SCMI core specific changes to distinct patch - reworked Kconfig and Makefile to keep proper alphabetic order - fixed SPDX comment style - removed unneeded inline functions - reworked conditionals for legibility - fixed some return paths to properly report SCMI original errors codes - added some more descriptive error messages when fw returns invalid ranges - removed unneeded explicit devm_regulator_unregister from .remove() Link: https://lore.kernel.org/r/20201123202336.46701-4-cristian.marussi@arm.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cristian Marussi authored
Remove optional properties bindings descriptions for SCMI Regulators. Signed-off-by: Cristian Marussi <cristian.marussi@arm.com> Link: https://lore.kernel.org/r/20201123202336.46701-2-cristian.marussi@arm.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Merge series "Add support for SCMIv3.0 Voltage Domain Protocol and SCMI-Regulator" from Cristian Marussi <cristian.marussi@arm.com>: Hi, this series introduces the support for the new SCMI Voltage Domain Protocol defined by the upcoming SCMIv3.0 specification, whose BETA release is available at [1]. Afterwards, a new generic SCMI Regulator driver is developed on top of the new SCMI VD Protocol. In V4 Patch 3/5 introduced a needed fix in Regulator framework to cope with generic named nodes. The series is currently based on for-next/scmi [2] on top of: commit b141fca08207 ("firmware: arm_scmi: Fix missing destroy_workqueue()") Any feedback welcome, Thanks, Cristian --- v5 --> v6 - reordered dt bindings patch - removed single field struct - reviewed args to scmi_init_voltage_levels() - allocating scmi_voltage_info_array contiguously v4 --> v5 - rebased - VD Protocol - removed inline - moved segmented intervals defines - fixed some macros complaints by checkpatch v3 --> v4 - DT bindings - using generic node names - listing explicitly subset of supported regulators bindings - SCMI Regulator - using of_match_full_name core regulator flag - avoid coccinelle false flag complaints - VD Protocol - avoid coccinelle false flag complaints - avoiding fixed size typing v2 --> v3 - DT bindings - avoid awkard examples based on _cpu/_gpu regulators - SCMI Regulator - remove multiple linear mappings support - removed duplicated voltage name printout - added a few comments - simplified return path in scmi_reg_set_voltage_sel() - VD Protocol - restrict segmented voltage domain descriptors to one triplet - removed unneeded inline - free allocated resources for invalid voltage domain - added __must_check to info_get voltage operations - added a few comments - removed fixed size typing from struct voltage_info v1 --> v2 - rebased on for-next/scmi v5.10 - DT bindings - removed any reference to negative voltages - SCMI Regulator - removed duplicate regulator naming - removed redundant .get/set_voltage ops: only _sel variants implemented - removed condexpr on fail path to increase readability - VD Protocol - fix voltage levels query loop to reload full cmd description between iterations as reported by Etienne Carriere - ensure transport rx buffer is properly sized calli scmi_reset_rx_to_maxsz between transfers [1]:https://developer.arm.com/documentation/den0056/c/ [2]:https://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux.git/log/?h=for-next/scmi Cristian Marussi (5): firmware: arm_scmi: Add Voltage Domain Support firmware: arm_scmi: add SCMI Voltage Domain devname regulator: core: add of_match_full_name boolean flag dt-bindings: arm: add support for SCMI Regulators regulator: add SCMI driver .../devicetree/bindings/arm/arm,scmi.txt | 43 ++ drivers/firmware/arm_scmi/Makefile | 2 +- drivers/firmware/arm_scmi/common.h | 1 + drivers/firmware/arm_scmi/driver.c | 3 + drivers/firmware/arm_scmi/voltage.c | 380 ++++++++++++++++ drivers/regulator/Kconfig | 9 + drivers/regulator/Makefile | 1 + drivers/regulator/of_regulator.c | 8 +- drivers/regulator/scmi-regulator.c | 409 ++++++++++++++++++ include/linux/regulator/driver.h | 3 + include/linux/scmi_protocol.h | 64 +++ 11 files changed, 920 insertions(+), 3 deletions(-) create mode 100644 drivers/firmware/arm_scmi/voltage.c create mode 100644 drivers/regulator/scmi-regulator.c -- 2.17.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
-
Gustavo A. R. Silva authored
In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning by explicitly adding a fallthrough pseudo-keyword instead of letting the code fall through to the next case. Link: https://github.com/KSPP/linux/issues/115Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org> Link: https://lore.kernel.org/r/c0efb81064f71837f19408f65b52d155103ee514.1605896059.git.gustavoars@kernel.orgSigned-off-by: Mark Brown <broonie@kernel.org>
-
Cristian Marussi authored
During regulators registration, if .of_match and .regulators_node are defined as non-null strings in struct regulator_desc the core searches the DT subtree rooted at .regulators_node trying to match, at first, .of_match against the 'regulator-compatible' property and, then, falling back to use the name of the node itself to determine a good match. Property 'regulator-compatible', though, is now deprecated and falling back to match against the node name, works fine only as long as the involved nodes are named in an unique way across the searched subtree; if that's not the case, like when using <common-name>@<unit> style naming for properties indexed via 'reg' property (as advised by the standard), the above matching mechanism based on the simple common name will lead to multiple matches and the only viable alternative would be to properly define the now deprecated 'regulator-compatible' as the node full name, i.e. <common-name>@<unit>. In order to address this case without using such deprecated binding, define a new boolean flag .of_match_full_name in struct regulator_desc to force the core to match against the node full-name instead of the plain name. Signed-off-by: Cristian Marussi <cristian.marussi@arm.com> Link: https://lore.kernel.org/r/20201119191051.46363-4-cristian.marussi@arm.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Merge tag 'scmi-voltage-5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux into regulator-5.11 SCMI voltage domain management protocol support for v5.11 SCMI v3.0 voltage domain protocol support to discover the voltage levels supported by the domains and to set/get the configuration and voltage level of any given domain.
-
- 20 Nov, 2020 3 commits
-
-
Cristian Marussi authored
Add SCMI voltage domain device name to the core list of supported protocol devices so that it can be enumerated if the firmware supports it. Link: https://lore.kernel.org/r/20201119191051.46363-3-cristian.marussi@arm.comSigned-off-by: Cristian Marussi <cristian.marussi@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
-
Cristian Marussi authored
SCMI v3.0 introduces voltage domain protocol which provides commands to: - Discover the voltage levels supported by a domain - Get the configuration and voltage level of a domain - Set the configuration and voltage level of a domain Let us add support for the same. Link: https://lore.kernel.org/r/20201119191051.46363-2-cristian.marussi@arm.comSigned-off-by: Cristian Marussi <cristian.marussi@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
-
Cristian Marussi authored
Add devicetree bindings to support regulators based on SCMI Voltage Domain Protocol. Link: https://lore.kernel.org/r/20201119191051.46363-5-cristian.marussi@arm.comReviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Cristian Marussi <cristian.marussi@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
-
- 13 Nov, 2020 3 commits
-
-
Claudiu Beznea authored
Do not continue if selector has already been located. Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com> Link: https://lore.kernel.org/r/1605290164-11556-1-git-send-email-claudiu.beznea@microchip.comSigned-off-by: Mark Brown <broonie@kernel.org>
-
Mark Brown authored
Merge series "regulator: mcp16502: add support for ramp delay" from Claudiu Beznea <claudiu.beznea@microchip.com>: Hi, This series adds support for ramp delay on mcp16502. It also adds some cleanup on mcp16502. Apart from that patches 1/6 fixes the selector validation in case the regulator::desc::linear_min_sel is not zero. Thank you, Claudiu Beznea Changes in v3: - fix compilation error in patch 5/6 Reported-by: kernel test robot <lkp@intel.com> Changes in v2: - rebase on top of regulator/for-next - checked 1/6 and 3/6 applies on top of regulator/for-5.10 Claudiu Beznea (6): regulator: core: validate selector against linear_min_sel regulator: core: do not continue if selector match regulator: mcp16502: add linear_min_sel regulator: mcp16502: adapt for get/set on other registers regulator: mcp16502: add support for ramp delay regulator: mcp16502: remove void documentation of struct mcp16502 drivers/regulator/core.c | 12 +++- drivers/regulator/helpers.c | 3 +- drivers/regulator/mcp16502.c | 135 ++++++++++++++++++++++++++++++++++++------- 3 files changed, 127 insertions(+), 23 deletions(-) -- 2.7.4 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
-
Claudiu Beznea authored
There are regulators who's min selector is not zero. Selectors loops (looping b/w zero and regulator::desc::n_voltages) might throw errors because invalid selectors are used (lower than regulator::desc::linear_min_sel). For this situations validate selectors against regulator::desc::linear_min_sel. Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com> Link: https://lore.kernel.org/r/1605280870-32432-2-git-send-email-claudiu.beznea@microchip.comSigned-off-by: Mark Brown <broonie@kernel.org>
-