From: Dan Carpenter <dan.carpenter@oracle.com>
To: Alison Schofield <alison.schofield@intel.com>
Cc: "Verma, Vishal L" <vishal.l.verma@intel.com>,
"Weiny, Ira" <ira.weiny@intel.com>,
"Widawsky, Ben" <ben.widawsky@intel.com>,
"Williams, Dan J" <dan.j.williams@intel.com>,
Jonathan Cameron <Jonathan.Cameron@huawei.com>,
Davidlohr Bueso <dave@stgolabs.net>,
"linux-cxl@vger.kernel.org" <linux-cxl@vger.kernel.org>,
"kernel-janitors@vger.kernel.org"
<kernel-janitors@vger.kernel.org>
Subject: Re: [PATCH] cxl/mbox: fix logical vs bitwise typo
Date: Fri, 6 May 2022 16:50:45 +0300 [thread overview]
Message-ID: <20220506135045.GF4009@kadam> (raw)
In-Reply-To: <20220429023700.GA1320788@alison-desk>
On Thu, Apr 28, 2022 at 07:37:00PM -0700, Alison Schofield wrote:
> On Thu, Apr 28, 2022 at 02:38:25AM -0700, Dan Carpenter wrote:
> > This should be bitwise & instead of &&.
>
> Thanks Dan. How'd you find this?
>
Sorry for the delayed response. This was from some Smatch work that I
hadn't published yet. I've pushed it now.
It doesn't find anything else though.
regards,
dan carpenter
> >
> > Fixes: 6179045ccc0c ("cxl/mbox: Block immediate mode in SET_PARTITION_INFO command")
> > Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> > ---
> > drivers/cxl/core/mbox.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/cxl/core/mbox.c b/drivers/cxl/core/mbox.c
> > index 731cb43b570e..54f434733b56 100644
> > --- a/drivers/cxl/core/mbox.c
> > +++ b/drivers/cxl/core/mbox.c
> > @@ -243,7 +243,7 @@ static bool cxl_payload_from_user_allowed(u16 opcode, void *payload_in)
> > case CXL_MBOX_OP_SET_PARTITION_INFO: {
> > struct cxl_mbox_set_partition_info *pi = payload_in;
> >
> > - if (pi->flags && CXL_SET_PARTITION_IMMEDIATE_FLAG)
> > + if (pi->flags & CXL_SET_PARTITION_IMMEDIATE_FLAG)
> > return false;
> > break;
> > }
> > --
> > 2.35.1
> >
prev parent reply other threads:[~2022-05-06 13:51 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-28 9:38 [PATCH] cxl/mbox: fix logical vs bitwise typo Dan Carpenter
2022-04-28 17:01 ` Dan Williams
2022-04-29 2:37 ` Alison Schofield
2022-05-06 13:50 ` Dan Carpenter [this message]
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=20220506135045.GF4009@kadam \
--to=dan.carpenter@oracle.com \
--cc=Jonathan.Cameron@huawei.com \
--cc=alison.schofield@intel.com \
--cc=ben.widawsky@intel.com \
--cc=dan.j.williams@intel.com \
--cc=dave@stgolabs.net \
--cc=ira.weiny@intel.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-cxl@vger.kernel.org \
--cc=vishal.l.verma@intel.com \
/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.