Skip to content

Commit d3b018f

Browse files
Carlos Meningroeck
authored andcommitted
dt-bindings: hwmon: (adc128d818) Specify ti,mode property size
By default, cells in DT are 32-bit in size. The driver reads "ti,mode" using the function of_property_read_u8() which causes the value to be read incorrectly in little-endian architectures if the size is not specified. Make it explicit in the binding documentation that this prorperty must be set as a 8-bit value. Signed-off-by: Carlos Menin <menin@carlosaurelio.net> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
1 parent 5fd43dd commit d3b018f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Documentation/devicetree/bindings/hwmon/adc128d818.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,13 @@ Required node properties:
2626

2727
Optional node properties:
2828

29-
- ti,mode: Operation mode (see above).
29+
- ti,mode: Operation mode (u8) (see above).
3030

3131

3232
Example (operation mode 2):
3333

3434
adc128d818@1d {
3535
compatible = "ti,adc128d818";
3636
reg = <0x1d>;
37-
ti,mode = <2>;
37+
ti,mode = /bits/ 8 <2>;
3838
};

0 commit comments

Comments
 (0)