summaryrefslogtreecommitdiff
path: root/drivers/regulator/mt6359-regulator.c
AgeCommit message (Collapse)AuthorFilesLines
2023-07-18regulator: Remove duplicated include in mt6359-regulator.cYang Li1-1/+0
./drivers/regulator/mt6359-regulator.c: linux/platform_device.h is included more than once. Reported-by: Abaci Robot <abaci@linux.alibaba.com> Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=5901 Signed-off-by: Yang Li <yang.lee@linux.alibaba.com> Link: https://lore.kernel.org/r/20230718003255.124594-1-yang.lee@linux.alibaba.com Signed-off-by: Mark Brown <broonie@kernel.org>
2023-07-14regulator: Explicitly include correct DT includesRob Herring1-1/+2
The DT of_device.h and of_platform.h date back to the separate of_platform_bus_type before it as merged into the regular platform bus. As part of that merge prepping Arm DT support 13 years ago, they "temporarily" include each other. They also include platform_device.h and of.h. As a result, there's a pretty much random mix of those include files used throughout the tree. In order to detangle these headers and replace the implicit includes with struct declarations, users need to explicitly include the correct includes. Signed-off-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20230714174930.4063320-1-robh@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2023-05-18regulator: mt6359: add read check for PMIC MT6359Sen Chu1-2/+5
Add hardware version read check for PMIC MT6359 Signed-off-by: Sen Chu <sen.chu@mediatek.com Fixes: 4cfc96547512 ("regulator: mt6359: Add support for MT6359P regulator") Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com Link: https://lore.kernel.org/r/20230518040646.8730-1-sen.chu@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org
2023-03-20regulator: Set PROBE_PREFER_ASYNCHRONOUS for drivers between 5.10 and 5.15Douglas Anderson1-0/+1
This follows on the change ("regulator: Set PROBE_PREFER_ASYNCHRONOUS for drivers that existed in 4.14") but changes regulators didn't exist in Linux 5.10 but did exist in Linux 5.15. Signed-off-by: Douglas Anderson <dianders@chromium.org> Link: https://lore.kernel.org/r/20230316125351.5.Ia0e6d859bdfe42ea5c187fb1eb4705c1b5ea23a1@changeid Signed-off-by: Mark Brown <broonie@kernel.org>
2021-07-12regulator: mt6359: Remove shift fields from struct mt6359_regulator_infoAxel Lin1-11/+8
The shift setting can be calculated via the corresponding mask field, so remove these shift fields. Signed-off-by: Axel Lin <axel.lin@ingics.com> Link: https://lore.kernel.org/r/20210629130503.2183574-2-axel.lin@ingics.com Signed-off-by: Mark Brown <broonie@kernel.org>
2021-06-07regulator: mt6359: Get rid of linear_range tablesAxel Lin1-98/+59
The MT6359_BUCK and MT6359_LDO_LINEAR macros setup both linear settings (min_uV, uV_step, linear_min_sel) and linar_range (linear_ranges, n_linear_ranges) settings. All the linear range tables actually only has one entry. Let's simplify it by using linear instead of linear range. The linear_min_sel setting is 0 for all cases, remove it from the macros. Signed-off-by: Axel Lin <axel.lin@ingics.com> Link: https://lore.kernel.org/r/20210606065052.1417111-3-axel.lin@ingics.com Signed-off-by: Mark Brown <broonie@kernel.org>
2021-06-07regulator: mt6359: Use unsigned int for volt_tablesAxel Lin1-18/+18
The regulator_desc expects "const unsigned int *volt_table", thus use unsigned int instead of u32. Signed-off-by: Axel Lin <axel.lin@ingics.com> Link: https://lore.kernel.org/r/20210606065052.1417111-2-axel.lin@ingics.com Signed-off-by: Mark Brown <broonie@kernel.org>
2021-06-01regulator: mt6359: Add support for MT6359P regulatorHsin-Hsiung Wang1-6/+373
The MT6359P is a eco version for MT6359 regulator. We add support based on MT6359 regulator driver. Signed-off-by: Hsin-Hsiung Wang <hsin-hsiung.wang@mediatek.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
2021-06-01regulator: mt6359: Add support for MT6359 regulatorWen Su1-0/+669
The MT6359 is a regulator found on boards based on MediaTek MT6779 and probably other SoCs. It is a so called pmic and connects as a slave to SoC using SPI, wrapped inside the pmic-wrapper. Signed-off-by: Wen Su <wen.su@mediatek.com> Signed-off-by: Hsin-Hsiung Wang <hsin-hsiung.wang@mediatek.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>