Re: [PATCH V5 3/6] drivers/auxdisplay: sensehat: Raspberry Pi Sense HAT display driver

From: Miguel Ojeda
Date: Sat Dec 11 2021 - 13:38:49 EST


Hi Charles, Mwesigwa, Joel, Serge,

On Fri, Dec 10, 2021 at 11:11 PM Charles Mirabile <cmirabil@xxxxxxxxxx> wrote:
>
> Signed-off-by: Charles Mirabile <cmirabil@xxxxxxxxxx>
> Co-developed-by: Mwesigwa Guma <mguma@xxxxxxxxxx>
> Signed-off-by: Mwesigwa Guma <mguma@xxxxxxxxxx>
> Co-developed-by: Joel Savitz <jsavitz@xxxxxxxxxx>
> Signed-off-by: Joel Savitz <jsavitz@xxxxxxxxxx>

The "submitting author" should be the last one, i.e.:

Co-developed-by: Mwesigwa Guma <mguma@xxxxxxxxxx>
Signed-off-by: Mwesigwa Guma <mguma@xxxxxxxxxx>
Co-developed-by: Joel Savitz <jsavitz@xxxxxxxxxx>
Signed-off-by: Joel Savitz <jsavitz@xxxxxxxxxx>
Signed-off-by: Charles Mirabile <cmirabil@xxxxxxxxxx>

> +config SENSEHAT_DISPLAY
> + tristate "Raspberry pi Sense HAT display driver"

pi -> Pi

> +static int sensehat_update_display(struct sensehat *sensehat);

Can the function be directly defined instead?

> + if (*f_pos >= VMEM_SIZE)
> + return 0;
> + if (*f_pos + count > VMEM_SIZE)
> + count = VMEM_SIZE - *f_pos;

`min` / `min_t`?

> + if (ret < 0)
> + dev_err(sensehat->dev,
> + "Update to 8x8 LED matrix display failed");

Could this happen a lot of times? Is it expected to happen under some
condition or should never happen?

Cheers,
Miguel