public inbox for linux-efi@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: "H. Peter Anvin" <hpa-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org>
Cc: Toshi Kani <toshi.kani-VXdhtT5mjnY@public.gmane.org>,
	dyoung-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	kexec-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	mjg59-1xO5oi07KQx4cg9Nei1l7Q@public.gmane.org,
	linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	James.Bottomley-d9PhHud1JfjCXq6kfMZ53/egYHeGw8Jk@public.gmane.org,
	horms-/R6kz+dDXgpPR4JQBCEnsQ@public.gmane.org,
	bp-Gina5bIWoIWzQB+pC5nmwQ@public.gmane.org,
	ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org,
	vgoyal-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
	Greg KH <greg-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
Subject: Re: [patch 1/3 v2] Add function get_bootparam
Date: Tue, 12 Nov 2013 04:53:44 +0100	[thread overview]
Message-ID: <20131112035344.GA28116@gmail.com> (raw)
In-Reply-To: <52819E71.70201-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org>


* H. Peter Anvin <hpa-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org> wrote:

> On 11/11/2013 05:27 PM, Toshi Kani wrote:
> > On Tue, 2013-11-05 at 16:29 +0800, dyoung-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org wrote:
> >> Not only setup_subarch will get data from debugfs file
> >> boot_params/data, later code for adding efi_info will
> >> also need do same thing. Thus add a common function here
> >> for later use.
> > 
> > get_bootparam() calls find_mnt_by_fsname("debugfs"), which assumes that
> > debugfs is mounted with device name "debugfs".  This function fails
> > when:
> >  - debugfs is not mounted, or
> >  - debugfs is mounted with a different device name, such as nodev [1].
> > 
> > This issue is not introduced by this patch.  But the original code,
> > which sets hardware_subarch, seems to work even if it failed to access
> > debugfs (which is ignored) since hardware_subarch is zero most of the
> > cases anyway.  With this change, however, this failure now makes the 2nd
> > kernel unbootable.  So, it needs to be addressed to make this code path
> > work reliably (or kexec should fail at least).
> > 
> 
> Greg, Ingo,
> 
> Since there is now a legitimate user of this stuff, can we actually 
> export this in sysfs (or something else other than sploit^Wdebugfs)?
> 
> kexec-tools can have a fallback to debugfs if we really need it, but 
> making people mount debugfs to have some essential piece of 
> functionality scares the heck out of me.

No principial objections from me: anything that actually turns out to 
prove itself in debugfs and ends up mattering for real ought to move to 
sysfs.

Thanks,

	Ingo

  parent reply	other threads:[~2013-11-12  3:53 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-05  8:29 [patch 0/3 v2] kexec-tools: efi runtime support dyoung-H+wXaHxf7aLQT0dZR+AlfA
2013-11-05  8:29 ` [patch 1/3 v2] Add function get_bootparam dyoung-H+wXaHxf7aLQT0dZR+AlfA
     [not found]   ` <20131105083428.411624560-je1gSBvt1TcFLmT5oZ11vB/sF2h8X+2i0E9HWUfgJXw@public.gmane.org>
2013-11-12  1:27     ` Toshi Kani
     [not found]       ` <1384219658.1847.84.camel-RbGIw1UOYPVo/CpIj0byZw@public.gmane.org>
2013-11-12  2:14         ` Dave Young
2013-11-12  3:20         ` H. Peter Anvin
     [not found]           ` <52819E71.70201-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org>
2013-11-12  3:53             ` Ingo Molnar [this message]
     [not found]               ` <aa0ccca4-b27b-41b6-8adb-3c969eb29bf7@email.android.com>
     [not found]                 ` <aa0ccca4-b27b-41b6-8adb-3c969eb29bf7-2ueSQiBKiTY7tOexoI0I+QC/G2K4zDHf@public.gmane.org>
2013-11-12 14:26                   ` Vivek Goyal
2013-11-12  7:58             ` Greg KH
     [not found]               ` <20131112075831.GA6213-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2013-11-12  8:08                 ` Dave Young
     [not found]                   ` <20131112080854.GD6999-je1gSBvt1TcFLmT5oZ11vB/sF2h8X+2i0E9HWUfgJXw@public.gmane.org>
2013-11-12  8:30                     ` Greg KH
     [not found]                       ` <20131112083012.GB7708-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2013-11-12  8:50                         ` Dave Young
2013-11-12  9:37                         ` H. Peter Anvin
     [not found]                           ` <5281F6D5.4090700-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org>
2013-11-12  9:51                             ` Greg KH
     [not found]                               ` <20131112095114.GA20100-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2013-11-13  0:50                                 ` Dave Young
     [not found]                                   ` <20131113005032.GB5069-je1gSBvt1TcFLmT5oZ11vB/sF2h8X+2i0E9HWUfgJXw@public.gmane.org>
2013-11-18  2:22                                     ` Dave Young
     [not found]                                       ` <20131118022234.GD4025-je1gSBvt1TcFLmT5oZ11vB/sF2h8X+2i0E9HWUfgJXw@public.gmane.org>
2013-11-18  3:29                                         ` H. Peter Anvin
     [not found]                                           ` <52898982.3020200-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org>
2013-11-18  5:29                                             ` Dave Young
     [not found]                                               ` <20131118052949.GA14532-je1gSBvt1TcFLmT5oZ11vB/sF2h8X+2i0E9HWUfgJXw@public.gmane.org>
2013-11-18  5:36                                                 ` H. Peter Anvin
2013-11-05  8:29 ` [patch 2/3 v2] Add efi_info in x86 setup header dyoung-H+wXaHxf7aLQT0dZR+AlfA
2013-11-05  8:29 ` [patch 3/3 v2] Passing efi related data via setup_data dyoung-H+wXaHxf7aLQT0dZR+AlfA

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=20131112035344.GA28116@gmail.com \
    --to=mingo-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
    --cc=James.Bottomley-d9PhHud1JfjCXq6kfMZ53/egYHeGw8Jk@public.gmane.org \
    --cc=bp-Gina5bIWoIWzQB+pC5nmwQ@public.gmane.org \
    --cc=dyoung-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org \
    --cc=greg-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org \
    --cc=horms-/R6kz+dDXgpPR4JQBCEnsQ@public.gmane.org \
    --cc=hpa-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org \
    --cc=kexec-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mjg59-1xO5oi07KQx4cg9Nei1l7Q@public.gmane.org \
    --cc=toshi.kani-VXdhtT5mjnY@public.gmane.org \
    --cc=vgoyal-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.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