Skip to content

Commit

Permalink
tgafb: actually allocate memory for the pseudo_palette
Browse files Browse the repository at this point in the history
No memory allocation was done for the pseudo_palette.  Allocate one for it.

Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Acked-by: "Maciej W. Rozycki" <macro@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Antonino A. Daplas authored and Linus Torvalds committed Jul 17, 2007
1 parent 9965f5b commit eb3daa8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/video/tgafb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1634,7 +1634,7 @@ tgafb_register(struct device *dev)
FBINFO_HWACCEL_IMAGEBLIT | FBINFO_HWACCEL_FILLRECT;
info->fbops = &tgafb_ops;
info->screen_base = par->tga_fb_base;
info->pseudo_palette = (void *)(par + 1);
info->pseudo_palette = par->palette;

/* This should give a reasonable default video mode. */
if (tga_bus_pci) {
Expand Down
1 change: 1 addition & 0 deletions include/video/tgafb.h
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,7 @@ struct tga_par {
u32 pll_freq; /* pixclock in mhz */
u32 bits_per_pixel; /* bits per pixel */
u32 sync_on_green; /* set if sync is on green */
u32 palette[16];
};


Expand Down

0 comments on commit eb3daa8

Please sign in to comment.