History log of /linux-master/drivers/regulator/tps6287x-regulator.c
Revision Date Author Comments
# c6929055 29-Aug-2023 Vincent Whitchurch <vincent.whitchurch@axis.com>

regulator: tps6287x: Fix n_voltages

There are 256 possible voltage settings for each range, not 256 possible
voltage settings in total.

Fixes: 15a1cd245d5b ("regulator: tps6287x: Fix missing .n_voltages setting")
Signed-off-by: Vincent Whitchurch <vincent.whitchurch@axis.com
Link: https://lore.kernel.org/r/20230829-tps-voltages-v1-1-7ba4f958a194@axis.com
Signed-off-by: Mark Brown <broonie@kernel.org


# 269cb04b 14-Jul-2023 Chen-Yu Tsai <wenst@chromium.org>

regulator: Use bitfield values for range selectors

Right now the regulator helpers expect raw register values for the range
selectors. This is different from the voltage selectors, which are
normalized as bitfield values. This leads to a bit of confusion. Also,
raw values are harder to copy from datasheets or match up with them,
as datasheets will typically have bitfield values.

Make the helpers expect bitfield values, and convert existing users. The
field in regulator_desc is renamed to |linear_range_selectors_bitfield|.
This is intended to cause drivers added in the same merge window and
out-of-tree drivers using the incorrect variable and values to break,
preventing incorrect values being used on actual hardware and potentially
producing magic smoke.

Also include bitops.h explicitly for ffs(), and reorder the header include
statements. While at it, also replace module.h with export.h, since the
only use is EXPORT_SYMBOL_GPL.

Signed-off-by: Chen-Yu Tsai <wenst@chromium.org>
Link: https://lore.kernel.org/r/20230714081408.274567-1-wenst@chromium.org
Signed-off-by: Mark Brown <broonie@kernel.org>


# 045a44d4 14-Jul-2023 Rob Herring <robh@kernel.org>

regulator: Explicitly include correct DT includes

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>


# d692cc61 11-Jun-2023 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

regulator: Switch two more i2c drivers back to use .probe()

The previous conversion back to .probe done in commit 964e186547b2
("regulator: Switch i2c drivers back to use .probe()") was done based on
v6.3. Since then two more drivers were added which need to be convert
back in the same way before eventually .probe_new() can be dropped from
struct i2c_driver.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Link: https://lore.kernel.org/r/20230611203559.827168-1-u.kleine-koenig@pengutronix.de
Signed-off-by: Mark Brown <broonie@kernel.org>


# 15a1cd24 16-May-2023 Axel Lin <axel.lin@ingics.com>

regulator: tps6287x: Fix missing .n_voltages setting

Otherwise, regulator_list_voltage() will return -EINVAL.

Signed-off-by: Axel Lin <axel.lin@ingics.com
Link: https://lore.kernel.org/r/20230516082333.466429-1-axel.lin@ingics.com
Signed-off-by: Mark Brown <broonie@kernel.org


# 7b0518fb 08-May-2023 Mårten Lindahl <marten.lindahl@axis.com>

regulator: Add support for TI TPS6287x regulators

Add support for Texas Instruments TPS6287x, single-channel
synchronous step-down converters with four output voltage ranges.

Signed-off-by: Mårten Lindahl <marten.lindahl@axis.com
Link: https://lore.kernel.org/r/20230502-tps6287x-driver-v3-2-e25140a023f5@axis.com
Signed-off-by: Mark Brown <broonie@kernel.org