From: Peter Huewe Date: Sun, 3 Feb 2013 21:54:30 +0000 (+0100) Subject: staging/xgifb: Simplify XGI_GetRatePtrCRT2 X-Git-Tag: v3.9-rc1~127^2~152 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f2c22605c5a12c605a7164585c96f0835e9e591c;p=pandora-kernel.git staging/xgifb: Simplify XGI_GetRatePtrCRT2 Since the smaller LCDRefreshIndex is contained identically in LCDARefreshIndex we can simply use LCDARefreshIndex and skip the if/else. Since LCDARefreshIndex is only used readonly and contains only small unsigned values we also change its declaration to const u8. In order to prevent an out-of-bounds access I changed the mask from 0x0F to 0x07 and added a dummy value. Signed-off-by: Peter Huewe Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed