Commit df5d4312 authored by Walt Feasel's avatar Walt Feasel Committed by Greg Kroah-Hartman

staging: xgifb: vb_setmode.c Align match parenthesis

Make suggested checkpatch modification for
CHECK: Alignment should match open parenthesis
Signed-off-by: default avatarWalt Feasel <waltfeasel@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent cf99b357
......@@ -167,7 +167,8 @@ static unsigned char XGI_SetDefaultVCLK(struct vb_device_info *pVBInfo)
}
static unsigned char XGI_AjustCRT2Rate(unsigned short ModeIdIndex,
unsigned short RefreshRateTableIndex, unsigned short *i,
unsigned short RefreshRateTableIndex,
unsigned short *i,
struct vb_device_info *pVBInfo)
{
unsigned short tempax, tempbx, resinfo, modeflag, infoflag;
......@@ -1480,17 +1481,14 @@ static void XGI_SetLVDSRegs(unsigned short ModeIdIndex,
if (tempcx >= tempax)
tempcx -= tempax;
xgifb_reg_set(pVBInfo->Part1Port, 0x1b,
(unsigned short)(tempbx & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x1c,
(unsigned short)(tempcx & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x1b, (unsigned short)(tempbx & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x1c, (unsigned short)(tempcx & 0xff));
tempbx = (tempbx >> 8) & 0x07;
tempcx = (tempcx >> 8) & 0x07;
xgifb_reg_set(pVBInfo->Part1Port, 0x1d,
(unsigned short)((tempcx << 3)
| tempbx));
xgifb_reg_set(pVBInfo->Part1Port, 0x1d, (unsigned short)((tempcx << 3) |
tempbx));
tempax = pVBInfo->VT;
tempbx = LCDPtr1->LCDVRS;
......@@ -1504,10 +1502,8 @@ static void XGI_SetLVDSRegs(unsigned short ModeIdIndex,
if (tempcx >= tempax)
tempcx -= tempax;
xgifb_reg_set(pVBInfo->Part1Port, 0x18,
(unsigned short)(tempbx & 0xff));
xgifb_reg_and_or(pVBInfo->Part1Port, 0x19, ~0x0f,
(unsigned short)(tempcx & 0x0f));
xgifb_reg_set(pVBInfo->Part1Port, 0x18, (unsigned short)(tempbx & 0xff));
xgifb_reg_and_or(pVBInfo->Part1Port, 0x19, ~0x0f, (unsigned short)(tempcx & 0x0f));
tempax = ((tempbx >> 8) & 0x07) << 3;
......@@ -1518,8 +1514,7 @@ static void XGI_SetLVDSRegs(unsigned short ModeIdIndex,
if (pVBInfo->LCDInfo & XGI_EnableLVDSDDA)
tempax |= 0x40;
xgifb_reg_and_or(pVBInfo->Part1Port, 0x1a, 0x07,
tempax);
xgifb_reg_and_or(pVBInfo->Part1Port, 0x1a, 0x07, tempax);
tempbx = pVBInfo->VDE;
tempax = pVBInfo->VGAVDE;
......@@ -1535,10 +1530,8 @@ static void XGI_SetLVDSRegs(unsigned short ModeIdIndex,
temp2 = temp1;
push3 = temp2;
xgifb_reg_set(pVBInfo->Part1Port, 0x37,
(unsigned short)(temp2 & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x36,
(unsigned short)((temp2 >> 8) & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x37, (unsigned short)(temp2 & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x36, (unsigned short)((temp2 >> 8) & 0xff));
tempbx = (unsigned short)(temp2 >> 16);
tempax = tempbx & 0x03;
......@@ -1559,18 +1552,14 @@ static void XGI_SetLVDSRegs(unsigned short ModeIdIndex,
(unsigned short)((temp2 >> 8) &
0xff));
tempbx = (unsigned short)(temp2 >> 16);
xgifb_reg_and_or(pVBInfo->Part4Port, 0x3a,
~0xc0,
(unsigned short)((tempbx &
0xff) << 6));
xgifb_reg_and_or(pVBInfo->Part4Port, 0x3a, ~0xc0,
(unsigned short)((tempbx & 0xff) << 6));
tempcx = pVBInfo->VGAVDE;
if (tempcx == pVBInfo->VDE)
xgifb_reg_and_or(pVBInfo->Part4Port,
0x30, ~0x0c, 0x00);
xgifb_reg_and_or(pVBInfo->Part4Port, 0x30, ~0x0c, 0x00);
else
xgifb_reg_and_or(pVBInfo->Part4Port,
0x30, ~0x0c, 0x08);
xgifb_reg_and_or(pVBInfo->Part4Port, 0x30, ~0x0c, 0x08);
}
tempcx = pVBInfo->VGAHDE;
......@@ -1604,20 +1593,16 @@ static void XGI_SetLVDSRegs(unsigned short ModeIdIndex,
tempax = ((tempbx >> 8) & 0xff) << 3;
tempax |= (unsigned short)((temp3 >> 8) & 0x07);
xgifb_reg_set(pVBInfo->Part1Port, 0x20,
(unsigned short)(tempax & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x21,
(unsigned short)(tempbx & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x20, (unsigned short)(tempax & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x21, (unsigned short)(tempbx & 0xff));
temp3 >>= 16;
if (modeflag & HalfDCLK)
temp3 >>= 1;
xgifb_reg_set(pVBInfo->Part1Port, 0x22,
(unsigned short)((temp3 >> 8) & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x23,
(unsigned short)(temp3 & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x22, (unsigned short)((temp3 >> 8) & 0xff));
xgifb_reg_set(pVBInfo->Part1Port, 0x23, (unsigned short)(temp3 & 0xff));
}
/*
......@@ -1645,7 +1630,8 @@ static void XGI_GetLCDVCLKPtr(unsigned char *di_0, unsigned char *di_1,
}
static unsigned char XGI_GetVCLKPtr(unsigned short RefreshRateTableIndex,
unsigned short ModeIdIndex, struct vb_device_info *pVBInfo)
unsigned short ModeIdIndex,
struct vb_device_info *pVBInfo)
{
unsigned short index, modeflag;
unsigned char tempal;
......@@ -1871,8 +1857,7 @@ void XGI_GetVBType(struct vb_device_info *pVBInfo)
pVBInfo->VBType = tempbx;
}
static void XGI_GetVBInfo(unsigned short ModeIdIndex,
struct vb_device_info *pVBInfo)
static void XGI_GetVBInfo(unsigned short ModeIdIndex, struct vb_device_info *pVBInfo)
{
unsigned short tempax, push, tempbx, temp, modeflag;
......@@ -1997,8 +1982,7 @@ static void XGI_GetVBInfo(unsigned short ModeIdIndex,
pVBInfo->VBInfo = tempbx;
}
static void XGI_GetTVInfo(unsigned short ModeIdIndex,
struct vb_device_info *pVBInfo)
static void XGI_GetTVInfo(unsigned short ModeIdIndex, struct vb_device_info *pVBInfo)
{
unsigned short tempbx = 0, resinfo = 0, modeflag, index1;
......@@ -3650,8 +3634,7 @@ static void XGI_SetGroup2(unsigned short ModeNo, unsigned short ModeIdIndex,
}
}
static void XGI_SetLCDRegs(unsigned short ModeIdIndex,
struct vb_device_info *pVBInfo)
static void XGI_SetLCDRegs(unsigned short ModeIdIndex, struct vb_device_info *pVBInfo)
{
unsigned short pushbx, tempax, tempbx, tempcx, temp, tempah,
tempbh, tempch;
......@@ -4126,8 +4109,7 @@ static void XGI_SetGroup4(unsigned short ModeIdIndex,
| TVSetHiVision))) {
temp |= 0x0001;
if ((pVBInfo->VBInfo & SetInSlaveMode) &&
!(pVBInfo->TVInfo
& TVSimuMode))
!(pVBInfo->TVInfo & TVSimuMode))
temp &= (~0x0001);
}
}
......@@ -4168,7 +4150,8 @@ static void XGI_DisableGatingCRT(struct vb_device_info *pVBInfo)
}
static unsigned char XGI_XG21CheckLVDSMode(struct xgifb_video_info *xgifb_info,
unsigned short ModeNo, unsigned short ModeIdIndex)
unsigned short ModeNo,
unsigned short ModeIdIndex)
{
unsigned short xres, yres, colordepth, modeflag, resindex;
......@@ -4652,12 +4635,11 @@ static void XGI_SetLCDCap_B(unsigned short tempcx,
{
if (tempcx & EnableLCD24bpp) /* 24bits */
xgifb_reg_and_or(pVBInfo->Part2Port, 0x1A, 0xE0,
(unsigned short)(((tempcx & 0x00ff) >> 6)
| 0x0c));
(unsigned short)(((tempcx & 0x00ff) >> 6) | 0x0c));
else
xgifb_reg_and_or(pVBInfo->Part2Port, 0x1A, 0xE0,
(unsigned short)(((tempcx & 0x00ff) >> 6)
| 0x18)); /* Enable Dither */
(unsigned short)(((tempcx & 0x00ff) >> 6) | 0x18));
/* Enable Dither */
}
static void XGI_LongWait(struct vb_device_info *pVBInfo)
......@@ -4720,8 +4702,8 @@ static void XGI_SetLCDCap(struct vb_device_info *pVBInfo)
/* VB Driving */
xgifb_reg_and_or(pVBInfo->Part4Port, 0x0D,
~((EnableVBCLKDRVLOW | EnablePLLSPLOW) >> 8),
(unsigned short)((tempcx & (EnableVBCLKDRVLOW
| EnablePLLSPLOW)) >> 8));
(unsigned short)((tempcx & (EnableVBCLKDRVLOW |
EnablePLLSPLOW)) >> 8));
if (pVBInfo->VBInfo & SetCRT2ToLCD)
XGI_SetLCDCap_B(tempcx, pVBInfo);
......@@ -5062,7 +5044,8 @@ void XGI_LockCRT2(struct vb_device_info *pVBInfo)
}
unsigned short XGI_GetRatePtrCRT2(struct xgi_hw_device_info *pXGIHWDE,
unsigned short ModeNo, unsigned short ModeIdIndex,
unsigned short ModeNo,
unsigned short ModeIdIndex,
struct vb_device_info *pVBInfo)
{
const u8 LCDARefreshIndex[] = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment