[PATCH 09/17] staging: xgifb: SetFlag: delete EnableChB
dan.carpenter at oracle.com
Mon Apr 1 12:22:35 UTC 2013
On Mon, Apr 01, 2013 at 02:41:30PM +0300, Aaro Koskinen wrote:
> On Mon, Apr 01, 2013 at 01:30:47PM +0300, Dan Carpenter wrote:
> > On Sat, Mar 30, 2013 at 11:18:05PM +0200, Aaro Koskinen wrote:
> > > @@ -4582,12 +4582,6 @@ static unsigned char XGI_EnableChISLCD(struct vb_device_info *pVBInfo,
> > > return 0;
> > > }
> > >
> > > - if (!(tempbx & EnableChB))
> > > - return 0;
> > > -
> > > - if (tempah & 0x01) /* Chk LCDB Mode */
> > > - return 1;
> > I don't understand why this return is deleted.
> Because EnableChB was never set in tempbx, the code took always the
> "return 0" path and the remaing code was unreachable. So we have to
> delete it too, otherwise there would be a change in functionality.
Ah, right. I misread that. I thought we never took the first
return but we always take it. Sorry for the noise.
More information about the devel