xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Julien Grall <julien.grall@arm.com>
To: Stefano Stabellini <sstabellini@kernel.org>
Cc: xen-devel@lists.xenproject.org, nd@arm.com
Subject: Re: [PATCH] xen/arm: increase default dom0_mem to 512M
Date: Thu, 16 Feb 2017 09:32:23 +0000	[thread overview]
Message-ID: <ad43f7c4-e71c-1b6b-040b-10124eb9363b@arm.com> (raw)
In-Reply-To: <alpine.DEB.2.10.1702151503060.9566@sstabellini-ThinkPad-X260>

Hi Stefano,

On 15/02/2017 23:05, Stefano Stabellini wrote:
> The default dom0_mem is 128M which is not sufficient to boot a Ubuntu
> based Dom0. Increase it to 512M.
>
> Signed-off-by: Stefano Stabellini <sstabellini@kernel.org>

I am not a big fan of increasing the default value. 128M is plenty 
enough if you use a small DOM0 (e.g buildroot or yocto) and people may 
rely on it because it is the default value in the documentation
(see docs/misc/xen-command-line.markdown).

Also, 512M may boot Ubuntu for you but it might not be the case in all 
the configuration. There is no perfect default value, but I think the 
smaller is better. Looking at the documentation, it looks like x86 is 
using 128MB or 1/16 of the memory (whichever is smaller).

But to be fair, I am not even sure why there is a default value, it is 
quite easy to specify the amount of memory used by DOM0 on the command line.

> diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c
> index c97a1f5..f4612a2 100644
> --- a/xen/arch/arm/domain_build.c
> +++ b/xen/arch/arm/domain_build.c
> @@ -31,7 +31,7 @@ integer_param("dom0_max_vcpus", opt_dom0_max_vcpus);
>
>  int dom0_11_mapping = 1;
>
> -#define DOM0_MEM_DEFAULT 0x8000000 /* 128 MiB */
> +#define DOM0_MEM_DEFAULT 0x20000000 /* 512 MiB */

I would use the MB(..) macro here to make the code more readable.

>  static u64 __initdata dom0_mem = DOM0_MEM_DEFAULT;
>
>  static void __init parse_dom0_mem(const char *s)
>

Cheers,

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2017-02-16  9:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-15 23:05 [PATCH] xen/arm: increase default dom0_mem to 512M Stefano Stabellini
2017-02-16  9:32 ` Julien Grall [this message]
2017-02-16 20:17   ` Stefano Stabellini
2017-02-17 15:13     ` Julien Grall
2017-02-17 23:35       ` Stefano Stabellini

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=ad43f7c4-e71c-1b6b-040b-10124eb9363b@arm.com \
    --to=julien.grall@arm.com \
    --cc=nd@arm.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.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;
as well as URLs for NNTP newsgroup(s).