Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 54869
b: refs/heads/master
c: 125e113
h: refs/heads/master
i:
  54867: 3841bb1
v: v3
  • Loading branch information
Witold Filipczyk authored and Linus Torvalds committed May 8, 2007
1 parent 0b484a3 commit f941f7f
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 10 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: c8e1693a4f63e317966f3dfe8f815eda95e26610
refs/heads/master: 125e1137cd2d93377028f521801d916729485733
29 changes: 20 additions & 9 deletions trunk/drivers/video/aty/aty128fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -2165,18 +2165,29 @@ static void __devexit aty128_remove(struct pci_dev *pdev)
static int aty128fb_blank(int blank, struct fb_info *fb)
{
struct aty128fb_par *par = fb->par;
u8 state = 0;
u8 state;

if (par->lock_blank || par->asleep)
return 0;

if (blank & FB_BLANK_VSYNC_SUSPEND)
state |= 2;
if (blank & FB_BLANK_HSYNC_SUSPEND)
state |= 1;
if (blank & FB_BLANK_POWERDOWN)
state |= 4;

switch (blank) {
case FB_BLANK_NORMAL:
state = 4;
break;
case FB_BLANK_VSYNC_SUSPEND:
state = 6;
break;
case FB_BLANK_HSYNC_SUSPEND:
state = 5;
break;
case FB_BLANK_POWERDOWN:
state = 7;
break;
case FB_BLANK_UNBLANK:
default:
state = 0;
break;
}
aty_st_8(CRTC_EXT_CNTL+1, state);

if (par->chip_gen == rage_M3) {
Expand Down Expand Up @@ -2430,7 +2441,7 @@ static int aty128_pci_suspend(struct pci_dev *pdev, pm_message_t state)
wait_for_idle(par);

/* Blank display and LCD */
aty128fb_blank(VESA_POWERDOWN, info);
aty128fb_blank(FB_BLANK_POWERDOWN, info);

/* Sleep */
par->asleep = 1;
Expand Down

0 comments on commit f941f7f

Please sign in to comment.