All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@calxeda.com>
To: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: "george.dunlap@eu.citrix.com" <george.dunlap@eu.citrix.com>,
	"xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	David Vrabel <david.vrabel@citrix.com>,
	Ian Campbell <Ian.Campbell@citrix.com>
Subject: Re: Xen on ARM DT based boot protocol
Date: Fri, 24 May 2013 00:27:42 +0200	[thread overview]
Message-ID: <519E97DE.5030703@calxeda.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1305232203560.4799@kaball.uk.xensource.com>

On 05/23/2013 11:04 PM, Stefano Stabellini wrote:

Hi,

> On Thu, 23 May 2013, David Vrabel wrote:
>> On 23/05/13 13:39, Stefano Stabellini wrote:
>>> Hi Ian,
>>> Andre was pointing out to me today that the current boot protocol has a
>>> problem:
>>>
>>>
>>> chosen {
>>>                bootargs = "dom0_mem=128M console=com1,vga";
>>>                xen,dom0-bootargs = "earlyprintk=xenboot console=ttyAMA1 root=/dev/mmcblk0 debug rw init=/bin/bash";
>>> };
>>>
>>>
>>> because we are using bootargs for Xen arguments, the bootloader cannot
>>> just pass the same two lines to Xen on ARM and to Linux on ARM.
>>
>> I think it is unlikely the command line arguments for Linux are the same
>> for bare metal and dom0.  Even in this example here you have a
>> Xen-specific option (earlyprintk=xenboot).
>
> Actually that is not true, in fact in the example above the only
> difference is earlyprintk=xenboot that is just a debug option.

Interestingly Linux/ARM does not seem to expect a parameter to 
earlyprintk, the actual device to use is hardcoded in 
arch/arm/include/debug/<mach>.S and earlyprintk is just a switch. So 
earlyprintk=xen is broken anyway ;-)

But using bootargs for Dom0 could just be a fallback, so what about:

if xen,xen-bootargs is provided: use it for Xen, else use "";
if xen,dom0-bootargs is provided: use it for Dom0, else
	if bootargs is provided: use that for Dom0
write Dom0 cmdline into chosen/bootargs in Dom0's dtb

And is there a need for the "xen," prefix? I thought that this syntax is 
only needed for the compatible property, no?

So eventually there could be one dtb to rule them all:
chosen {
	xen,xen-bootargs = "...";
	xen,dom0-bootargs = "...";
	bootargs = "...";
}
My concern is not so much about the bootloader's understanding of the 
dtb, but more about the vendor provided one, which one would expect to 
be in flash ROM, for instance. We can provide only one here.

Will send a patch tomorrow.

Regards,
Andre.

  reply	other threads:[~2013-05-23 22:27 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-23 12:39 Xen on ARM DT based boot protocol Stefano Stabellini
2013-05-23 12:47 ` George Dunlap
2013-05-23 13:22 ` Ian Campbell
2013-05-23 14:07 ` David Vrabel
2013-05-23 21:04   ` Stefano Stabellini
2013-05-23 22:27     ` Andre Przywara [this message]
2013-05-24  8:31       ` Ian Campbell

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=519E97DE.5030703@calxeda.com \
    --to=andre.przywara@calxeda.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=david.vrabel@citrix.com \
    --cc=george.dunlap@eu.citrix.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --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 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.