All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Colin King <colin.king@canonical.com>
Cc: Jack Wang <jinpu.wang@cloud.ionos.com>,
	"James E . J . Bottomley" <jejb@linux.ibm.com>,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Deepak Ukey <Deepak.Ukey@microchip.com>,
	Viswas G <Viswas.G@microchip.com>,
	linux-scsi@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] scsi: pm80xx: fix logic to break out of loop when register value is 2 or 3
Date: Wed, 27 Nov 2019 02:30:35 +0000	[thread overview]
Message-ID: <yq136ea9hkk.fsf@oracle.com> (raw)
In-Reply-To: <20191120135031.270708-1-colin.king@canonical.com> (Colin King's message of "Wed, 20 Nov 2019 13:50:31 +0000")


Colin,

> The condition (reg_val != 2) || (reg_val != 3) will always be true
> because reg_val cannot be equal to two different values at the same
> time. Fix this by replacing the || operator with && so that the loop
> will loop if reg_val is not a 2 and not a 3 as was originally
> intended.

Applied to 5.5/scsi-queue, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering

WARNING: multiple messages have this Message-ID (diff)
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Colin King <colin.king@canonical.com>
Cc: Jack Wang <jinpu.wang@cloud.ionos.com>,
	"James E . J . Bottomley" <jejb@linux.ibm.com>,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Deepak Ukey <Deepak.Ukey@microchip.com>,
	Viswas G <Viswas.G@microchip.com>,
	linux-scsi@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH][next] scsi: pm80xx: fix logic to break out of loop when register value is 2 or 3
Date: Tue, 26 Nov 2019 21:30:35 -0500	[thread overview]
Message-ID: <yq136ea9hkk.fsf@oracle.com> (raw)
In-Reply-To: <20191120135031.270708-1-colin.king@canonical.com> (Colin King's message of "Wed, 20 Nov 2019 13:50:31 +0000")


Colin,

> The condition (reg_val != 2) || (reg_val != 3) will always be true
> because reg_val cannot be equal to two different values at the same
> time. Fix this by replacing the || operator with && so that the loop
> will loop if reg_val is not a 2 and not a 3 as was originally
> intended.

Applied to 5.5/scsi-queue, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering

  parent reply	other threads:[~2019-11-27  2:30 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-20 13:50 [PATCH][next] scsi: pm80xx: fix logic to break out of loop when register value is 2 or 3 Colin King
2019-11-22  8:53 ` Jinpu Wang
2019-11-22  8:53   ` Jinpu Wang
2019-11-27  2:30 ` Martin K. Petersen [this message]
2019-11-27  2:30   ` Martin K. Petersen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=yq136ea9hkk.fsf@oracle.com \
    --to=martin.petersen@oracle.com \
    --cc=Deepak.Ukey@microchip.com \
    --cc=Viswas.G@microchip.com \
    --cc=colin.king@canonical.com \
    --cc=jejb@linux.ibm.com \
    --cc=jinpu.wang@cloud.ionos.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.