diff options
author | Ansuel Smith <ansuelsmth@gmail.com> | 2019-11-28 22:29:15 +0100 |
---|---|---|
committer | Petr Štetiar <ynezz@true.cz> | 2019-12-19 22:41:57 +0100 |
commit | 402153623d927c35e4ee66cf2111e8e7d456d428 (patch) | |
tree | 32d49678fd980de08e71d5ded59b17fdb8bb455f /target/linux/ipq806x | |
parent | f28e6ae7ceb89651082f75b9dceb23fecf788b73 (diff) | |
download | upstream-402153623d927c35e4ee66cf2111e8e7d456d428.tar.gz upstream-402153623d927c35e4ee66cf2111e8e7d456d428.tar.bz2 upstream-402153623d927c35e4ee66cf2111e8e7d456d428.zip |
ipq806x: fix tsens driver in 4.19
Added patch:
- 063-3 Fix tsense shared memory problem
Recent changes in ioremap_resource function are causing fails for the
memory areas which are already mapped. This changes are causing tsense
driver failures during initialization:
qcom-tsens 900000.thermal-sensor: tsens init failed
So this patch uses simple ioremap in order to use this shared memory
space.
Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
[commit subject and desciption facelitf]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Diffstat (limited to 'target/linux/ipq806x')
-rw-r--r-- | target/linux/ipq806x/patches-4.19/0063-3-tsens-fix-kernel-4_19.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/target/linux/ipq806x/patches-4.19/0063-3-tsens-fix-kernel-4_19.patch b/target/linux/ipq806x/patches-4.19/0063-3-tsens-fix-kernel-4_19.patch new file mode 100644 index 0000000000..19afe8c212 --- /dev/null +++ b/target/linux/ipq806x/patches-4.19/0063-3-tsens-fix-kernel-4_19.patch @@ -0,0 +1,20 @@ +--- a/drivers/thermal/qcom/tsens-common.c ++++ b/drivers/thermal/qcom/tsens-common.c +@@ -128,6 +128,7 @@ + { + void __iomem *base; + struct resource *res; ++ resource_size_t size; + struct platform_device *op = of_find_device_by_node(tmdev->dev->of_node); + + if (!op) +@@ -142,7 +143,8 @@ int __init init_common(struct tsens_devi + } + + res = platform_get_resource(op, IORESOURCE_MEM, 0); +- base = devm_ioremap_resource(&op->dev, res); ++ size = resource_size(res); ++ base = devm_ioremap(&op->dev, res->start, size); + if (IS_ERR(base)) + return PTR_ERR(base); + |