From: Mark Brown <broonie@kernel.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Nick Krause <xerofoiify@gmail.com>,
"open list:SPI SUBSYSTEM" <linux-spi@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] spi: Initialize variable to prevent uninitialized warning
Date: Thu, 7 Aug 2014 10:55:17 +0100 [thread overview]
Message-ID: <20140807095517.GD17528@sirena.org.uk> (raw)
In-Reply-To: <20140807052219.GA21124@roeck-us.net>
[-- Attachment #1: Type: text/plain, Size: 489 bytes --]
On Wed, Aug 06, 2014 at 10:22:19PM -0700, Guenter Roeck wrote:
> So if we ever hit that uninitialized case, where bits_per_word is
> neither 8 nor 16, we'll have ops set to NULL and end up wondering
> why the kernel crashes a bit further down in the code. Not really
> sure if that is an improvement.
It's not. The goal isn't to fix the warning, it's to fix the problem
the compiler is telling you about - initialising to the wrong value is
just as bad as not being initialised at all.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
prev parent reply other threads:[~2014-08-07 9:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-07 4:51 Nick Krause
2014-08-07 5:22 ` Guenter Roeck
2014-08-07 9:55 ` Mark Brown [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=20140807095517.GD17528@sirena.org.uk \
--to=broonie@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-spi@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=xerofoiify@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome