Message ID | 20151112094338.GB28432@mwanda (mailing list archive) |
---|---|
State | Accepted, archived |
Headers | show |
On Thu, 2015-11-12 at 12:43 +0300, Dan Carpenter wrote: > HPSA_DIAG_OPTS_DISABLE_RLD_CACHING is a mask and bitwise AND was > intended here instead of logical &&. This bug is essentially > harmless, > it means that sometimes we don't print a warning message which we > wanted > to print. > > Fixes: c2adae44e916 ('hpsa: disable report lun data caching') > Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> > > diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c > index 6a8f958..a386036 100644 > --- a/drivers/scsi/hpsa.c > +++ b/drivers/scsi/hpsa.c > @@ -8671,7 +8671,7 @@ static void hpsa_disable_rld_caching(struct > ctlr_info *h) > if ((rc != 0) || (c->err_info->CommandStatus != 0)) > goto errout; > > - if (*options && HPSA_DIAG_OPTS_DISABLE_RLD_CACHING) > + if (*options & HPSA_DIAG_OPTS_DISABLE_RLD_CACHING) > goto out; > > errout: Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" > in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 11/12/2015 03:59 AM, Johannes Thumshirn wrote: > On Thu, 2015-11-12 at 12:43 +0300, Dan Carpenter wrote: >> HPSA_DIAG_OPTS_DISABLE_RLD_CACHING is a mask and bitwise AND was >> intended here instead of logical &&. This bug is essentially >> harmless, >> it means that sometimes we don't print a warning message which we >> wanted >> to print. >> >> Fixes: c2adae44e916 ('hpsa: disable report lun data caching') >> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> >> >> diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c >> index 6a8f958..a386036 100644 >> --- a/drivers/scsi/hpsa.c >> +++ b/drivers/scsi/hpsa.c >> @@ -8671,7 +8671,7 @@ static void hpsa_disable_rld_caching(struct >> ctlr_info *h) >> if ((rc != 0) || (c->err_info->CommandStatus != 0)) >> goto errout; >> >> - if (*options && HPSA_DIAG_OPTS_DISABLE_RLD_CACHING) >> + if (*options & HPSA_DIAG_OPTS_DISABLE_RLD_CACHING) >> goto out; >> >> errout: > Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> > >> -- >> To unsubscribe from this list: send the line "unsubscribe linux-scsi" >> in >> the body of a message to majordomo@vger.kernel.org >> More majordomo info at http://vger.kernel.org/majordomo-info.html > Signed-off-by: Don Brace <don.brace@pmcs.com> > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
>>>>> "Dan" == Dan Carpenter <dan.carpenter@oracle.com> writes:
Dan> HPSA_DIAG_OPTS_DISABLE_RLD_CACHING is a mask and bitwise AND was
Dan> intended here instead of logical &&. This bug is essentially
Dan> harmless, it means that sometimes we don't print a warning message
Dan> which we wanted to print.
Applied.
diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c index 6a8f958..a386036 100644 --- a/drivers/scsi/hpsa.c +++ b/drivers/scsi/hpsa.c @@ -8671,7 +8671,7 @@ static void hpsa_disable_rld_caching(struct ctlr_info *h) if ((rc != 0) || (c->err_info->CommandStatus != 0)) goto errout; - if (*options && HPSA_DIAG_OPTS_DISABLE_RLD_CACHING) + if (*options & HPSA_DIAG_OPTS_DISABLE_RLD_CACHING) goto out; errout:
HPSA_DIAG_OPTS_DISABLE_RLD_CACHING is a mask and bitwise AND was intended here instead of logical &&. This bug is essentially harmless, it means that sometimes we don't print a warning message which we wanted to print. Fixes: c2adae44e916 ('hpsa: disable report lun data caching') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html