public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Matt Fleming <matt.fleming@intel.com>
To: Ingo Molnar <mingo@kernel.org>
Cc: Matthew Garrett <matthew.garrett@nebula.com>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	"H. Peter Anvin" <hpa@linux.intel.com>,
	Borislav Petkov <bp@suse.de>, "H. Peter Anvin" <hpa@zytor.com>,
	Ingo Molnar <mingo@elte.hu>, Josh Boyer <jwboyer@redhat.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Paul Bolle <pebolle@tiscali.nl>,
	Thomas Gleixner <tglx@linutronix.de>
Subject: Re: [GIT PULL] x86 fixes for 3.9
Date: Fri, 26 Apr 2013 10:01:32 +0100	[thread overview]
Message-ID: <517A426C.6020701@intel.com> (raw)
In-Reply-To: <20130426072919.GA31557@gmail.com>

On 26/04/13 08:29, Ingo Molnar wrote:
> I'm worried about the fragility of this code - this is firmware code ...
> 
> I think firmware code should be fundamentally paranoid and robust, and in 
> this case treat all EFI-provided data as hostile and do a much sanity 
> checking of it as possible - and provide an actionable error message if 
> the checks fail, not just 'crash'.
> 
> Even if no-one complained, yet.

I'm not sure how much more robust checking for NULL makes it, it's not
going to save us from garbage pointers, etc. Instead of the pointer
being NULL a more likely bug is that query_variable_info() exists (for
those firmware that implement the relevant spec version), but doesn't
work correctly. That's the kind of bug we've been seeing in other
functions.

To be fair to Josh, his original submission did include the NULL check,
but I asked him to remove it. If someone really wants to re-add the
check for a NULL pointer, I'm not super opposed to it.

      reply	other threads:[~2013-04-26  9:01 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-25 21:44 [GIT PULL] x86 fixes for 3.9 H. Peter Anvin
2013-04-25 22:20 ` Linus Torvalds
2013-04-25 22:23   ` Matthew Garrett
2013-04-25 22:53     ` Michel Lespinasse
2013-04-25 22:54       ` H. Peter Anvin
2013-04-25 23:11         ` Michel Lespinasse
2013-04-26  7:12           ` Matt Fleming
2013-04-26  7:43             ` Michel Lespinasse
2013-04-26  8:49               ` Matt Fleming
2013-04-26  9:02                 ` Michel Lespinasse
2013-04-26  9:44                   ` Matt Fleming
2013-04-26  7:29     ` Ingo Molnar
2013-04-26  9:01       ` Matt Fleming [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=517A426C.6020701@intel.com \
    --to=matt.fleming@intel.com \
    --cc=bp@suse.de \
    --cc=hpa@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=jwboyer@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matthew.garrett@nebula.com \
    --cc=mingo@elte.hu \
    --cc=mingo@kernel.org \
    --cc=pebolle@tiscali.nl \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.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