From: "H. Peter Anvin" <hpa@zytor.com>
To: Paul Bolle <pebolle@tiscali.nl>
Cc: jeremy@goop.org, xen-devel@lists.xensource.com,
Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
Michael Opdenacker <michael.opdenacker@free-electrons.com>,
x86@kernel.org, linux-kernel@vger.kernel.org,
virtualization@lists.linux-foundation.org, mingo@redhat.com,
Borislav Petkov <bp@alien8.de>, Matt Wilson <msw@amazon.com>,
tglx@linutronix.de
Subject: Re: [Xen-devel] [PATCH] xen: remove unused Kconfig parameter
Date: Thu, 11 Jul 2013 10:57:07 -0700 [thread overview]
Message-ID: <51DEF1F3.2020900@zytor.com> (raw)
In-Reply-To: <1373537338.9708.18.camel@x61.thuisdomein>
On 07/11/2013 03:08 AM, Paul Bolle wrote:
> On Mon, 2013-07-08 at 20:26 -0400, Konrad Rzeszutek Wilk wrote:
>> Could you explain to me please why the check in the scripts is
>> superfluous?
>
> The discussion has since moved on a bit, but I haven't answered this
> question yet.
>
> The check grub2 currently performs in one of its configuration scripts
> is (reformatted):
> if (grep -qx "CONFIG_XEN_DOM0=y" "${config}" 2> /dev/null ||
> grep -qx "CONFIG_XEN_PRIVILEGED_GUEST=y" "${config}" 2> /dev/null);
> then echo -n "$i " ;
> fi
>
If only grep supported looking for more than one string at a time.
Maybe we could construct some kind of pattern expression syntax for it,
perhaps based on the theory of regular languages?
> But the Kconfig entry for XEN_PRIVILEGED_GUEST reads:
> # Dummy symbol since people have come to rely on the PRIVILEGED_GUEST
> # name in tools.
> config XEN_PRIVILEGED_GUEST
> def_bool XEN_DOM0
>
> In other words: CONFIG_XEN_PRIVILEGED_GUEST should always be equal to
> CONFIG_XEN_DOM0. So the two grep commands should always both evaluate to
> true or both evaluate to false. One of these two commands can safely be
> dropped.
Not necessarily true across kernel versions.
> Another consequence is that dropping XEN_PRIVILEGED_GUEST doesn't break
> this configuration script. It will still behave as it does now.
>
> (Whether that script should grep for Kconfig macros in the first place
> is another discussion.)
"Hell no".
-hpa
next prev parent reply other threads:[~2013-07-11 17:57 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-08 6:28 [PATCH] xen: remove unused Kconfig parameter Michael Opdenacker
2013-07-08 19:28 ` Konrad Rzeszutek Wilk
2013-07-08 19:34 ` [Xen-devel] " Matt Wilson
2013-07-08 20:29 ` H. Peter Anvin
2013-07-08 20:58 ` Borislav Petkov
2013-07-08 23:35 ` Paul Bolle
2013-07-09 0:26 ` Konrad Rzeszutek Wilk
2013-07-09 7:41 ` Jan Beulich
2013-07-09 14:48 ` Konrad Rzeszutek Wilk
2013-07-09 14:54 ` Jan Beulich
2013-07-09 15:05 ` Borislav Petkov
2013-07-09 15:09 ` H. Peter Anvin
2013-07-09 17:19 ` Konrad Rzeszutek Wilk
2013-07-09 20:01 ` Borislav Petkov
2013-07-09 20:40 ` Konrad Rzeszutek Wilk
2013-07-09 20:57 ` Borislav Petkov
2013-07-09 22:34 ` Sander Eikelenboom
2013-07-10 3:20 ` Borislav Petkov
2013-07-10 3:55 ` H. Peter Anvin
2013-07-10 6:19 ` Matt Wilson
2013-07-10 7:41 ` Sander Eikelenboom
2013-07-10 14:46 ` Konrad Rzeszutek Wilk
2013-07-11 10:08 ` Paul Bolle
2013-07-11 17:57 ` H. Peter Anvin [this message]
2013-07-11 18:13 ` Paul Bolle
2013-07-11 18:24 ` Konrad Rzeszutek Wilk
2013-07-11 21:13 ` Geert Uytterhoeven
2013-07-08 20:13 ` H. Peter Anvin
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=51DEF1F3.2020900@zytor.com \
--to=hpa@zytor.com \
--cc=bp@alien8.de \
--cc=jeremy@goop.org \
--cc=konrad.wilk@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=michael.opdenacker@free-electrons.com \
--cc=mingo@redhat.com \
--cc=msw@amazon.com \
--cc=pebolle@tiscali.nl \
--cc=tglx@linutronix.de \
--cc=virtualization@lists.linux-foundation.org \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xensource.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;
as well as URLs for NNTP newsgroup(s).