Searched hist:db02247827ef2adc1617839b4bdcc5e1cef3e1ed (Results 1 – 3 of 3) sorted by relevance
/linux/drivers/gpio/ |
H A D | gpio-idio-16.h | diff db02247827ef2adc1617839b4bdcc5e1cef3e1ed Fri Aug 11 00:00:38 CEST 2023 William Breathitt Gray <william.gray@linaro.org> gpio: idio-16: Migrate to the regmap API
The regmap API supports IO port accessors so we can take advantage of regmap abstractions rather than handling access to the device registers directly in the driver.
By leveraging the regmap API, the idio-16 library is reduced to simply a devm_idio_16_regmap_register() function and a configuration structure struct idio_16_regmap_config.
Legacy functions and code will be removed once all consumers have migrated to the new idio-16 library interface.
For IDIO-16 devices we have the following IRQ registers:
Base Address +1 (Write): Clear Interrupt Base Address +2 (Read): Enable Interrupt Base Address +2 (Write): Disable Interrupt
An interrupt is asserted whenever a change-of-state is detected on any of the inputs. Any write to 0x2 will disable interrupts, while any read will enable interrupts. Interrupts are cleared by a write to 0x1.
For 104-IDIO-16 devices, there is no IRQ status register, so software has to assume that if an interrupt is raised then it was for the 104-IDIO-16 device.
For PCI-IDIO-16 devices, there is an additional IRQ register:
Base Address +6 (Read): Interrupt Status
Interrupt status can be read from 0x6 where bit 2 set indicates that an IRQ has been generated.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/b45081958ab53dfa697f4a8b15f1bfba46718068.1680618405.git.william.gray@linaro.org/ Signed-off-by: William Breathitt Gray <william.gray@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
|
H A D | gpio-idio-16.c | diff db02247827ef2adc1617839b4bdcc5e1cef3e1ed Fri Aug 11 00:00:38 CEST 2023 William Breathitt Gray <william.gray@linaro.org> gpio: idio-16: Migrate to the regmap API
The regmap API supports IO port accessors so we can take advantage of regmap abstractions rather than handling access to the device registers directly in the driver.
By leveraging the regmap API, the idio-16 library is reduced to simply a devm_idio_16_regmap_register() function and a configuration structure struct idio_16_regmap_config.
Legacy functions and code will be removed once all consumers have migrated to the new idio-16 library interface.
For IDIO-16 devices we have the following IRQ registers:
Base Address +1 (Write): Clear Interrupt Base Address +2 (Read): Enable Interrupt Base Address +2 (Write): Disable Interrupt
An interrupt is asserted whenever a change-of-state is detected on any of the inputs. Any write to 0x2 will disable interrupts, while any read will enable interrupts. Interrupts are cleared by a write to 0x1.
For 104-IDIO-16 devices, there is no IRQ status register, so software has to assume that if an interrupt is raised then it was for the 104-IDIO-16 device.
For PCI-IDIO-16 devices, there is an additional IRQ register:
Base Address +6 (Read): Interrupt Status
Interrupt status can be read from 0x6 where bit 2 set indicates that an IRQ has been generated.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/b45081958ab53dfa697f4a8b15f1bfba46718068.1680618405.git.william.gray@linaro.org/ Signed-off-by: William Breathitt Gray <william.gray@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
|
H A D | Kconfig | diff db02247827ef2adc1617839b4bdcc5e1cef3e1ed Fri Aug 11 00:00:38 CEST 2023 William Breathitt Gray <william.gray@linaro.org> gpio: idio-16: Migrate to the regmap API
The regmap API supports IO port accessors so we can take advantage of regmap abstractions rather than handling access to the device registers directly in the driver.
By leveraging the regmap API, the idio-16 library is reduced to simply a devm_idio_16_regmap_register() function and a configuration structure struct idio_16_regmap_config.
Legacy functions and code will be removed once all consumers have migrated to the new idio-16 library interface.
For IDIO-16 devices we have the following IRQ registers:
Base Address +1 (Write): Clear Interrupt Base Address +2 (Read): Enable Interrupt Base Address +2 (Write): Disable Interrupt
An interrupt is asserted whenever a change-of-state is detected on any of the inputs. Any write to 0x2 will disable interrupts, while any read will enable interrupts. Interrupts are cleared by a write to 0x1.
For 104-IDIO-16 devices, there is no IRQ status register, so software has to assume that if an interrupt is raised then it was for the 104-IDIO-16 device.
For PCI-IDIO-16 devices, there is an additional IRQ register:
Base Address +6 (Read): Interrupt Status
Interrupt status can be read from 0x6 where bit 2 set indicates that an IRQ has been generated.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/b45081958ab53dfa697f4a8b15f1bfba46718068.1680618405.git.william.gray@linaro.org/ Signed-off-by: William Breathitt Gray <william.gray@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
|