Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Documentation: devicetree: Add DT bindings to eeprom_93xx46 driver.

This commit documents bindings to be added to the eeprom_93xx46 driver
which will allow:

- Device word size and read-only attributes to be specified.
- A device-specific compatible string for use with Atmel AT93C46D
EEPROMs.
- Specifying a GPIO line to function as a 'select' or 'enable' signal
prior to accessing the EEPROM.

Signed-off-by: Cory Tusar <cory.tusar@pid1solutions.com>
Acked-by: Rob Herring <robh@kernel.org>
Tested-by: Chris Healy <chris.healy@zii.aero>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Cory Tusar and committed by
Greg Kroah-Hartman
862a4a78 cb54ad6c

+25
+25
Documentation/devicetree/bindings/misc/eeprom-93xx46.txt
··· 1 + EEPROMs (SPI) compatible with Microchip Technology 93xx46 family. 2 + 3 + Required properties: 4 + - compatible : shall be one of: 5 + "atmel,at93c46d" 6 + "eeprom-93xx46" 7 + - data-size : number of data bits per word (either 8 or 16) 8 + 9 + Optional properties: 10 + - read-only : parameter-less property which disables writes to the EEPROM 11 + - select-gpios : if present, specifies the GPIO that will be asserted prior to 12 + each access to the EEPROM (e.g. for SPI bus multiplexing) 13 + 14 + Property rules described in Documentation/devicetree/bindings/spi/spi-bus.txt 15 + apply. In particular, "reg" and "spi-max-frequency" properties must be given. 16 + 17 + Example: 18 + eeprom@0 { 19 + compatible = "eeprom-93xx46"; 20 + reg = <0>; 21 + spi-max-frequency = <1000000>; 22 + spi-cs-high; 23 + data-size = <8>; 24 + select-gpios = <&gpio4 4 GPIO_ACTIVE_HIGH>; 25 + };