All of lore.kernel.org
 help / color / mirror / Atom feed
From: Juergen Gross <jgross@suse.com>
To: Jan Beulich <JBeulich@suse.com>, xen-devel@lists.xenproject.org
Cc: andrew.cooper3@citrix.com, daniel.kiper@oracle.com,
	alex.thorlton@hpe.com
Subject: Re: [PATCH v3 2/3] xen/x86: use trampoline e820 buffer for BIOS interface only
Date: Fri, 24 Mar 2017 13:18:01 +0100	[thread overview]
Message-ID: <cf69da5b-b990-23c3-fd7e-2226935da857@suse.com> (raw)
In-Reply-To: <58D50FF202000078001473BC@suse.com>

On 24/03/17 12:24, Jan Beulich wrote:
>>>> On 24.03.17 at 08:48, <jgross@suse.com> wrote:
>> Instead of using the E820 raw buffer for BIOS, EFI and multiboot based
>> memory map information use it for the BIOS interface only. This will
>> enable us to support more E820 entries than the limited trampoline
>> located buffer can.
>>
>> Add a new raw e820 table for common purpose and copy the BIOS buffer
>> to it. Doing the copying in assembly avoids the need to export the
>> symbols for the BIOS E820 buffer and number of entries.
>>
>> Signed-off-by: Juergen Gross <jgross@suse.com>
> 
> Reviewed-by: Jan Beulich <jbeulich@suse.com>
> with one question:
> 
>> --- a/xen/arch/x86/setup.c
>> +++ b/xen/arch/x86/setup.c
>> @@ -636,7 +636,7 @@ void __init noreturn __start_xen(unsigned long mbi_p)
>>  {
>>      char *memmap_type = NULL;
>>      char *cmdline, *kextra, *loader;
>> -    unsigned int initrdidx, domcr_flags = DOMCRF_s3_integrity;
>> +    unsigned int nr_e820, initrdidx, domcr_flags = DOMCRF_s3_integrity;
> 
> Is this variable really needed?
> 
>> @@ -782,14 +782,17 @@ void __init noreturn __start_xen(unsigned long mbi_p)
>>      }
>>      else if ( efi_enabled(EFI_BOOT) )
>>          memmap_type = "EFI";
>> -    else if ( e820_raw_nr != 0 )
>> +    else if ( (nr_e820 = copy_bios_e820(e820_raw.map,
>> +                                        ARRAY_SIZE(e820_raw.map))) != 0 )
>>      {
>>          memmap_type = "Xen-e820";
>> +        e820_raw.nr_map = nr_e820;
>>      }
> 
> I.e. can't we store the result of the function call in e820_raw.nr_map
> right away? (The change could of course be done while committing.)

You are right, the variable can be omitted.


Juergen


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

  parent reply	other threads:[~2017-03-24 12:18 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-24  7:48 [PATCH v3 0/3] xen: support of large memory maps Juergen Gross
2017-03-24  7:48 ` [PATCH v3 1/3] xen/x86: split boot trampoline into permanent and temporary part Juergen Gross
2017-03-24 11:19   ` Jan Beulich
2017-03-24  7:48 ` [PATCH v3 2/3] xen/x86: use trampoline e820 buffer for BIOS interface only Juergen Gross
2017-03-24 11:24   ` Jan Beulich
     [not found]   ` <58D50FF202000078001473BC@suse.com>
2017-03-24 12:18     ` Juergen Gross [this message]
2017-03-24  7:48 ` [PATCH v3 3/3] xen/x86: support larger memory map from EFI Juergen Gross

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=cf69da5b-b990-23c3-fd7e-2226935da857@suse.com \
    --to=jgross@suse.com \
    --cc=JBeulich@suse.com \
    --cc=alex.thorlton@hpe.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=daniel.kiper@oracle.com \
    --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 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.