Re: [PATCH v4 2/5] drm/imagination: Limit access to the RISC-V firmware interface

From: Geert Uytterhoeven

Date: Wed Nov 25 2026 - 03:47:38 EST


Hi Alexandru,

On Tue, 3 Nov 2026 at 10:01, Alexandru Dadu <alexandru.dadu@xxxxxxxxxx> wrote:
> From: Alessio Belle <alessio.belle@xxxxxxxxxx>
>
> - Rename the RISC-V firmware processor header adding an "internal"
> suffix.
> - Add guard to the RISC-V firmware processor header to prevent
> accidental inclusion outside of the RISC-V firmware specific logic.
>
> Signed-off-by: Alessio Belle <alessio.belle@xxxxxxxxxx>
> Signed-off-by: Alexandru Dadu <alexandru.dadu@xxxxxxxxxx>

Thanks for your patch, which is now commit 2f42457ad97a6d32
("drm/imagination: Limit access to the RISC-V firmware interface")
in drm-misc/for-linux-next.

> --- a/drivers/gpu/drm/imagination/pvr_fw_riscv.c
> +++ b/drivers/gpu/drm/imagination/pvr_fw_riscv.c
> @@ -7,7 +7,9 @@
> #include "pvr_fw_mips.h"
> #include "pvr_gem.h"
> #include "pvr_rogue_cr_defs.h"
> -#include "pvr_rogue_riscv.h"
> +#define PVR_ROGUE_RISCV_INTERNAL_H_EXPLICIT_INCLUDE
> +#include "pvr_rogue_riscv_internal.h"
> +#undef PVR_ROGUE_RISCV_INTERNAL_H_EXPLICIT_INCLUDE

Really? IMHO that is very ugly.

> #include "pvr_vm.h"
>
> #include <linux/compiler.h>

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds