Re: [PATCH 1/5] fbcmap.c: mark structs const or __read_mostly
flat view
From: Geert Uytterhoeven <geert@linux-m68k.org>
Date: 2006-09-14 20:42:23
On Thu, 14 Sep 2006, Helge Deller wrote:
- Add named initializers in fb_cmap structs and use the ARRAY_SIZE() macro
quoted hunk ↗ jump to hunk
-static struct fb_cmap default_2_colors = { - 0, 2, red2, green2, blue2, NULL +static const struct fb_cmap default_2_colors = { + len:2, red:red2, green:green2, blue:blue2 }; -static struct fb_cmap default_8_colors = { - 0, 8, red8, green8, blue8, NULL +static const struct fb_cmap default_8_colors = { + len:8, red:red8, green:green8, blue:blue8 }; -static struct fb_cmap default_4_colors = { - 0, 4, red4, green4, blue4, NULL +static const struct fb_cmap default_4_colors = { + len:4, red:red4, green:green4, blue:blue4 }; -static struct fb_cmap default_16_colors = { - 0, 16, red16, green16, blue16, NULL +static const struct fb_cmap default_16_colors = { + len:16, red:red16, green:green16, blue:blue16 };
Please use the C99 variant instead of the obsolete GNU variant.
Gr{oetje,eeting}s,
Geert
P.S. Please inline your patches, to facilitate adding review comments.
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
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
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642