From: "Winkler, Tomas" <tomas.winkler@intel.com>
To: Haakon Bugge <haakon.bugge@oracle.com>,
Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Cc: "arnd@arndb.de" <arnd@arndb.de>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
OFED mailing list <linux-rdma@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"kernel-janitors@vger.kernel.org"
<kernel-janitors@vger.kernel.org>
Subject: RE: [PATCH] mei: Remove some dead code
Date: Sun, 28 Nov 2021 11:12:33 +0000 [thread overview]
Message-ID: <17d6896a6abf49138556e34cb426d575@intel.com> (raw)
In-Reply-To: <80B25490-FE92-420E-A506-C92A996EF174@oracle.com>
>
>
> > On 12 Nov 2021, at 11:06, Christophe JAILLET
> <christophe.jaillet@wanadoo.fr> wrote:
> >
> > 'generated' is known to be true here, so "true || whatever" will still
> > be true.
> >
> > So, remove some dead code.
> >
> > Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> > ---
> > This is also likely that a bug is lurking here.
> >
> > Maybe, the following was expected:
> > - generated = generated ||
> > + generated =
> > (hisr & HISR_INT_STS_MSK) ||
> > (ipc_isr & SEC_IPC_HOST_INT_STATUS_PENDING);
> >
> > ?
>
> I concur about your analysis, but I do not know the intent here.
Your fix is okay, I can ack that patch.
Thanks
Tomas
>
>
> Håkon
>
> > ---
> > drivers/misc/mei/hw-txe.c | 6 +-----
> > 1 file changed, 1 insertion(+), 5 deletions(-)
> >
> > diff --git a/drivers/misc/mei/hw-txe.c b/drivers/misc/mei/hw-txe.c
> > index a4e854b9b9e6..00652c137cc7 100644
> > --- a/drivers/misc/mei/hw-txe.c
> > +++ b/drivers/misc/mei/hw-txe.c
> > @@ -994,11 +994,7 @@ static bool mei_txe_check_and_ack_intrs(struct
> mei_device *dev, bool do_ack)
> > hhisr &= ~IPC_HHIER_SEC;
> > }
> >
> > - generated = generated ||
> > - (hisr & HISR_INT_STS_MSK) ||
> > - (ipc_isr & SEC_IPC_HOST_INT_STATUS_PENDING);
> > -
> > - if (generated && do_ack) {
> > + if (do_ack) {
> > /* Save the interrupt causes */
> > hw->intr_cause |= hisr & HISR_INT_STS_MSK;
> > if (ipc_isr & SEC_IPC_HOST_INT_STATUS_IN_RDY)
> > --
> > 2.30.2
> >
next prev parent reply other threads:[~2021-11-28 11:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-12 10:06 [PATCH] mei: Remove some dead code Christophe JAILLET
2021-11-12 11:30 ` Haakon Bugge
2021-11-28 11:12 ` Winkler, Tomas [this message]
2021-11-28 14:29 ` gregkh
2021-11-28 16:38 ` Winkler, Tomas
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=17d6896a6abf49138556e34cb426d575@intel.com \
--to=tomas.winkler@intel.com \
--cc=arnd@arndb.de \
--cc=christophe.jaillet@wanadoo.fr \
--cc=gregkh@linuxfoundation.org \
--cc=haakon.bugge@oracle.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox