diff options
| author | Wolfram Sang <wsa@the-dreams.de> | 2018-04-19 16:00:08 -0400 |
|---|---|---|
| committer | Wolfram Sang <wsa@the-dreams.de> | 2018-05-17 10:27:52 -0400 |
| commit | 62ea22c4954f5b147488eefa644d668e843be6f7 (patch) | |
| tree | 34a8a79e0cfee07467fb147a40b414ffcf1d1f71 /include/linux/platform_data | |
| parent | 1e9d42194e4c8f0ba3f9d4f72b5f54050ddf7a39 (diff) | |
i2c: mux: gpio: move header to platform_data
This header only contains platform_data. Move it to the proper directory.
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Acked-by: Peter Korsgaard <peter.korsgaard@barco.com>
Diffstat (limited to 'include/linux/platform_data')
| -rw-r--r-- | include/linux/platform_data/i2c-mux-gpio.h | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/include/linux/platform_data/i2c-mux-gpio.h b/include/linux/platform_data/i2c-mux-gpio.h new file mode 100644 index 000000000000..4406108201fe --- /dev/null +++ b/include/linux/platform_data/i2c-mux-gpio.h | |||
| @@ -0,0 +1,43 @@ | |||
| 1 | /* | ||
| 2 | * i2c-mux-gpio interface to platform code | ||
| 3 | * | ||
| 4 | * Peter Korsgaard <peter.korsgaard@barco.com> | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License version 2 as | ||
| 8 | * published by the Free Software Foundation. | ||
| 9 | */ | ||
| 10 | |||
| 11 | #ifndef _LINUX_I2C_MUX_GPIO_H | ||
| 12 | #define _LINUX_I2C_MUX_GPIO_H | ||
| 13 | |||
| 14 | /* MUX has no specific idle mode */ | ||
| 15 | #define I2C_MUX_GPIO_NO_IDLE ((unsigned)-1) | ||
| 16 | |||
| 17 | /** | ||
| 18 | * struct i2c_mux_gpio_platform_data - Platform-dependent data for i2c-mux-gpio | ||
| 19 | * @parent: Parent I2C bus adapter number | ||
| 20 | * @base_nr: Base I2C bus number to number adapters from or zero for dynamic | ||
| 21 | * @values: Array of bitmasks of GPIO settings (low/high) for each | ||
| 22 | * position | ||
| 23 | * @n_values: Number of multiplexer positions (busses to instantiate) | ||
| 24 | * @classes: Optional I2C auto-detection classes | ||
| 25 | * @gpio_chip: Optional GPIO chip name; if set, GPIO pin numbers are given | ||
| 26 | * relative to the base GPIO number of that chip | ||
| 27 | * @gpios: Array of GPIO numbers used to control MUX | ||
| 28 | * @n_gpios: Number of GPIOs used to control MUX | ||
| 29 | * @idle: Bitmask to write to MUX when idle or GPIO_I2CMUX_NO_IDLE if not used | ||
| 30 | */ | ||
| 31 | struct i2c_mux_gpio_platform_data { | ||
| 32 | int parent; | ||
| 33 | int base_nr; | ||
| 34 | const unsigned *values; | ||
| 35 | int n_values; | ||
| 36 | const unsigned *classes; | ||
| 37 | char *gpio_chip; | ||
| 38 | const unsigned *gpios; | ||
| 39 | int n_gpios; | ||
| 40 | unsigned idle; | ||
| 41 | }; | ||
| 42 | |||
| 43 | #endif /* _LINUX_I2C_MUX_GPIO_H */ | ||
