Home Home > GIT Browse
diff options
authorAdam Kropelin <akropel1@rochester.rr.com>2004-06-06 05:59:45 -0700
committerDavid S. Miller <davem@kernel.bkbits.net>2004-06-06 05:59:45 -0700
commit55a92a2bbd294863d2b820816ac1cfb40eafddae (patch)
parent31c577a150b2778eb550fe1ec8b42d229cb01a70 (diff)
[FB]: Fix uninitialized fb_cmap member in sbuslib.c
When handling FBIOPUTCMAP_SPARC, sbusfb fails to initialize cmap.transp, which quickly leads to an oops when fb_set_cmap() dereferences it. First encountered in Aurora Wombat kernels and seems to afflict mainline as well. Patch is against 2.6.7-rc2. xorg still fails to actually get anything to display on my CG6, but at least it no longer oopses the kernel. Signed-off-by: Adam Kropelin <akropel1@rochester.rr.com> Signed-off-by: David S. Miller <davem@redhat.com>
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/video/sbuslib.c b/drivers/video/sbuslib.c
index a09be527d759..c1ab754d38c6 100644
--- a/drivers/video/sbuslib.c
+++ b/drivers/video/sbuslib.c
@@ -122,6 +122,7 @@ int sbusfb_ioctl_helper(unsigned long cmd, unsigned long arg,
cmap.red = &red;
cmap.green = &green;
cmap.blue = &blue;
+ cmap.transp = NULL;
for (i = 0; i < count; i++) {
int err;