Use devm_pm_opp_* API to simplify code, and we don't need
to make opp_table glabal.
Let's remove opp_table from geni_se later.
Signed-off-by: Yangtao Li
---
drivers/tty/serial/qcom_geni_serial.c | 23 +--
1 file changed, 9 insertions(+), 14 deletions(-)
di
We should use dev_pm_opp_put_clkname() to free opp table each time
dev_pm_opp_of_add_table() got error.
Signed-off-by: Yangtao Li
---
drivers/tty/serial/qcom_geni_serial.c | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/tty/serial/qcom_geni_serial.c
b
Add devres wrapper for dev_pm_opp_set_clkname() and
dev_pm_opp_put_clkname() to simplify driver code.
Signed-off-by: Yangtao Li
---
drivers/opp/core.c | 47 ++
include/linux/pm_opp.h | 9
2 files changed, 56 insertions(+)
diff --git a
Add devres wrapper for dev_pm_opp_set_supported_hw() to simplify driver
code.
Signed-off-by: Yangtao Li
---
drivers/opp/core.c | 38 ++
include/linux/pm_opp.h | 8
2 files changed, 46 insertions(+)
diff --git a/drivers/opp/core.c b/drivers/opp
Use devm_pm_opp_* API to simplify code, and we don't need
to make opp_table glabal.
Let's remove opp_table from geni_se later.
Signed-off-by: Yangtao Li
---
drivers/spi/spi-geni-qcom.c | 15 ++-
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/drivers/sp
We should use dev_pm_opp_put_clkname() to free opp table each time
dev_pm_opp_of_add_table() got error.
Signed-off-by: Yangtao Li
---
drivers/spi/spi-geni-qcom.c | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/spi/spi-geni-qcom.c b/drivers/spi/spi-geni
opp_table isn't used anymore, remove it.
Signed-off-by: Yangtao Li
---
include/linux/qcom-geni-se.h | 2 --
1 file changed, 2 deletions(-)
diff --git a/include/linux/qcom-geni-se.h b/include/linux/qcom-geni-se.h
index ec2ad4b0fe14..cddef864a760 100644
--- a/include/linux/qcom-geni-se.h
We should use dev_pm_opp_put_clkname() to free opp table each time
dev_pm_opp_of_add_table() got error.
Signed-off-by: Yangtao Li
---
drivers/mmc/host/sdhci-msm.c | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci
Use devm_pm_opp_* API to simplify code, and remove opp_table
from sdhci_msm_host.
Signed-off-by: Yangtao Li
---
drivers/mmc/host/sdhci-msm.c | 19 +++
1 file changed, 7 insertions(+), 12 deletions(-)
diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index
Use devm_pm_opp_* API to simplify code, and remove opp_table
from qcom_qspi.
Signed-off-by: Yangtao Li
---
drivers/spi/spi-qcom-qspi.c | 16 ++--
1 file changed, 6 insertions(+), 10 deletions(-)
diff --git a/drivers/spi/spi-qcom-qspi.c b/drivers/spi/spi-qcom-qspi.c
index
1. Use devm_pm_opp_* to simplif code and avoid mem leak.
2. Remove opp_table from dpu_kms, dp_ctrl_private and msm_dsi_host,
since it does not need a global scope.
3. Remove dp_ctrl_put.
Signed-off-by: Yangtao Li
---
drivers/gpu/drm/msm/adreno/a5xx_gpu.c | 2 +-
drivers/gpu/drm/msm/adreno
We should use dev_pm_opp_put_clkname() to free opp table each time
dev_pm_opp_of_add_table() got error.
Signed-off-by: Yangtao Li
---
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 10 ++
drivers/gpu/drm/msm/dsi/dsi_host.c | 8 +---
2 files changed, 11 insertions(+), 7 deletions
We should use dev_pm_opp_put_clkname() to free opp table each time
dev_pm_opp_of_add_table() got error.
Signed-off-by: Yangtao Li
---
drivers/spi/spi-qcom-qspi.c | 11 ++-
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/drivers/spi/spi-qcom-qspi.c b/drivers/spi/spi-qcom
There is no need to manually release devm related resources.
Signed-off-by: Yangtao Li
---
drivers/gpu/drm/lima/lima_devfreq.c | 5 -
1 file changed, 5 deletions(-)
diff --git a/drivers/gpu/drm/lima/lima_devfreq.c
b/drivers/gpu/drm/lima/lima_devfreq.c
index d5937cf86504..7690c5c69f9f
Don't call dev_pm_opp_put_clkname() when got invalid OPP table
in device tree, since we do this in core_put_v4().
Signed-off-by: Yangtao Li
---
drivers/media/platform/qcom/venus/pm_helpers.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/media/platform/qcom/
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
drivers/memory/samsung/exynos5422-dmc.c | 21 +
1 file changed, 5 insertions(+), 16 deletions(-)
diff --git a/drivers/memory/samsung/exynos5422-dmc.c
b/drivers/memory/samsung/exynos5422-dmc.c
index
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
.../media/platform/qcom/venus/pm_helpers.c| 21 ---
1 file changed, 4 insertions(+), 17 deletions(-)
diff --git a/drivers/media/platform/qcom/venus/pm_helpers.c
b/drivers/media/platform/qcom/venus
We can't always return -EINVAL, let's fix it.
Signed-off-by: Yangtao Li
---
drivers/memory/samsung/exynos5422-dmc.c | 10 +++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/drivers/memory/samsung/exynos5422-dmc.c
b/drivers/memory/samsung/exynos5422-d
Use devm_pm_opp_* API to simplify code, and remove opp_table
from lima_devfreq.
Signed-off-by: Yangtao Li
---
drivers/gpu/drm/lima/lima_devfreq.c | 40 -
drivers/gpu/drm/lima/lima_devfreq.h | 2 --
2 files changed, 10 insertions(+), 32 deletions(-)
diff --git a
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
drivers/memory/tegra/tegra20-emc.c | 29 +
1 file changed, 9 insertions(+), 20 deletions(-)
diff --git a/drivers/memory/tegra/tegra20-emc.c
b/drivers/memory/tegra/tegra20-emc.c
index 686aaf477d8a
Use devm_pm_opp_* API to simplify code, and remove opp_table
from panfrost_devfreq.
Signed-off-by: Yangtao Li
---
drivers/gpu/drm/panfrost/panfrost_devfreq.c | 34 ++---
drivers/gpu/drm/panfrost/panfrost_devfreq.h | 1 -
2 files changed, 10 insertions(+), 25 deletions(-)
diff
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
drivers/memory/tegra/tegra30-emc.c | 29 +
1 file changed, 9 insertions(+), 20 deletions(-)
diff --git a/drivers/memory/tegra/tegra30-emc.c
b/drivers/memory/tegra/tegra30-emc.c
index 44ac155936aa
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
drivers/devfreq/imx8m-ddrc.c | 15 ++-
1 file changed, 2 insertions(+), 13 deletions(-)
diff --git a/drivers/devfreq/imx8m-ddrc.c b/drivers/devfreq/imx8m-ddrc.c
index bc82d3653bff..9383d6e5538b 100644
--- a
Use devm_pm_opp_* API to simplify code. Since devres release
can guarantee the order, let's remove
devm_devfreq_unregister_opp_notifier().
Signed-off-by: Yangtao Li
---
drivers/devfreq/rk3399_dmc.c | 22 +++---
1 file changed, 3 insertions(+), 19 deletions(-)
diff --
Use devm_pm_opp_* API to simplify code, and remove opp_table
from tegra_devfreq.
Signed-off-by: Yangtao Li
---
drivers/devfreq/tegra30-devfreq.c | 21 +++--
1 file changed, 7 insertions(+), 14 deletions(-)
diff --git a/drivers/devfreq/tegra30-devfreq.c
b/drivers/devfreq
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
drivers/devfreq/devfreq.c | 66 +--
include/linux/devfreq.h | 23 --
2 files changed, 1 insertion(+), 88 deletions(-)
diff --git a/drivers/devfreq/devfreq.c b/drivers
Use devm_pm_opp_* API to simplify code.
Signed-off-by: Yangtao Li
---
drivers/devfreq/imx-bus.c | 14 +++---
1 file changed, 3 insertions(+), 11 deletions(-)
diff --git a/drivers/devfreq/imx-bus.c b/drivers/devfreq/imx-bus.c
index 4f38455ad742..ff26ef049b1b 100644
--- a/drivers/devfreq
Use devm_pm_opp_* API to simplify code, and remove opp_table
from exynos_bus.
Signed-off-by: Yangtao Li
---
drivers/devfreq/exynos-bus.c | 42
1 file changed, 9 insertions(+), 33 deletions(-)
diff --git a/drivers/devfreq/exynos-bus.c b/drivers/devfreq
This brings the kernel doc in line with the function signature.
Signed-off-by: Yangtao Li
---
drivers/base/power/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c
index f80d298de3fa..0cff68bd7b4b 100644
--- a/drivers
Rearrange comment to make the comment style consistent, the previous
function parameters are described first.
Signed-off-by: Yangtao Li
---
drivers/base/power/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c
index
DEVICE_SUSPEND_FUNC() helper macro can decrease
code duplication.
Signed-off-by: Yangtao Li
---
drivers/base/power/main.c | 33 -
1 file changed, 12 insertions(+), 21 deletions(-)
diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c
index cb44bb6b2b66
This patch set introduces some functions and macros that help reduce
code duplication.
Yangtao Li (4):
PM / core: Introduce dpm_async_fn() helper
PM / core: Introduce DEVICE_SUSPEND_FUNC() helper macro
PM / core: Introduce ASYNC_RESUME_FUNC() helper macro
PM / core: Introduce
lot of such repeated operations here, in fact we can avoid
this. So introduce dpm_async_fn() to have better code readability and
reuse.
And use this function to do some cleanup.
Signed-off-by: Yangtao Li
---
drivers/base/power/main.c | 62 +++
1 file
);
if (error)
pm_dev_err(dev, pm_transition, " async", error);
put_device(dev);
}
The ASYNC_RESUME_FUNC() helper macro can decrease code duplication.
Signed-off-by: Yangtao Li
---
drivers/base/power/main.c | 46 +--
1 file c
);
if (error) {
dpm_save_failed_dev(dev_name(dev));
pm_dev_err(dev, pm_transition, " async", error);
}
put_device(dev);
}
The ASYNC_SUSPEND_FUNC() helper macro can decrease code duplication.
Signed-off-by: Yangtao Li
---
drivers/
The ARM CPU cores are fed by the CPU clock from the CCU. Add a
reference to the clock for each CPU core, along with the clock
transition latency.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 8
1 file changed, 8 insertions(+)
diff --git a/arch/arm64
The original pine use the dcdca to supply the CPU cores. According
to the axp805 spec, the range of dcdca is 0.6 to 1.1v, 1.12 to 1.52v.
In order to support more CPU frequency, slightly increase the voltage
maximum and minimum.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i
The original orangepi use the dcdca to supply the CPU cores. According
to the axp805 spec, the range of dcdca is 0.6 to 1.1v, 1.12 to 1.52v.
In order to support more CPU frequency, slightly increase the voltage
maximum and minimum.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner
Add an OPP (Operating Performance Points) table for the CPU cores to
enable DVFS (Dynamic Voltage & Frequency Scaling) on the H6. This
information comes from github.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 61
1 file changed
on the sunxi source code and has not been tested on an
actual board.
---
Yangtao Li (4):
arm64: dts: allwinner: h6: orangepi: Add CPU supply regulator
arm64: dts: allwinner: h6: pine: Add CPU supply regulator
arm64: dts: allwinner: h6: Add clock to CPU cores
arm64: dts: allwinner: h6: Add
ge of the
cpu is smaller or larger than the datasheet.
For some better quality ic, the minimum voltage can be smaller. For
some poor quality ic, the maximum voltage needs to be increased a
little.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6-pine-h64.dts | 8 ++--
1
ally.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 55
1 file changed, 55 insertions(+)
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi
b/arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi
index 723f5d991a74..84fb47062fe6 100644
--- a/arch/a
ltage of the
cpu is smaller or larger than the datasheet.
For some better quality ic, the minimum voltage can be smaller.
For some poor quality ic, the maximum voltage needs to be increased a
little.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi | 8 ++
Add the cpufreq support of h6, source of information is as follows.
h6 cpu opp info:
https://github.com/Allwinner-Homlet/H6-BSP4.9-linux/blob/master/arch/arm64/boot/dts/sunxi/sun50iw6p1.dtsi
axp805 spec:
http://linux-sunxi.org/images/b/bc/AXP805_Datasheet_V1.0_en.pdf
Yangtao Li (4):
arm64
The ARM CPU cores are fed by the CPU clock from the CCU. Add a
reference to the clock for each CPU core, along with the clock
transition latency.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 8
1 file changed, 8 insertions(+)
diff --git a/arch/arm64
Add the cpufreq information of h6 to dts, source of information is as follows.
h6 cpu opp info:
https://github.com/Allwinner-Homlet/H6-BSP4.9-linux/blob/master/arch/arm64/boot/dts/sunxi/sun50iw6p1.dtsi
axp805 spec:
http://linux-sunxi.org/images/b/bc/AXP805_Datasheet_V1.0_en.pdf
Yangtao Li (4
ltage of the
cpu is smaller or larger than the datasheet.
For some better quality ic, the minimum voltage can be smaller.
For some poor quality ic, the maximum voltage needs to be increased a
little.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi | 8 ++
ally.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 55
1 file changed, 55 insertions(+)
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi
b/arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi
index 723f5d991a74..84fb47062fe6 100644
--- a/arch/a
The ARM CPU cores are fed by the CPU clock from the CCU. Add a
reference to the clock for each CPU core, along with the clock
transition latency.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 8
1 file changed, 8 insertions(+)
diff --git a/arch/arm64
ge of the
cpu is smaller or larger than the datasheet.
For some better quality ic, the minimum voltage can be smaller. For
some poor quality ic, the maximum voltage needs to be increased a
little.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6-pine-h64.dts | 8 ++--
1
device_register() may fail, use put_device() giving up the refconut
to avoid refcount leak.
Signed-off-by: Yangtao Li
---
kernel/time/clocksource.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c
index 3bcc19ceb073
Exit latency is the time from exiting the idle state to execute
the first instruction. This place may be a typo , so fix it.
Signed-off-by: Yangtao Li
---
Documentation/admin-guide/pm/cpuidle.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/admin-guide/pm
Use BIT() to do some clean-up.
Signed-off-by: Yangtao Li
---
include/linux/irq.h | 106 ++--
1 file changed, 53 insertions(+), 53 deletions(-)
diff --git a/include/linux/irq.h b/include/linux/irq.h
index def2b2aac8b1..66c9801ce108 100644
--- a/include
Use BIT() to do some clean-up.
Signed-off-by: Yangtao Li
---
include/linux/clockchips.h | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/include/linux/clockchips.h b/include/linux/clockchips.h
index 8ae9a95ebf5b..39a2294e995b 100644
--- a/include/linux
It's a small tidy-up.
Signed-off-by: Yangtao Li
---
v2:
-add missing changelog
---
include/linux/clocksource.h | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
index b21db536fd52..130f4c3c0781 1
Signed-off-by: Yangtao Li
---
include/linux/clocksource.h | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
index b21db536fd52..130f4c3c0781 100644
--- a/include/linux/clocksource.h
+++ b/include/linux
Use BIT() macro to do a small tidy-up. The CPUIDLE_DRIVER_FLAGS_MASK
is not being used, so remove it.
Signed-off-by: Yangtao Li
---
include/linux/cpuidle.h | 8 +++-
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/include/linux/cpuidle.h b/include/linux/cpuidle.h
index
'devfreq' is malloced in devfreq_add_device() and should be freed in
the error handling cases, otherwise it will cause memory leak.
devm_kzalloc() could fail, so insert a check of its return value. And
if it fails, returns -ENOMEM.
Signed-off-by: Yangtao Li
---
drivers/devfreq/devf
devm_kzalloc() could fail, so insert a check of its return value. And
if it fails, returns -ENOMEM.
Signed-off-by: Yangtao Li
---
drivers/devfreq/devfreq.c | 14 +-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c
To beautify the code format.
Signed-off-by: Yangtao Li
---
drivers/devfreq/devfreq.c | 17 -
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c
index 0ae3de76833b..076b1c2f40a4 100644
--- a/drivers/devfreq
'devfreq' is malloced in devfreq_add_device() and should be freed in
the error handling cases, otherwise it will cause memory leak.
Signed-off-by: Yangtao Li
---
drivers/devfreq/devfreq.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/devfreq/devfreq.c
device_register() may fail, use put_device() giving up the refconut
to avoid refcount leak.
Signed-off-by: Yangtao Li
---
kernel/time/clockevents.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/kernel/time/clockevents.c b/kernel/time/clockevents.c
index
The variables are local to the source and do not
need to be in global scope, so make them static.
Signed-off-by: Yangtao Li
---
drivers/cpufreq/qcom-cpufreq-kryo.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/cpufreq/qcom-cpufreq-kryo.c
b/drivers/cpufreq/qcom
of_cpu_device_node_get() will increase the refcount of device_node,
it is necessary to call of_node_put() at the end to release the
refcount.
Signed-off-by: Yangtao Li
---
drivers/cpufreq/tegra124-cpufreq.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/cpufreq/tegra124-cpufreq.c
of_cpu_device_node_get() will increase the refcount of device_node,
it is necessary to call of_node_put() at the end to release the
refcount.
Fixes: 9eb15dbbfa1a2 ("cpufreq: Add cpufreq driver for Tegra124")
Cc: # 4.4+
Signed-off-by: Yangtao Li
---
v2:
- move of_node_put() to th
This brings the kernel doc in line with the function signature.
Signed-off-by: Yangtao Li
---
drivers/base/power/wakeup.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/power/wakeup.c b/drivers/base/power/wakeup.c
index 5fa1898755a3..f1fee72ed970 100644
--- a
To unify code style.
Signed-off-by: Yangtao Li
---
drivers/thermal/Makefile | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/thermal/Makefile b/drivers/thermal/Makefile
index fa6f8b206281..d7eafb5ef8ef 100644
--- a/drivers/thermal/Makefile
+++ b/drivers
This patchset add support for H6 thermal sensor.
BWY, do a cleanup in thermal makfile.
Yangtao Li (3):
thermal: sun8i: add thermal driver for h6
dt-bindings: thermal: add binding document for h6 thermal controller
thermal: fix indentation in makefile
.../bindings/thermal/sun8i
This patch adds the support for allwinner thermal sensor, within
allwinner SoC. It will register sensors for thermal framework
and use device tree to bind cooling device.
Signed-off-by: Yangtao Li
---
MAINTAINERS | 7 +
drivers/thermal/Kconfig | 14 +
drivers
This patch adds binding document for allwinner h6 thermal controller.
Signed-off-by: Yangtao Li
---
.../bindings/thermal/sun8i-thermal.yaml | 71 +++
1 file changed, 71 insertions(+)
create mode 100644 Documentation/devicetree/bindings/thermal/sun8i-thermal.yaml
diff
This brings the kernel doc in line with the function signature.
Signed-off-by: Yangtao Li
---
kernel/time/alarmtimer.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c
index 0519a8805aab..57518efc3810 100644
--- a/kernel/time/alarmtimer.c
Add support for H6's SID controller. It supports 4K-bit
EFUSE, bigger than before.
Signed-off-by: Yangtao Li
---
drivers/nvmem/sunxi_sid.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/drivers/nvmem/sunxi_sid.c b/drivers/nvmem/sunxi_sid.c
index 7013f9cc43c7..a079a80ddf2c 1
The device tree binding already lists compatible strings for H6
SoCs, so add a device node for iy.
Signed-off-by: Yangtao Li
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi
b/arch/arm64/boot
Add SID's support for H6.
Yangtao Li (2):
nvmem: sunxi_sid: Support SID on H6
arm64: dts: sunxi: h6: Add device node for SID
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 5 +
drivers/nvmem/sunxi_sid.c| 6 ++
2 files changed, 11 insertions(+)
--
2.17.0
The device tree binding already lists compatible strings for H6
SoC, so add a device node for it.
Signed-off-by: Yangtao Li
---
fix typo:
iy->it
0x3006000->0x03006000
---
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/arm64/bo
M area containig the speedbin information)
- opp-supported-hw: A single 32 bit bitmap value,
representing compatible HW:
0: speedbin 0
1: speedbin 1
2: speedbin 2
3-31: unused
Signe
Add sunxi nvmem based CPU scaling driver, refers to qcom-cpufreq-kryo.
Yangtao Li (2):
cpufreq: Add sunxi nvmem based CPU scaling driver
dt-bindings: cpufreq: Document operating-points-v2-sunxi-cpu
.../bindings/opp/sunxi-nvmem-cpufreq.txt | 235 +
MAINTAINERS
value from the SoC to provide the OPP framework with
required information.
Signed-off-by: Yangtao Li
---
MAINTAINERS | 7 +
drivers/cpufreq/Kconfig.arm | 10 ++
drivers/cpufreq/Makefile | 1 +
drivers/cpufreq/cpufreq-dt-platdev.c | 2
-off-by: Yangtao Li
---
MAINTAINERS | 7 +
drivers/thermal/Kconfig | 14 ++
drivers/thermal/Makefile | 1 +
drivers/thermal/sun50i_thermal.c | 357 +++
4 files changed, 379 insertions(+)
create mode 100644 drivers/thermal
This patch adds binding document for allwinner h6 thermal controller.
Signed-off-by: Yangtao Li
---
.../bindings/thermal/sun50i-thermal.txt | 32 +++
1 file changed, 32 insertions(+)
create mode 100644 Documentation/devicetree/bindings/thermal/sun50i-thermal.txt
diff
Sid contains speedbin information and temperature sensor
calibration information and more, which are important for SOC.
This patch enables CONFIG_NVMEM_SUNXI_SID by default.
Signed-off-by: Yangtao Li
---
arch/arm64/configs/defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch
This patchset support thermal driver of allwinner H6.
Yangtao Li (3):
arm64: defconfig: add allwinner sid support
thermal: sun50i: add thermal driver for h6
dt-bindings: thermal: add binding document for h6 thermal controller
.../bindings/thermal/sun50i-thermal.txt | 32
Updates license to use SPDX-License-Identifier.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/iio/adc/sun4i-gpadc-iio.c
b/drivers/iio/adc/sun4i-gpadc-iio.c
index 04d7147e0110..f13c6248a662 100644
Orangepi 3 has HDMI type A connector.
Signed-off-by: Yangtao Li
---
rebase:
sunxi/dt64-for-5.2 arm64: dts: allwinner: a64-amarula-relic: Add OV5640
camera node
---
.../dts/allwinner/sun50i-h6-orangepi-3.dts| 25 +++
1 file changed, 25 insertions(+)
diff --git a/arch/arm64
Updates license to use SPDX-License-Identifier.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/iio/adc/sun4i-gpadc-iio.c
b/drivers/iio/adc/sun4i-gpadc-iio.c
index 9b6fc592f54c..cf2bf3ab3342 100644
For some SOCs, the temperature data register start address may be
different, so introduce temp_data in gpadc_data.
Also modify read temperature to support multiple sensor.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion
thermal_zone_device and distinguish between different sensors.
3) modify read temperature and initialization function.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 61 +++
1 file changed, 45 insertions(+), 16 deletions(-)
diff --git a/drivers/iio/adc
Different sensors may have different enable and disable functions, so
introduce enable and disable in gpadc_data to support soc specific
function.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 37 ++-
1 file changed, 31 insertions(+), 6 deletions
This patch adds documentation for the H6 GPADC binding.
Signed-off-by: Yangtao Li
---
.../devicetree/bindings/mfd/sun4i-gpadc.txt | 27 +--
1 file changed, 25 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/mfd/sun4i-gpadc.txt
b/Documentation
This patch adds support for the H6 ths sensor.
TODO: calibrate thermal sensor by using information from sid.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 65 +++
include/linux/mfd/sun4i-gpadc.h | 9 +
2 files changed, 74 insertions
H6 has bus clock and a reset, so introduce something in
gpadc_data/sun4i_gpadc_iio and adds the process of the
clocks and resets.
This is pre-work for supprt it.
Signed-off-by: Yangtao Li
---
drivers/iio/adc/sun4i-gpadc-iio.c | 32 +--
1 file changed, 30 insertions
This patchset adds support for the H6 ths sensor.
Based on IIO-based thermal sensor driver for Allwinner H3 and A83T SoC,
thx to Philipp Rossak's work.
TODO: calibrate thermal sensor by using information from sid.
Yangtao Li (7):
iio: adc: sun4i-gpadc: rework for support multiple th
This patch adds the support for allwinner thermal sensor, within
allwinner SoC. It will register sensors for thermal framework
and use device tree to bind cooling device.
Signed-off-by: Yangtao Li
---
MAINTAINERS | 7 +
drivers/thermal/Kconfig | 14 ++
drivers
thermal: sun8i: add support for Allwinner R40 thermal sensor
Vasily Khoruzhick (1):
thermal: sun8i: add thermal driver for A64
Yangtao Li (14):
thermal: sun8i: add thermal driver for h6
dt-bindings: thermal: add binding document for h6 thermal controller
thermal: fix indentation in makefile
This patch adds binding document for allwinner h6 thermal controller.
Signed-off-by: Yangtao Li
---
.../bindings/thermal/sun8i-thermal.yaml | 79 +++
1 file changed, 79 insertions(+)
create mode 100644 Documentation/devicetree/bindings/thermal/sun8i-thermal.yaml
diff
For different socs, the way they get and calculate the
temperature is roughly the same. So get the difference
from device compatible.
Difference point:
1) temperature calculation formula parameters
2) ths data register start address
Signed-off-by: Yangtao Li
---
drivers/thermal
To unify code style.
Signed-off-by: Yangtao Li
---
drivers/thermal/Makefile | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/thermal/Makefile b/drivers/thermal/Makefile
index fa6f8b206281..d7eafb5ef8ef 100644
--- a/drivers/thermal/Makefile
+++ b/drivers
This patch adds binding document for allwinner a64 thermal controller.
Signed-off-by: Yangtao Li
---
Documentation/devicetree/bindings/thermal/sun8i-thermal.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/devicetree/bindings/thermal/sun8i-thermal.yaml
b/Documentation
H3 has extra clock, so introduce something in ths_thermal_chip/ths_device
and adds the process of the clock.
This is pre-work for supprt it.
Signed-off-by: Yangtao Li
---
drivers/thermal/sun8i_thermal.c | 17 -
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a
: Yangtao Li
---
drivers/thermal/sun8i_thermal.c | 86 ++---
1 file changed, 48 insertions(+), 38 deletions(-)
diff --git a/drivers/thermal/sun8i_thermal.c b/drivers/thermal/sun8i_thermal.c
index 6f4294c2aba7..47c20c4c69e7 100644
--- a/drivers/thermal/sun8i_thermal.c
201 - 300 of 365 matches
Mail list logo