Re: [PATCH 1/2] drm/etnaviv: etnaviv_fence: Put base class first
From: Christian König
Date: Wed Oct 28 2026 - 06:34:27 EST
On 10/28/26 11:31, Philipp Stanner wrote:
> struct etnaviv_fence contains a struct dma_fence, which is its base
> class. The base class should always be the first member of a class.
>
> This allows for removing a deprecated callback in a subsequent patch.
>
> Make struct dma_fence base the first member of struct etnaviv_fence.
>
> Signed-off-by: Philipp Stanner <phasta@xxxxxxxxxx>
Reviewed-by: Christian König <christian.koenig@xxxxxxx> for both patches.
> ---
> drivers/gpu/drm/etnaviv/etnaviv_gpu.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
> index 5c23182f4d33..e51a310c8d70 100644
> --- a/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
> +++ b/drivers/gpu/drm/etnaviv/etnaviv_gpu.c
> @@ -1148,8 +1148,8 @@ int etnaviv_gpu_debugfs(struct etnaviv_gpu *gpu, struct seq_file *m)
>
> /* fence object management */
> struct etnaviv_fence {
> - struct etnaviv_gpu *gpu;
> struct dma_fence base;
> + struct etnaviv_gpu *gpu;
> };
>
> static inline struct etnaviv_fence *to_etnaviv_fence(struct dma_fence *fence)
>
> base-commit: 731ba09867520c047c7de53f92e384808e0b638e