aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelipe Balbi <balbi@ti.com>2013-11-11 02:56:43 -0500
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2013-11-11 03:01:45 -0500
commitc9aeb249bf72edcf1ca28fe301fb3cbb53cb23d8 (patch)
tree18cc82506adda0bb411a6266676a0e90e8bb5b4d
parenta0137817476ce9dc8c5cfd8078862796bbb8c70c (diff)
Input: ti_am335x_tsc - fix spelling mistake in TSC/ADC DT binding
There was a spelling mistake on TSC/ADC binding where "coordinate" was spelled as "coordiante". We can't simply fix the error due to DT being an ABI, the approach taken was to first use correct spelling and if that fails, fall back to miss-spelled version. It's unfortunate that has creeped into the tree. Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-rw-r--r--Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt2
-rw-r--r--arch/arm/boot/dts/am335x-evm.dts2
-rw-r--r--drivers/input/touchscreen/ti_am335x_tsc.c9
3 files changed, 10 insertions, 3 deletions
diff --git a/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt b/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt
index 491c97b78384..878549ba814d 100644
--- a/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt
+++ b/Documentation/devicetree/bindings/input/touchscreen/ti-tsc-adc.txt
@@ -6,7 +6,7 @@ Required properties:
6 ti,wires: Wires refer to application modes i.e. 4/5/8 wire touchscreen 6 ti,wires: Wires refer to application modes i.e. 4/5/8 wire touchscreen
7 support on the platform. 7 support on the platform.
8 ti,x-plate-resistance: X plate resistance 8 ti,x-plate-resistance: X plate resistance
9 ti,coordiante-readouts: The sequencer supports a total of 16 9 ti,coordinate-readouts: The sequencer supports a total of 16
10 programmable steps each step is used to 10 programmable steps each step is used to
11 read a single coordinate. A single 11 read a single coordinate. A single
12 readout is enough but multiple reads can 12 readout is enough but multiple reads can
diff --git a/arch/arm/boot/dts/am335x-evm.dts b/arch/arm/boot/dts/am335x-evm.dts
index e8ec8756e498..c5b73bcd3686 100644
--- a/arch/arm/boot/dts/am335x-evm.dts
+++ b/arch/arm/boot/dts/am335x-evm.dts
@@ -509,7 +509,7 @@
509 tsc { 509 tsc {
510 ti,wires = <4>; 510 ti,wires = <4>;
511 ti,x-plate-resistance = <200>; 511 ti,x-plate-resistance = <200>;
512 ti,coordiante-readouts = <5>; 512 ti,coordinate-readouts = <5>;
513 ti,wire-config = <0x00 0x11 0x22 0x33>; 513 ti,wire-config = <0x00 0x11 0x22 0x33>;
514 }; 514 };
515 515
diff --git a/drivers/input/touchscreen/ti_am335x_tsc.c b/drivers/input/touchscreen/ti_am335x_tsc.c
index df9b24f7e2cb..ad7564296ddf 100644
--- a/drivers/input/touchscreen/ti_am335x_tsc.c
+++ b/drivers/input/touchscreen/ti_am335x_tsc.c
@@ -348,9 +348,16 @@ static int titsc_parse_dt(struct platform_device *pdev,
348 if (err < 0) 348 if (err < 0)
349 return err; 349 return err;
350 350
351 err = of_property_read_u32(node, "ti,coordiante-readouts", 351 /*
352 * Try with the new binding first. If it fails, try again with
353 * bogus, miss-spelled version.
354 */
355 err = of_property_read_u32(node, "ti,coordinate-readouts",
352 &ts_dev->coordinate_readouts); 356 &ts_dev->coordinate_readouts);
353 if (err < 0) 357 if (err < 0)
358 err = of_property_read_u32(node, "ti,coordiante-readouts",
359 &ts_dev->coordinate_readouts);
360 if (err < 0)
354 return err; 361 return err;
355 362
356 return of_property_read_u32_array(node, "ti,wire-config", 363 return of_property_read_u32_array(node, "ti,wire-config",