Re: [PATCH v1 1/2] gpio: mpfs: add CoreGPIO support

From: Bartosz Golaszewski
Date: Sun Nov 10 2024 - 14:08:42 EST


On Thu, Nov 7, 2024 at 11:33 AM Conor Dooley <conor@xxxxxxxxxx> wrote:
>
> From: Conor Dooley <conor.dooley@xxxxxxxxxxxxx>
>
> coreGPIO, which the "hard" core in PolarFire SoC is based on, has
> different offsets for inp/outp. Add some match_data handling to account
> for the differences.
>
> Signed-off-by: Conor Dooley <conor.dooley@xxxxxxxxxxxxx>
> ---
> drivers/gpio/gpio-mpfs.c | 38 +++++++++++++++++++++++++++++++++-----
> 1 file changed, 33 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpio/gpio-mpfs.c b/drivers/gpio/gpio-mpfs.c
> index 3718121eb97a..4aefae05a9fb 100644
> --- a/drivers/gpio/gpio-mpfs.c
> +++ b/drivers/gpio/gpio-mpfs.c
> @@ -10,6 +10,7 @@
> #include <linux/errno.h>
> #include <linux/gpio/driver.h>
> #include <linux/init.h>
> +#include <linux/of_device.h>

You don't need this. Include property.h and use device_get_match_data() instead.

Bart