diff options
Diffstat (limited to 'Documentation/gpio/consumer.txt')
-rw-r--r-- | Documentation/gpio/consumer.txt | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Documentation/gpio/consumer.txt b/Documentation/gpio/consumer.txt index 6ce544191ca6..c67f806401a5 100644 --- a/Documentation/gpio/consumer.txt +++ b/Documentation/gpio/consumer.txt | |||
@@ -199,6 +199,33 @@ The active-low state of a GPIO can also be queried using the following call: | |||
199 | Note that these functions should only be used with great moderation ; a driver | 199 | Note that these functions should only be used with great moderation ; a driver |
200 | should not have to care about the physical line level. | 200 | should not have to care about the physical line level. |
201 | 201 | ||
202 | |||
203 | Set multiple GPIO outputs with a single function call | ||
204 | ----------------------------------------------------- | ||
205 | The following functions set the output values of an array of GPIOs: | ||
206 | |||
207 | void gpiod_set_array(unsigned int array_size, | ||
208 | struct gpio_desc **desc_array, | ||
209 | int *value_array) | ||
210 | void gpiod_set_raw_array(unsigned int array_size, | ||
211 | struct gpio_desc **desc_array, | ||
212 | int *value_array) | ||
213 | void gpiod_set_array_cansleep(unsigned int array_size, | ||
214 | struct gpio_desc **desc_array, | ||
215 | int *value_array) | ||
216 | void gpiod_set_raw_array_cansleep(unsigned int array_size, | ||
217 | struct gpio_desc **desc_array, | ||
218 | int *value_array) | ||
219 | |||
220 | The array can be an arbitrary set of GPIOs. The functions will try to set | ||
221 | GPIOs belonging to the same bank or chip simultaneously if supported by the | ||
222 | corresponding chip driver. In that case a significantly improved performance | ||
223 | can be expected. If simultaneous setting is not possible the GPIOs will be set | ||
224 | sequentially. | ||
225 | Note that for optimal performance GPIOs belonging to the same chip should be | ||
226 | contiguous within the array of descriptors. | ||
227 | |||
228 | |||
202 | GPIOs mapped to IRQs | 229 | GPIOs mapped to IRQs |
203 | -------------------- | 230 | -------------------- |
204 | GPIO lines can quite often be used as IRQs. You can get the IRQ number | 231 | GPIO lines can quite often be used as IRQs. You can get the IRQ number |