Re: [PATCH] media: mali-c55: add padding to mali_c55_params_ccm structure

From: Jacopo Mondi

Date: Wed Sep 30 2026 - 04:42:27 EST


Hi Arnd

On Tue, Sep 15, 2026 at 10:24:48PM +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@xxxxxxxx>
>
> The newly added structure has extra padding on the on
> some architectures, which triggers a pedantic uapi check:
>
> ./usr/include/linux/media/arm/mali-c55-config.h:807:1: error: padding struct size to alignment boundary with 2 bytes [-Werror=padded]
>
> Add explicit padding here to avoid risking information leaks
> and incompatibilities between architectures.
>
> Fixes: bb401df68c06 ("media: mali-c55: Add support for CCM")
> Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>

The documentation of the newly added field is missing, triggering a
warning when building the documentation

https://gitlab.freedesktop.org/linux-media/users/patchwork/-/jobs/110343884
WARNING: ./include/uapi/linux/media/arm/mali-c55-config.h:803 struct member '__pad' not described in 'mali_c55_params_ccm'

I am about to send a PR collecting all mali-related changes, I can add

* @__pad: Padding bytes

To the documentation of struct mali_c55_params_ccm.

> ---
> include/uapi/linux/media/arm/mali-c55-config.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/include/uapi/linux/media/arm/mali-c55-config.h b/include/uapi/linux/media/arm/mali-c55-config.h
> index 84d8f3901405..9c922290e035 100644
> --- a/include/uapi/linux/media/arm/mali-c55-config.h
> +++ b/include/uapi/linux/media/arm/mali-c55-config.h
> @@ -804,6 +804,7 @@ struct mali_c55_params_ccm {
> __u16 coeffs[3][3];
> __u16 gains[3];
> __u16 offs[3];
> + __u16 __pad;
> };
>
> /**
> --
> 2.53.0
>
>