diff options
author | Aaro Koskinen <aaro.koskinen@iki.fi> | 2013-05-29 23:59:10 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-05-30 20:55:51 +0900 |
commit | a2526d1f3218dc68aca0e3bcc210b34ce6993216 (patch) | |
tree | c7c8b8da1a3b80af9f401807395aafa24122ea0b /drivers/staging/xgifb | |
parent | d1724637e1b33dd4f53c1d75d6f5e22a7c8a2f5c (diff) | |
download | linux-a2526d1f3218dc68aca0e3bcc210b34ce6993216.tar.bz2 |
staging: xgifb: SetFlag: delete EnableChA
This flag is never set, so checks can be removed and code behind it
deleted.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/xgifb')
-rw-r--r-- | drivers/staging/xgifb/vb_def.h | 1 | ||||
-rw-r--r-- | drivers/staging/xgifb/vb_setmode.c | 21 |
2 files changed, 3 insertions, 19 deletions
diff --git a/drivers/staging/xgifb/vb_def.h b/drivers/staging/xgifb/vb_def.h index 6bc20e9803df..5c739bebd8a5 100644 --- a/drivers/staging/xgifb/vb_def.h +++ b/drivers/staging/xgifb/vb_def.h @@ -30,7 +30,6 @@ #define SetCRT2ToDualEdge 0x8000 #define ReserveTVOption 0x0008 -#define EnableChA 0x8000 #define SetTVLowResolution 0x0400 #define TVSimuMode 0x0800 diff --git a/drivers/staging/xgifb/vb_setmode.c b/drivers/staging/xgifb/vb_setmode.c index 41f29a3821dc..8c55ebe7c5a9 100644 --- a/drivers/staging/xgifb/vb_setmode.c +++ b/drivers/staging/xgifb/vb_setmode.c @@ -4552,18 +4552,9 @@ static unsigned char XGI_EnableChISLCD(struct vb_device_info *pVBInfo, { unsigned short tempbx, tempah; - if (enable) - tempbx = pVBInfo->SetFlag & EnableChA; - else - tempbx = 0; - + tempbx = 0; tempah = ~((unsigned short) xgifb_reg_get(pVBInfo->Part1Port, 0x2E)); - if (tempbx & EnableChA) { - if (!(tempah & 0x08)) /* Chk LCDA Mode */ - return 0; - } - return 0; } @@ -5463,11 +5454,9 @@ static void XGI_EnableBridge(struct xgifb_video_info *xgifb_info, if (pVBInfo->VBType & (VB_SIS301B | VB_SIS302B | VB_SIS301LV | VB_SIS302LV | VB_XGI301C)) { - if ((pVBInfo->SetFlag & EnableChA) || - (pVBInfo->VBInfo & SetCRT2ToDualEdge)) { + if (pVBInfo->VBInfo & SetCRT2ToDualEdge) /* Power on */ xgifb_reg_set(pVBInfo->Part1Port, 0x1E, 0x20); - } if (pVBInfo->VBInfo & (SetCRT2ToLCD | SetCRT2ToTV | SetCRT2ToRAMDAC)) { @@ -5487,8 +5476,7 @@ static void XGI_EnableBridge(struct xgifb_video_info *xgifb_info, xgifb_reg_and(pVBInfo->Part1Port, 0x00, 0x7F); } - if ((pVBInfo->SetFlag & EnableChA) - || (!(pVBInfo->VBInfo & DisableCRT2Display))) { + if (!(pVBInfo->VBInfo & DisableCRT2Display)) { xgifb_reg_and_or(pVBInfo->Part2Port, 0x00, ~0xE0, 0x20); /* shampoo 0129 */ if (pVBInfo->VBType & (VB_SIS302LV | VB_XGI301C)) { @@ -5518,9 +5506,6 @@ static void XGI_EnableBridge(struct xgifb_video_info *xgifb_info, tempah = tempah & 0x40; if (pVBInfo->VBInfo & XGI_SetCRT2ToLCDA) tempah = tempah ^ 0xC0; - - if (pVBInfo->SetFlag & EnableChA) - tempah |= 0x80; } } |