Re: [PATCH] gpio: pca9570: Use I2C match data
From: Bartosz Golaszewski
Date: Fri Jun 26 2026 - 05:38:32 EST
On Wed, 24 Jun 2026 13:37:44 +0800, Pengpeng Hou wrote:
> The driver stores chip metadata in both the OF match table and the I2C
> id table, but probe currently reads it with device_get_match_data().
> That helper only returns firmware-node match data, so an I2C-id/modalias
> match can leave chip_data NULL before the driver dereferences it to read
> ngpio.
>
> Use i2c_get_match_data() so the I2C id table driver_data is consumed
> when firmware match data is not present.
>
> [...]
Applied, thanks!
[1/1] gpio: pca9570: Use I2C match data
https://git.kernel.org/brgl/c/415c63896b76fd98883e190bc7518383cb01779c
Best regards,
--
Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxxxxxxxx>