* [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5
@ 2017-05-04 2:59 Zhangbo (Oscar)
2017-05-10 10:17 ` Jan Beulich
0 siblings, 1 reply; 5+ messages in thread
From: Zhangbo (Oscar) @ 2017-05-04 2:59 UTC (permalink / raw)
To: xen-devel
In __acpi_map_table(), it suppose all ACPI tables may not exceed 4 pages.
but nowadays ACPI tables, such as SRAT table, are large enough, On my
BIOS board, the SRAT table achieves the size of 14428B, although it's
above 3 pages and within 4pages, but in __acpi_map_table(), it maps pages
to get the table. suppose the start address is near the end of the first page:
1000B 4096B 4096B 4096B 1140B
|___|_____________|______________|______________|____|
although the total page is within 4pages , but it may be in fact across 5
pages, thus the NUM_FIXMAP_ACPI_PAGES should be at least 5 nowadays. If
not, xen would wrongly thinks no NUMA configuation could be found as that it
could not get SRAT table.
diff --git a/xen/include/xen/acpi.h b/xen/include/xen/acpi.h
index 30ec0ee..bd616a1 100644
--- a/xen/include/xen/acpi.h
+++ b/xen/include/xen/acpi.h
@@ -43,7 +43,7 @@
* Fixmap pages to reserve for ACPI boot-time tables (see asm-x86/fixmap.h or
* asm-arm/config.h)
*/
-#define NUM_FIXMAP_ACPI_PAGES 4
+#define NUM_FIXMAP_ACPI_PAGES 5
#define BAD_MADT_ENTRY(entry, end) ( \
(!(entry)) || (unsigned long)(entry) + sizeof(*(entry)) > (end) || \
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5
2017-05-04 2:59 [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5 Zhangbo (Oscar)
@ 2017-05-10 10:17 ` Jan Beulich
2017-05-11 6:45 ` Zhangbo (Oscar)
0 siblings, 1 reply; 5+ messages in thread
From: Jan Beulich @ 2017-05-10 10:17 UTC (permalink / raw)
To: Zhangbo (Oscar); +Cc: xen-devel
>>> On 04.05.17 at 04:59, <oscar.zhangbo@huawei.com> wrote:
> --- a/xen/include/xen/acpi.h
> +++ b/xen/include/xen/acpi.h
> @@ -43,7 +43,7 @@
> * Fixmap pages to reserve for ACPI boot-time tables (see asm-x86/fixmap.h or
> * asm-arm/config.h)
> */
> -#define NUM_FIXMAP_ACPI_PAGES 4
> +#define NUM_FIXMAP_ACPI_PAGES 5
Well, this is the kind of fix I don't really like: You make things work for
you without thinking about others. If you found 4 pages aren't
enough, how likely is it that soon someone will find 5 aren't enough
either? IOW, short of eliminating the fixed upper bound altogether,
you should at least add some slack for the foreseeable future. For
this it may also help to estimate the theoretical upper limit of SRAT
(and perhaps other affected tables) for systems currently around
plus, again, some slack. As you may have concluded already it
would therefore also have helped if you had indicated what size a
system you see this relatively large SRAT on.
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5
2017-05-10 10:17 ` Jan Beulich
@ 2017-05-11 6:45 ` Zhangbo (Oscar)
0 siblings, 0 replies; 5+ messages in thread
From: Zhangbo (Oscar) @ 2017-05-11 6:45 UTC (permalink / raw)
To: Jan Beulich; +Cc: xen-devel
>> --- a/xen/include/xen/acpi.h
>> +++ b/xen/include/xen/acpi.h
>> @@ -43,7 +43,7 @@
>> * Fixmap pages to reserve for ACPI boot-time tables (see asm-x86/fixmap.h
>or
>> * asm-arm/config.h)
>> */
>> -#define NUM_FIXMAP_ACPI_PAGES 4
>> +#define NUM_FIXMAP_ACPI_PAGES 5
>
>Well, this is the kind of fix I don't really like: You make things work for
>you without thinking about others. If you found 4 pages aren't
>enough, how likely is it that soon someone will find 5 aren't enough
>either? IOW, short of eliminating the fixed upper bound altogether,
>you should at least add some slack for the foreseeable future. For
>this it may also help to estimate the theoretical upper limit of SRAT
>(and perhaps other affected tables) for systems currently around
>plus, again, some slack. As you may have concluded already it
>would therefore also have helped if you had indicated what size a
>system you see this relatively large SRAT on.
>
>Jan
Thanks, Jan, I'm checking the proper number, and patch v2 is on its way.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5
2017-05-10 3:29 Zhangbo (Oscar)
@ 2017-05-10 9:06 ` Julien Grall
0 siblings, 0 replies; 5+ messages in thread
From: Julien Grall @ 2017-05-10 9:06 UTC (permalink / raw)
To: Zhangbo (Oscar), xen-devel
Cc: Stefano Stabellini, Wei Liu, George Dunlap, Andrew Cooper,
Tim Deegan, Jan Beulich, Ian Jackson
Hello,
On 05/10/2017 04:29 AM, Zhangbo (Oscar) wrote:
> Ping
Most of the maintainers have nowadays filters to flag e-mail with them
CCed and look less often to rest. If you want to draw attention to your
patch, you should CC relevant maintainers (you can find them in
MAINTAINERS).
>
>> In __acpi_map_table(), it suppose all ACPI tables may not exceed 4 pages.
The spaces at the beginning of every lines in the commit message are not
necessary.
>> but nowadays ACPI tables, such as SRAT table, are large enough, On my
>> BIOS board, the SRAT table achieves the size of 14428B, although it's
>> above 3 pages and within 4pages, but in __acpi_map_table(), it maps
>> pages
>> to get the table. suppose the start address is near the end of the first page:
>>
>> 1000B 4096B 4096B 4096B 1140B
>>
>> |___|_____________|______________|______________|____|
>>
>> although the total page is within 4pages , but it may be in fact across 5
s/4pages/4 pages/
>> pages, thus the NUM_FIXMAP_ACPI_PAGES should be at least 5 nowadays.
>> If
>> not, xen would wrongly thinks no NUMA configuation could be found as that
s/configuation/configuration/
>> it
>> could not get SRAT table.
Your signed-off-by is missing here.
>>
>> diff --git a/xen/include/xen/acpi.h b/xen/include/xen/acpi.h
>> index 30ec0ee..bd616a1 100644
>> --- a/xen/include/xen/acpi.h
>> +++ b/xen/include/xen/acpi.h
>> @@ -43,7 +43,7 @@
>> * Fixmap pages to reserve for ACPI boot-time tables (see asm-x86/fixmap.h or
>> * asm-arm/config.h)
>> */
>> -#define NUM_FIXMAP_ACPI_PAGES 4
>> +#define NUM_FIXMAP_ACPI_PAGES 5
>>
>> #define BAD_MADT_ENTRY(entry, end)
>> ( \
>> (!(entry)) || (unsigned long)(entry) + sizeof(*(entry)) > (end)
>> || \
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> https://lists.xen.org/xen-devel
>
Cheers,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5
@ 2017-05-10 3:29 Zhangbo (Oscar)
2017-05-10 9:06 ` Julien Grall
0 siblings, 1 reply; 5+ messages in thread
From: Zhangbo (Oscar) @ 2017-05-10 3:29 UTC (permalink / raw)
To: Zhangbo (Oscar), xen-devel
Ping
> In __acpi_map_table(), it suppose all ACPI tables may not exceed 4 pages.
> but nowadays ACPI tables, such as SRAT table, are large enough, On my
> BIOS board, the SRAT table achieves the size of 14428B, although it's
> above 3 pages and within 4pages, but in __acpi_map_table(), it maps
>pages
> to get the table. suppose the start address is near the end of the first page:
>
> 1000B 4096B 4096B 4096B 1140B
>
> |___|_____________|______________|______________|____|
>
> although the total page is within 4pages , but it may be in fact across 5
> pages, thus the NUM_FIXMAP_ACPI_PAGES should be at least 5 nowadays.
>If
> not, xen would wrongly thinks no NUMA configuation could be found as that
>it
> could not get SRAT table.
>
>diff --git a/xen/include/xen/acpi.h b/xen/include/xen/acpi.h
>index 30ec0ee..bd616a1 100644
>--- a/xen/include/xen/acpi.h
>+++ b/xen/include/xen/acpi.h
>@@ -43,7 +43,7 @@
> * Fixmap pages to reserve for ACPI boot-time tables (see asm-x86/fixmap.h or
> * asm-arm/config.h)
> */
>-#define NUM_FIXMAP_ACPI_PAGES 4
>+#define NUM_FIXMAP_ACPI_PAGES 5
>
> #define BAD_MADT_ENTRY(entry, end)
>( \
> (!(entry)) || (unsigned long)(entry) + sizeof(*(entry)) > (end)
>|| \
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-05-11 6:45 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-04 2:59 [PATCH]acpi: enlarge NUM_FIXMAP_ACPI_PAGES from 4 to 5 Zhangbo (Oscar)
2017-05-10 10:17 ` Jan Beulich
2017-05-11 6:45 ` Zhangbo (Oscar)
2017-05-10 3:29 Zhangbo (Oscar)
2017-05-10 9:06 ` Julien Grall
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.