From: Christoph Hellwig <hch@lst.de>
To: Keith Busch <kbusch@kernel.org>
Cc: Oleksandr Natalenko <oleksandr@redhat.com>,
Jens Axboe <axboe@fb.com>, Sagi Grimberg <sagi@grimberg.me>,
Arnd Bergmann <arnd@arndb.de>,
Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
linux-nvme@lists.infradead.org,
Christoph Hellwig <hch@infradead.org>,
Marta Rybczynska <mrybczyn@kalray.eu>,
Hannes Reinecke <hare@suse.de>, Christoph Hellwig <hch@lst.de>,
Bart Van Assche <bvanassche@acm.org>
Subject: Re: [PATCH] nvme: fix uninitialized-variable warning
Date: Wed, 19 Feb 2020 16:21:20 +0100 [thread overview]
Message-ID: <20200219152120.GA18253@lst.de> (raw)
In-Reply-To: <20200213195106.GA8256@redsun51.ssa.fujisawa.hgst.com>
On Fri, Feb 14, 2020 at 04:51:06AM +0900, Keith Busch wrote:
> On Thu, Jan 30, 2020 at 07:48:15AM -0800, Christoph Hellwig wrote:
> > On Thu, Jan 30, 2020 at 04:36:48PM +0100, Arnd Bergmann wrote:
> > > > This one is just gross. I think we'll need to find some other fix
> > > > that doesn't obsfucate the code as much.
> > >
> > > Initializing the nvme_result in nvme_features() would do it, as would
> > > setting it in the error path in __nvme_submit_sync_cmd() -- either
> > > way the compiler cannot be confused about whether it is initialized
> > > later on.
> >
> > Given that this is outside the hot path we can just zero the whole
> > structure before submitting the I/O.
>
> I think this should be okay:
This looks good. Can you send a formal patch?
_______________________________________________
linux-nvme mailing list
linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
WARNING: multiple messages have this Message-ID (diff)
From: Christoph Hellwig <hch@lst.de>
To: Keith Busch <kbusch@kernel.org>
Cc: Christoph Hellwig <hch@infradead.org>,
Arnd Bergmann <arnd@arndb.de>, Jens Axboe <axboe@fb.com>,
Christoph Hellwig <hch@lst.de>, Sagi Grimberg <sagi@grimberg.me>,
Oleksandr Natalenko <oleksandr@redhat.com>,
Bart Van Assche <bvanassche@acm.org>,
Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>,
Marta Rybczynska <mrybczyn@kalray.eu>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
linux-nvme@lists.infradead.org, Hannes Reinecke <hare@suse.de>
Subject: Re: [PATCH] nvme: fix uninitialized-variable warning
Date: Wed, 19 Feb 2020 16:21:20 +0100 [thread overview]
Message-ID: <20200219152120.GA18253@lst.de> (raw)
In-Reply-To: <20200213195106.GA8256@redsun51.ssa.fujisawa.hgst.com>
On Fri, Feb 14, 2020 at 04:51:06AM +0900, Keith Busch wrote:
> On Thu, Jan 30, 2020 at 07:48:15AM -0800, Christoph Hellwig wrote:
> > On Thu, Jan 30, 2020 at 04:36:48PM +0100, Arnd Bergmann wrote:
> > > > This one is just gross. I think we'll need to find some other fix
> > > > that doesn't obsfucate the code as much.
> > >
> > > Initializing the nvme_result in nvme_features() would do it, as would
> > > setting it in the error path in __nvme_submit_sync_cmd() -- either
> > > way the compiler cannot be confused about whether it is initialized
> > > later on.
> >
> > Given that this is outside the hot path we can just zero the whole
> > structure before submitting the I/O.
>
> I think this should be okay:
This looks good. Can you send a formal patch?
next prev parent reply other threads:[~2020-02-19 15:21 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-07 21:42 [PATCH] nvme: fix uninitialized-variable warning Arnd Bergmann
2020-01-07 21:42 ` Arnd Bergmann
2020-01-30 15:04 ` Christoph Hellwig
2020-01-30 15:04 ` Christoph Hellwig
2020-01-30 15:36 ` Arnd Bergmann
2020-01-30 15:36 ` Arnd Bergmann
2020-01-30 15:48 ` Christoph Hellwig
2020-01-30 15:48 ` Christoph Hellwig
2020-02-13 19:51 ` Keith Busch
2020-02-13 19:51 ` Keith Busch
2020-02-19 15:21 ` Christoph Hellwig [this message]
2020-02-19 15:21 ` Christoph Hellwig
-- strict thread matches above, loose matches on Subject: below --
2020-02-19 16:19 [PATCH] nvme: Fix " Keith Busch
2020-02-19 16:22 ` Christoph Hellwig
2020-02-20 7:43 ` Sagi Grimberg
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=20200219152120.GA18253@lst.de \
--to=hch@lst.de \
--cc=arnd@arndb.de \
--cc=axboe@fb.com \
--cc=bvanassche@acm.org \
--cc=chaitanya.kulkarni@wdc.com \
--cc=hare@suse.de \
--cc=hch@infradead.org \
--cc=kbusch@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=mrybczyn@kalray.eu \
--cc=oleksandr@redhat.com \
--cc=sagi@grimberg.me \
/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.