frank-zago / ch341-i2c-spi-gpio

WinChipHead CH341 linux driver for I2C, SPI and GPIO mode
GNU General Public License v2.0
70 stars 29 forks source link

Enable compile for 5.x Linux kernel #17

Closed mskalski closed 1 year ago

mskalski commented 1 year ago

For pre-6 Linux kernel use definitions of devm_i2c_add_adapter() introduced in 5.13 Linux kernel - copied verbatim

Also macros for GPIOCHIP_IRQ_RESOURCE_HELPERS and gpio_irq_chip_set_chip() and IRQCHIP_IMMUTABLE which were introduced in 5.19 kernel are defined

mskalski commented 1 year ago

Succesfully compiles (and works) on 5.4 kernel (Ubuntu 18.04)

frank-zago commented 1 year ago

Sounds raisonnable. Thanks.