All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shannon Zhao <zhaoshenglong@huawei.com>
To: Jan Beulich <JBeulich@suse.com>, Shannon Zhao <shannon.zhao@linaro.org>
Cc: Hangaohuai <hangaohuai@huawei.com>,
	Ian Campbell <ian.campbell@citrix.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	andrew@fubar.geek.nz,
	"Huangpeng (Peter)" <peter.huangpeng@huawei.com>,
	Julien Grall <julien.grall@citrix.com>,
	Stefano Stabellini <stefano.stabellini@citrix.com>,
	David Vrabel <david.vrabel@citrix.com>,
	BorisOstrovsky <boris.ostrovsky@oracle.com>,
	xen-devel <xen-devel@lists.xen.org>,
	Parth Dixit <parth.dixit@linaro.org>,
	Christoffer Dall <christoffer.dall@linaro.org>,
	RogerPauMonne <roger.pau@citrix.com>
Subject: Re: Design doc of adding ACPI support for arm64 on Xen - version 5
Date: Mon, 31 Aug 2015 19:31:18 +0800	[thread overview]
Message-ID: <55E43B06.3080406@huawei.com> (raw)
In-Reply-To: <55E43D3A020000780009E3B2@prv-mh.provo.novell.com>



On 2015/8/31 17:40, Jan Beulich wrote:
>>>> On 31.08.15 at 10:51, <zhaoshenglong@huawei.com> wrote:
>> On 2015/8/31 15:39, Jan Beulich wrote:
>>>>>> On 29.08.15 at 03:29, <shannon.zhao@linaro.org> wrote:
>>>> On 2015/8/28 23:06, Jan Beulich wrote:
>>>>>>>> On 28.08.15 at 11:45, <zhaoshenglong@huawei.com> wrote:
>>>>>> Create only one ConfigurationTable to store VendorGuid and VendorTable.
>>>>>
>>>>> What do you mean with "Create only one ..." - there is only one.
>>>>> DYM "Create one additional Configuration Table entry ...", implying
>>>>> that the Configuration Table will need to by copied too?
>>>>
>>>> Sorry for the misunderstanding. I mean that it doesn't copy the original
>>>> one and just creates a new ConfigurationTable.
>>>
>>> If you don't copy the original one, how does Dom0 learn of what is
>>> in the original one (ACPI being just one such element)? Right now I
>>> can't see why you wouldn't copy the entire table and simply append
>>> the one extra entry.
>>
>> The original System table contains a EFI configuration table which
>> stores the _host_ RSDP table address. But we create a new RSDP table and
>> the address is different. We create a new EFI configuration table to
>> store the new RSDP table address to VenderTable.
>> So if we supply both the host EFI configuration table and the new one to
>> Dom0, how do you expect Dom0 to get the right ACPI table?
> 
> There isn't even a way to supply both. You can only supply a
> clone. If you expect Linux to be able to deal with it with minimal
> change, the altered RSDP should still be provided using
> ACPI_20_TABLE_GUID.

That's what this design exactly does.

 But wait - I think I see where the confusion
> comes from: You say "store [...] to VendorTable", which I read as
> another kind of table, but I think you mean the VendorTable field
> of EFI_CONFIGURATION_TABLE. Since this isn't the first time
> imprecise wording has led to confusion - may I once again ask that
> you be very precise in the terms you use, so that tables, table
> entries, fields, etc can all be told apart easily (and namely without
> having to look up what a certain term used refers to)?
> 
>>>>>> d) Copy MADT table
>>>>>> It needs to change MADT table to restrict the number of vCPUs. We choose
>>>>>> to copy the first dom0_max_vcpus GICC entries of MADT to new created
>>>>>> MADT table when numa is not supported currently.
>>>>>
>>>>> Copy means you imply to have an original?
>>>>
>>>> So I'll change it to "create".
>>>>
>>>>> What if dom0_max_vcpus
>>>>> is larger than the physical CPU count?
>>>>
>>>> I think it only needs to care the cpu_interface_number, uid and mpidr
>>>> field of GICC entry and other fields could be same with the host GICC
>>>> entry. It could get the mpidr from the vCPU index.
>>>
>>> You again suggest to use data from host entries, i.e. you leave
>>> incompletely addressed the original question: "What source of
>>> information do you intend to use when the Dom0's vCPU count is
>>> higher than the host's pCPU count?"
>>>
>>
>> There are only the cpu_interface_number, uid and mpidr which need to
>> change. Other fields could copy from any one of the GICC entries from
>> host MADT table.
> 
> Hmm, okay, if _any one_ is indeed fine, then okay. But then please
> change to wording in your document to make this explicit (and to also
> make explicit that you consider this an okay thing to do in the first
> place, just to catch others' attention to double check it really is).
> 
>>>>>> g) Copy RSDP table
>>>>>> Change the value of xsdt_physical_address in RSDP table. As we create a
>>>>>> new XSDT table and the address of XSDT is changed, so it needs to update
>>>>>> the value of "xsdt_physical_address" in RSDP. So Dom0 could get the
>>>>>> right XSDT table rather than the old one. And it needs to update the
>>>>>> value of VendorTable in EFI Configuration Table which is created in
>>>>>> above step a).
>>>>>
>>>>> How is this last sentence related to the handling of RSDP?
>>>>
>>>> Because the ACPI root address(i.e. the address of RSDP table) is stored
>>>> in EFI Configuration Table.
>>>
>>> With this I can only see you to refer to everything _except_ the last
>>> sentence. The last sentence talks about VendorTable, which I continue
>>> to not see to have a relation to ACPI/RSDP.
>>>
>>
>> The value of VendorTable is the ACPI root address and Dom0 (or Linux)
>> get the ACPI root address from it when using UEFI with ACPI.
>>
>> (I wonder why you didn't get this if you have a glance at the booting
>> process. uefi_init(arch/arm64/kernel/efi.c of Linux) -->
>> efi_config_parse_tables --> match_config_table. It will save the
>> VenderTable to efi.acpi20 and when Linux call acpi_os_get_root_pointer
>> to get ACPI root address, it will return efi.acpi20)
> 
> See above - if I hadn't realized you, in every single place you use it,
> really mean "the VendorTable field of the Configuration Table entry
> using ACPI_20_TABLE_GUID", I would have complained here again.
> (Of course you don't need to spell it this way every time, but you
> should imo spell it this or a similar way at least once in each section.)
> 

So you can't get the meaning of "the value of VendorTable in EFI
Configuration Table"?

-- 
Shannon

  reply	other threads:[~2015-08-31 11:31 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-28  9:45 Design doc of adding ACPI support for arm64 on Xen - version 5 Shannon Zhao
2015-08-28 12:55 ` Julien Grall
2015-08-29  1:00   ` Shannon Zhao
2015-08-31  7:33     ` Jan Beulich
2015-08-31 11:44     ` Julien Grall
2015-08-31 12:03       ` Shannon Zhao
2015-08-31 12:34         ` Julien Grall
2015-09-01  4:12           ` Shannon Zhao
2015-09-01 11:28             ` Julien Grall
2015-09-01 12:35               ` Shannon Zhao
2015-09-01 13:40                 ` Julien Grall
2015-09-01 14:03                   ` Jan Beulich
2015-09-01 14:20                     ` Julien Grall
2015-09-02  6:02                   ` Shannon Zhao
2015-09-02  8:41                     ` Jan Beulich
2015-09-02  9:18                       ` Christoffer Dall
2015-09-02 11:15                         ` Julien Grall
2015-09-02  9:25                       ` Shannon Zhao
2015-09-02 12:30                         ` Jan Beulich
2015-09-02 11:09                     ` Julien Grall
2015-09-02 12:02                       ` Shannon Zhao
2015-09-02 12:52                         ` Julien Grall
2015-09-02 13:26                           ` Ian Campbell
2015-09-02 13:48                             ` Julien Grall
2015-09-02 13:54                               ` Ian Campbell
2015-09-02 13:57                                 ` Christoffer Dall
2015-09-02 15:27                                   ` Leif Lindholm
2015-09-02 15:37                                     ` Ard Biesheuvel
2015-09-02 14:00                               ` Jan Beulich
2015-09-02 12:58           ` Ian Campbell
2015-08-28 15:06 ` Jan Beulich
2015-08-29  1:29   ` Shannon Zhao
2015-08-31  7:39     ` Jan Beulich
2015-08-31  8:51       ` Shannon Zhao
2015-08-31  9:40         ` Jan Beulich
2015-08-31 11:31           ` Shannon Zhao [this message]
2015-08-31 11:46             ` Jan Beulich
2015-09-02 12:54           ` Ian Campbell
2015-09-02 13:59             ` Shannon Zhao
2015-09-02 14:24               ` Ian Campbell
2015-09-02 12:18 ` Ian Campbell
2015-09-07  3:37   ` Shannon Zhao
2015-09-07 10:47     ` 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=55E43B06.3080406@huawei.com \
    --to=zhaoshenglong@huawei.com \
    --cc=JBeulich@suse.com \
    --cc=andrew@fubar.geek.nz \
    --cc=boris.ostrovsky@oracle.com \
    --cc=christoffer.dall@linaro.org \
    --cc=david.vrabel@citrix.com \
    --cc=hangaohuai@huawei.com \
    --cc=ian.campbell@citrix.com \
    --cc=julien.grall@citrix.com \
    --cc=parth.dixit@linaro.org \
    --cc=peter.huangpeng@huawei.com \
    --cc=roger.pau@citrix.com \
    --cc=shannon.zhao@linaro.org \
    --cc=stefano.stabellini@citrix.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xen.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.