Re: [PATCH 20/21] staging: xgifb: use correct type for VBVCLKData

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 11, 2012 at 12:15:31AM +0300, Aaro Koskinen wrote:
> Use correct type to eliminate casting.
> 
> Signed-off-by: Aaro Koskinen <aaro.koskinen@xxxxxx>
> ---
>  drivers/staging/xgifb/vb_setmode.c |    6 +++---
>  drivers/staging/xgifb/vb_table.h   |    2 +-
>  2 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/staging/xgifb/vb_setmode.c b/drivers/staging/xgifb/vb_setmode.c
> index 0ed8036..ef8775e 100644
> --- a/drivers/staging/xgifb/vb_setmode.c
> +++ b/drivers/staging/xgifb/vb_setmode.c
> @@ -32,7 +32,7 @@ void InitTo330Pointer(unsigned char ChipType, struct vb_device_info *pVBInfo)
>  	pVBInfo->MCLKData = (struct SiS_MCLKData *) XGI340New_MCLKData;
>  	pVBInfo->ECLKData = (struct XGI_ECLKDataStruct *) XGI340_ECLKData;
>  	pVBInfo->VCLKData = (struct SiS_VCLKData *) XGI_VCLKData;
> -	pVBInfo->VBVCLKData = (struct SiS_VBVCLKData *) XGI_VBVCLKData;
> +	pVBInfo->VBVCLKData = XGI_VBVCLKData;
>  	pVBInfo->ScreenOffset = XGI330_ScreenOffset;
>  	pVBInfo->StResInfo = (struct SiS_StResInfo_S *) XGI330_StResInfo;
>  	pVBInfo->ModeResInfo
> @@ -2276,8 +2276,8 @@ static void XGI_GetVCLKLen(unsigned char tempal, unsigned char *di_0,
>  			| VB_SIS301LV | VB_SIS302LV | VB_XGI301C)) {
>  		if ((!(pVBInfo->VBInfo & XGI_SetCRT2ToLCDA)) &&
>  		    (pVBInfo->SetFlag & ProgrammingCRT2)) {
> -			*di_0 = (unsigned char) XGI_VBVCLKData[tempal].SR2B;
> -			*di_1 = XGI_VBVCLKData[tempal].SR2C;
> +			*di_0 = XGI_VBVCLKData[tempal].Part4_A;
> +			*di_1 = XGI_VBVCLKData[tempal].Part4_C;

This should have been:

			*di_1 = XGI_VBVCLKData[tempal].Part4_B;

but you silently fix that bug in the next patch...  Sloppy.

But other than that this patchset does is very nice.

regards,
dan carpenter


_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux