On Thu, Dec 01, 2011 at 10:55:05PM -0800, Andres Salomon wrote: > > --- a/drivers/staging/olpc_dcon/olpc_dcon.c > > +++ b/drivers/staging/olpc_dcon/olpc_dcon.c > > @@ -755,9 +755,9 @@ static int dcon_resume(struct i2c_client *client) > > irqreturn_t dcon_interrupt(int irq, void *id) > > { > > struct dcon_priv *dcon = id; > > - int status = pdata->read_status(); > > + u8 status; > > > > - if (status == -1) > > + if (pdata->read_status(&status) == -1) > > return IRQ_NONE; It would be better to do a check for < 0 instead of -1 or even just a check for non-zero. if (pdata->read_status(&status)) return IRQ_NONE; That's more linux-ish. regards, dan carpenter
Attachment:
signature.asc
Description: Digital signature
_______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/devel