[PATCH] drm/bridge: Constify struct i2c_device_id
Doug Anderson
dianders at chromium.org
Wed Nov 20 23:18:08 UTC 2024
Hi,
On Tue, Nov 12, 2024 at 1:12 PM Christophe JAILLET
<christophe.jaillet at wanadoo.fr> wrote:
>
> 'struct i2c_device_id' is not modified in these drivers.
>
> Constifying this structure moves some data to a read-only section, so
> increase overall security.
>
> On a x86_64, with allmodconfig, as an example:
> Before:
> ======
> text data bss dec hex filename
> 15566 987 32 16585 40c9 drivers/gpu/drm/bridge/chipone-icn6211.o
>
> After:
> =====
> text data bss dec hex filename
> 15630 923 32 16585 40c9 drivers/gpu/drm/bridge/chipone-icn6211.o
>
> Signed-off-by: Christophe JAILLET <christophe.jaillet at wanadoo.fr>
> ---
> Compile tested-only.
> ---
> drivers/gpu/drm/bridge/chipone-icn6211.c | 2 +-
> drivers/gpu/drm/bridge/lontium-lt9211.c | 2 +-
> drivers/gpu/drm/bridge/lontium-lt9611.c | 2 +-
> drivers/gpu/drm/bridge/lontium-lt9611uxc.c | 2 +-
> drivers/gpu/drm/bridge/ti-sn65dsi83.c | 2 +-
> drivers/gpu/drm/bridge/ti-sn65dsi86.c | 2 +-
> 6 files changed, 6 insertions(+), 6 deletions(-)
I figured it didn't hurt if I just pushed this so I did. Now in drm-misc-next:
[1/1] drm/bridge: Constify struct i2c_device_id
commit: dbf7986f8a56ce47465bb6e0f2b2d166b931d707
-Doug
More information about the dri-devel
mailing list