Re: Question on struct fb_videomode.name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 26, 2011 at 22:55, Timur Tabi <timur@xxxxxxxxxxxxx> wrote:
> In my fb driver, I have an array of fb_videomode structs, like this:
>
> static struct fb_videomode __devinitdata fsl_diu_mode_db[] = {
>        {
>                .name           = "1024x768-60",
>                .refresh        = 60,
>                .xres           = 1024,
>                .yres           = 768,
>                .pixclock       = 15385,
>                .left_margin    = 160,
>                .right_margin   = 24,
>                .upper_margin   = 29,
>                .lower_margin   = 3,
>                .hsync_len      = 136,
>                .vsync_len      = 6,
>                .sync           = FB_SYNC_COMP_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
>                .vmode          = FB_VMODE_NONINTERLACED
>        },
>        ...
>
> Is there any value in specifying the .name field as "<xres>x<yres>-<ref>"?  I
> know the .name field is optional, but what happens if I don't specify it?  It
> just seems redundant to generate the name based on other data in the same structure.

If the name is just "<xres>x<yres>-<ref>", you can leave it NULL.
The name only adds value if it's something different, cfr. the modes
in macmodes.c,
amifb.c, or ps3fb.c.

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
��.n��������+%������w��{.n�����{����n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�

[Index of Archives]     [Video for Linux]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Tourism]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux