On Wed, Feb 2, 2022 at 10:25 AM Thomas Zimmermann <[email protected]> wrote:
> Am 31.01.22 um 22:05 schrieb Daniel Vetter:
> > It's only one flag and slightly tidier code.
> >
> > Signed-off-by: Daniel Vetter <[email protected]>
> > Cc: Daniel Vetter <[email protected]>
> > Cc: Tetsuo Handa <[email protected]>
> > Cc: Greg Kroah-Hartman <[email protected]>
> > Cc: Du Cheng <[email protected]>
> > Cc: Thomas Zimmermann <[email protected]>
> > Cc: Claudio Suarez <[email protected]>
>
> Acked-by: Thomas Zimmermann <[email protected]>

> > +++ b/drivers/video/fbdev/core/fbcon.h
> > @@ -18,8 +18,6 @@
> >
> >   #include <asm/io.h>
> >
> > -#define FBCON_FLAGS_INIT         1
> > -
> >      /*
> >       *    This is the interface between the low-level console driver and 
> > the
> >       *    low-level frame buffer device
> > @@ -77,7 +75,7 @@ struct fbcon_ops {
> >       int    blank_state;
> >       int    graphics;
> >       int    save_graphics; /* for debug enter/leave */
> > -     int    flags;
> > +     bool   initialized;
>
> This will add 3 bytes of padding. Maybe you can put the bool elsewhere.

Several of the int variables are used as boolean flags, too.
Perhaps convert them all to bitfields?

    unsigned int initialized : 1;
    ...

> >       int    rotate;
> >       int    cur_rotate;
> >       char  *cursor_data;

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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

Reply via email to