Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 354314
b: refs/heads/master
c: e2e544c
h: refs/heads/master
v: v3
  • Loading branch information
Peter Huewe authored and Greg Kroah-Hartman committed Feb 4, 2013
1 parent 0b2dcd6 commit e6ea496
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 12 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: 5fc699f6089913e3a691209243bf6bc2a6178ddd
refs/heads/master: e2e544c9d5c3cbdb1cefad65f40b00706034ef25
19 changes: 8 additions & 11 deletions trunk/drivers/staging/xgifb/vb_setmode.c
Original file line number Diff line number Diff line change
Expand Up @@ -638,19 +638,16 @@ static void xgifb_set_lcd(int chip_id,
unsigned short RefreshRateTableIndex,
unsigned short ModeNo)
{
unsigned short Data, Temp;
unsigned short XGI_P3cc;

XGI_P3cc = pVBInfo->P3cc;
unsigned short temp;

xgifb_reg_set(pVBInfo->P3d4, 0x2E, 0x00);
xgifb_reg_set(pVBInfo->P3d4, 0x2F, 0x00);
xgifb_reg_set(pVBInfo->P3d4, 0x46, 0x00);
xgifb_reg_set(pVBInfo->P3d4, 0x47, 0x00);

if (chip_id == XG27) {
Temp = xgifb_reg_get(pVBInfo->P3d4, 0x37);
if ((Temp & 0x03) == 0) { /* dual 12 */
temp = xgifb_reg_get(pVBInfo->P3d4, 0x37);
if ((temp & 0x03) == 0) { /* dual 12 */
xgifb_reg_set(pVBInfo->P3d4, 0x46, 0x13);
xgifb_reg_set(pVBInfo->P3d4, 0x47, 0x13);
}
Expand All @@ -659,8 +656,8 @@ static void xgifb_set_lcd(int chip_id,
if (chip_id == XG27) {
XGI_SetXG27FPBits(pVBInfo);
} else {
Temp = xgifb_reg_get(pVBInfo->P3d4, 0x37);
if (Temp & 0x01) {
temp = xgifb_reg_get(pVBInfo->P3d4, 0x37);
if (temp & 0x01) {
/* 18 bits FP */
xgifb_reg_or(pVBInfo->P3c4, 0x06, 0x40);
xgifb_reg_or(pVBInfo->P3c4, 0x09, 0x40);
Expand All @@ -672,11 +669,11 @@ static void xgifb_set_lcd(int chip_id,
xgifb_reg_and(pVBInfo->P3c4, 0x30, ~0x20); /* Hsync polarity */
xgifb_reg_and(pVBInfo->P3c4, 0x35, ~0x80); /* Vsync polarity */

Data = XGI330_RefIndex[RefreshRateTableIndex].Ext_InfoFlag;
if (Data & 0x4000)
temp = XGI330_RefIndex[RefreshRateTableIndex].Ext_InfoFlag;
if (temp & 0x4000)
/* Hsync polarity */
xgifb_reg_or(pVBInfo->P3c4, 0x30, 0x20);
if (Data & 0x8000)
if (temp & 0x8000)
/* Vsync polarity */
xgifb_reg_or(pVBInfo->P3c4, 0x35, 0x80);
}
Expand Down

0 comments on commit e6ea496

Please sign in to comment.