summaryrefslogtreecommitdiff
path: root/drivers/mfd
diff options
context:
space:
mode:
authorMiquel Raynal <miquel.raynal@bootlin.com>2021-10-15 11:14:55 +0300
committerLee Jones <lee.jones@linaro.org>2021-10-21 11:23:53 +0300
commit90fc6ff48be44ece2cb9b0012074bd0e642f48bc (patch)
treed0d68cd5e260c076280b98be53d8e71cc8abaaef /drivers/mfd
parent0a1233031c16d8575be6b864e6fd353b6fd758c4 (diff)
downloadlinux-90fc6ff48be44ece2cb9b0012074bd0e642f48bc.tar.xz
mfd: ti_am335x_tscadc: Support the correctly spelled DT property
There was in the past a typo in the coordinate readouts property. The bindings have been updated, the touchscreen driver as well and now supports both. However, the MFD driver that is in charge of verifying the validity of the property only checks the bogus one. Add support for the correctly spelled DT property. Fixes: c9aeb249bf72 ("Input: ti_am335x_tsc - fix spelling mistake in TSC/ADC DT binding") Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Link: https://lore.kernel.org/r/20211015081506.933180-38-miquel.raynal@bootlin.com
Diffstat (limited to 'drivers/mfd')
-rw-r--r--drivers/mfd/ti_am335x_tscadc.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/mfd/ti_am335x_tscadc.c b/drivers/mfd/ti_am335x_tscadc.c
index bfbc8288a71e..740cae00dac2 100644
--- a/drivers/mfd/ti_am335x_tscadc.c
+++ b/drivers/mfd/ti_am335x_tscadc.c
@@ -144,8 +144,14 @@ static int ti_tscadc_probe(struct platform_device *pdev)
if (ti_adc_with_touchscreen(tscadc)) {
node = of_get_child_by_name(pdev->dev.of_node, "tsc");
of_property_read_u32(node, "ti,wires", &tscmag_wires);
- of_property_read_u32(node, "ti,coordiante-readouts", &readouts);
+ err = of_property_read_u32(node, "ti,coordinate-readouts",
+ &readouts);
+ if (err < 0)
+ of_property_read_u32(node, "ti,coordiante-readouts",
+ &readouts);
+
of_node_put(node);
+
if (tscmag_wires)
use_tsc = true;
} else {