Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 60916
b: refs/heads/master
c: 000d533
h: refs/heads/master
v: v3
  • Loading branch information
Antonino A. Daplas authored and Linus Torvalds committed Jul 17, 2007
1 parent fb70302 commit fd88824
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c312f97df65bf38a8e7f664b76154639f593775d
refs/heads/master: 000d5335c6e7f5dbcd849b62b4be7ae005aa6974
2 changes: 1 addition & 1 deletion trunk/drivers/video/sis/sis.h
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ struct sis_video_info {
struct fb_var_screeninfo default_var;

struct fb_fix_screeninfo sisfb_fix;
u32 pseudo_palette[17];
u32 pseudo_palette[16];

struct sisfb_monitor {
u16 hmin;
Expand Down
6 changes: 6 additions & 0 deletions trunk/drivers/video/sis/sis_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1405,12 +1405,18 @@ sisfb_setcolreg(unsigned regno, unsigned red, unsigned green, unsigned blue,
}
break;
case 16:
if (regno >= 16)
break;

((u32 *)(info->pseudo_palette))[regno] =
(red & 0xf800) |
((green & 0xfc00) >> 5) |
((blue & 0xf800) >> 11);
break;
case 32:
if (regno >= 16)
break;

red >>= 8;
green >>= 8;
blue >>= 8;
Expand Down

0 comments on commit fd88824

Please sign in to comment.