* Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root="
@ 2015-03-12 17:48 Sander Eikelenboom
2015-03-12 17:59 ` Ian Campbell
0 siblings, 1 reply; 5+ messages in thread
From: Sander Eikelenboom @ 2015-03-12 17:48 UTC (permalink / raw)
To: Ian Campbell; +Cc: xen-devel
Hi Ian,
My PV-guest configs were still using the old "root=" option,
but these guests don't boot anymore since:
commit 49ab17a3a615e1ab4ccc46d6942f925cf841df4b,
"tools: xl: handle unspecified extra= when dealing with root="
These pv guests don't boot anymore since the "root=" part isn't
prepended anymore on the kernel commandline, leading to
a guest kernel that is incapable of finding the root partition.
--
Sander
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root="
2015-03-12 17:48 Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root=" Sander Eikelenboom
@ 2015-03-12 17:59 ` Ian Campbell
2015-03-12 18:49 ` Sander Eikelenboom
2015-03-13 10:05 ` Wei Liu
0 siblings, 2 replies; 5+ messages in thread
From: Ian Campbell @ 2015-03-12 17:59 UTC (permalink / raw)
To: Sander Eikelenboom, Wei Liu, Ian Jackson; +Cc: xen-devel
On Thu, 2015-03-12 at 18:48 +0100, Sander Eikelenboom wrote:
> Hi Ian,
>
> My PV-guest configs were still using the old "root=" option,
> but these guests don't boot anymore since:
> commit 49ab17a3a615e1ab4ccc46d6942f925cf841df4b,
> "tools: xl: handle unspecified extra= when dealing with root="
>
> These pv guests don't boot anymore since the "root=" part isn't
> prepended anymore on the kernel commandline, leading to
> a guest kernel that is incapable of finding the root partition.
Bugger, you are of course absolutely correct.
How about this, compile tested only...
8<-------------
>From fc8eed8083d87608df7b836d89ba058066206b6c Mon Sep 17 00:00:00 2001
From: Ian Campbell <ian.campbell@citrix.com>
Date: Thu, 12 Mar 2015 17:56:47 +0000
Subject: [PATCH] tools: xl: prepend root= to root field on command line with
no extra
This was broken in 49ab17a3a615 "tools: xl: handle unspecified extra=
when dealing with root=".
Reported-by: Sander Eikelenboom <linux@eikelenboom.it>
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
---
tools/libxl/xl_cmdimpl.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c
index 2c32a96..af5bd87 100644
--- a/tools/libxl/xl_cmdimpl.c
+++ b/tools/libxl/xl_cmdimpl.c
@@ -821,7 +821,8 @@ static char *parse_cmdline(XLU_Config *config)
if (asprintf(&cmdline, "root=%s %s", root, extra) == -1)
cmdline = NULL;
} else if (root) {
- cmdline = strdup(root);
+ if (asprintf(&cmdline, "root=%s", root) == -1)
+ cmdline = NULL;
} else if (extra) {
cmdline = strdup(extra);
}
--
1.7.10.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root="
2015-03-12 17:59 ` Ian Campbell
@ 2015-03-12 18:49 ` Sander Eikelenboom
2015-03-13 10:05 ` Wei Liu
1 sibling, 0 replies; 5+ messages in thread
From: Sander Eikelenboom @ 2015-03-12 18:49 UTC (permalink / raw)
To: Ian Campbell; +Cc: Ian Jackson, Wei Liu, xen-devel
Thursday, March 12, 2015, 6:59:06 PM, you wrote:
> On Thu, 2015-03-12 at 18:48 +0100, Sander Eikelenboom wrote:
>> Hi Ian,
>>
>> My PV-guest configs were still using the old "root=" option,
>> but these guests don't boot anymore since:
>> commit 49ab17a3a615e1ab4ccc46d6942f925cf841df4b,
>> "tools: xl: handle unspecified extra= when dealing with root="
>>
>> These pv guests don't boot anymore since the "root=" part isn't
>> prepended anymore on the kernel commandline, leading to
>> a guest kernel that is incapable of finding the root partition.
> Bugger, you are of course absolutely correct.
> How about this, compile tested only...
Works for me, Thanks !
--
Sander
> 8<-------------
> From fc8eed8083d87608df7b836d89ba058066206b6c Mon Sep 17 00:00:00 2001
> From: Ian Campbell <ian.campbell@citrix.com>
> Date: Thu, 12 Mar 2015 17:56:47 +0000
> Subject: [PATCH] tools: xl: prepend root= to root field on command line with
> no extra
> This was broken in 49ab17a3a615 "tools: xl: handle unspecified extra=
> when dealing with root=".
> Reported-by: Sander Eikelenboom <linux@eikelenboom.it>
> Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
> ---
> tools/libxl/xl_cmdimpl.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
> diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c
> index 2c32a96..af5bd87 100644
> --- a/tools/libxl/xl_cmdimpl.c
> +++ b/tools/libxl/xl_cmdimpl.c
> @@ -821,7 +821,8 @@ static char *parse_cmdline(XLU_Config *config)
> if (asprintf(&cmdline, "root=%s %s", root, extra) == -1)
> cmdline = NULL;
> } else if (root) {
> - cmdline = strdup(root);
> + if (asprintf(&cmdline, "root=%s", root) == -1)
> + cmdline = NULL;
> } else if (extra) {
> cmdline = strdup(extra);
> }
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root="
2015-03-12 17:59 ` Ian Campbell
2015-03-12 18:49 ` Sander Eikelenboom
@ 2015-03-13 10:05 ` Wei Liu
2015-03-13 10:23 ` Ian Campbell
1 sibling, 1 reply; 5+ messages in thread
From: Wei Liu @ 2015-03-13 10:05 UTC (permalink / raw)
To: Ian Campbell; +Cc: Sander Eikelenboom, Wei Liu, Ian Jackson, xen-devel
On Thu, Mar 12, 2015 at 05:59:06PM +0000, Ian Campbell wrote:
> On Thu, 2015-03-12 at 18:48 +0100, Sander Eikelenboom wrote:
> > Hi Ian,
> >
> > My PV-guest configs were still using the old "root=" option,
> > but these guests don't boot anymore since:
> > commit 49ab17a3a615e1ab4ccc46d6942f925cf841df4b,
> > "tools: xl: handle unspecified extra= when dealing with root="
> >
> > These pv guests don't boot anymore since the "root=" part isn't
> > prepended anymore on the kernel commandline, leading to
> > a guest kernel that is incapable of finding the root partition.
>
> Bugger, you are of course absolutely correct.
>
> How about this, compile tested only...
>
> 8<-------------
>
> >From fc8eed8083d87608df7b836d89ba058066206b6c Mon Sep 17 00:00:00 2001
> From: Ian Campbell <ian.campbell@citrix.com>
> Date: Thu, 12 Mar 2015 17:56:47 +0000
> Subject: [PATCH] tools: xl: prepend root= to root field on command line with
> no extra
>
> This was broken in 49ab17a3a615 "tools: xl: handle unspecified extra=
> when dealing with root=".
>
> Reported-by: Sander Eikelenboom <linux@eikelenboom.it>
> Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
> ---
> tools/libxl/xl_cmdimpl.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c
> index 2c32a96..af5bd87 100644
> --- a/tools/libxl/xl_cmdimpl.c
> +++ b/tools/libxl/xl_cmdimpl.c
> @@ -821,7 +821,8 @@ static char *parse_cmdline(XLU_Config *config)
> if (asprintf(&cmdline, "root=%s %s", root, extra) == -1)
> cmdline = NULL;
> } else if (root) {
> - cmdline = strdup(root);
> + if (asprintf(&cmdline, "root=%s", root) == -1)
> + cmdline = NULL;
> } else if (extra) {
> cmdline = strdup(extra);
> }
> --
> 1.7.10.4
>
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root="
2015-03-13 10:05 ` Wei Liu
@ 2015-03-13 10:23 ` Ian Campbell
0 siblings, 0 replies; 5+ messages in thread
From: Ian Campbell @ 2015-03-13 10:23 UTC (permalink / raw)
To: Wei Liu; +Cc: Sander Eikelenboom, Ian Jackson, xen-devel
On Fri, 2015-03-13 at 10:05 +0000, Wei Liu wrote:
> On Thu, Mar 12, 2015 at 05:59:06PM +0000, Ian Campbell wrote:
> > On Thu, 2015-03-12 at 18:48 +0100, Sander Eikelenboom wrote:
> > > Hi Ian,
> > >
> > > My PV-guest configs were still using the old "root=" option,
> > > but these guests don't boot anymore since:
> > > commit 49ab17a3a615e1ab4ccc46d6942f925cf841df4b,
> > > "tools: xl: handle unspecified extra= when dealing with root="
> > >
> > > These pv guests don't boot anymore since the "root=" part isn't
> > > prepended anymore on the kernel commandline, leading to
> > > a guest kernel that is incapable of finding the root partition.
> >
> > Bugger, you are of course absolutely correct.
> >
> > How about this, compile tested only...
> >
> > 8<-------------
> >
> > >From fc8eed8083d87608df7b836d89ba058066206b6c Mon Sep 17 00:00:00 2001
> > From: Ian Campbell <ian.campbell@citrix.com>
> > Date: Thu, 12 Mar 2015 17:56:47 +0000
> > Subject: [PATCH] tools: xl: prepend root= to root field on command line with
> > no extra
> >
> > This was broken in 49ab17a3a615 "tools: xl: handle unspecified extra=
> > when dealing with root=".
> >
> > Reported-by: Sander Eikelenboom <linux@eikelenboom.it>
> > Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
>
> Acked-by: Wei Liu <wei.liu2@citrix.com>
Applied, with a tested-by from Sander too.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-03-13 10:23 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-12 17:48 Xen-unstable: "root=" no longer prepended on kernel cmdline since commit "tools: xl: handle unspecified extra= when dealing with root=" Sander Eikelenboom
2015-03-12 17:59 ` Ian Campbell
2015-03-12 18:49 ` Sander Eikelenboom
2015-03-13 10:05 ` Wei Liu
2015-03-13 10:23 ` Ian Campbell
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.