linux-4.7.* under xen-4.6.* gives "unhandled page fault (ec=0000)" at boot. -- Root cause found.
A message that is not in the archive (sent off-list or not yet received): [email protected]
Den 17. aug. 2016 21:56, I wrote (to xen-users, as I am no developer):
Quoted 4 lines
I'm on gentoo, running gentoo-sources kernel for dom0.
I am unable to run gentoo-sources-4.7.{0,1}. I'm running under xen, currently at 4.6.3-r1
I am now on linux gentoo-sources-4.7.2, and the bug is stil present.
I have done some digging on my own, and found that protecting two instances of " for_each_efi_memory_desc(md) {" with something like "if( efi.memmap.map != NULL) {" will allow my dom0 to boot and run.
My line-numbers may be a bit off due to copious use of pr_info.
The locations are:
- linux/arch/x86/platform/efi/efi.c line 121 in function efi_find_mirror()
- /usr/src/linux/arch/x86/platform/efi/quirks.c line 253 in function efi_free_boot_services(void)
Searching the web lead me first to a solution which I believe to be wrong, changing the comparison operator in for_each_efi_memory_desc. It also lead me to someone mentioning that efi.memmap.map is not used when running under xen. That info may also be bogus for all I know.
As an example, the latter function now (correct ? ) looks like this after my mis-treatment:
void __init efi_free_boot_services(void)
{
efi_memory_desc_t *md;
if( efi.memmap.map != NULL) {
pr_info("efi_free_boot_services: efi.memmap.map is
%p\n",efi.memmap.map);
for_each_efi_memory_desc(md) {
unsigned long long start = md->phys_addr;
unsigned long long size = md->num_pages << EFI_PAGE_SHIFT;
if (md->type != EFI_BOOT_SERVICES_CODE &&
md->type != EFI_BOOT_SERVICES_DATA)
continue;
/* Do not free, someone else owns it: */
if (md->attribute & EFI_MEMORY_RUNTIME)
continue;
free_bootmem_late(start, size);
}
} else {
pr_info("efi_free_boot_services: efi.memmap.map is (null)\n");
}
efi_unmap_memmap();
}_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Quoted 1 line
Quoted 1 line
Quoted 1 line · On 29.08.16 at 01:14, <[email protected]> wrote:
First of all - please don't cross post.
Quoted 11 lines
Den 17. aug. 2016 21:56, I wrote (to xen-users, as I am no developer):
Quoted 4 lines
I'm on gentoo, running gentoo-sources kernel for dom0.
I am unable to run gentoo-sources-4.7.{0,1}. I'm running under xen, currently at 4.6.3-r1
I am now on linux gentoo-sources-4.7.2, and the bug is stil present.
I have done some digging on my own, and found that protecting two instances of "
for_each_efi_memory_desc(md){" with something like "if( efi.memmap.map != NULL) {" will allow my dom0 to boot and run.
Which is basically the equivalent of e.g.
http://lkml.iu.edu/hypermail/linux/kernel/1608.2/03448.html
(this first one that a quick search found)
Quoted 11 lines
My line-numbers may be a bit off due to copious use of
pr_info.The locations are:
-linux/arch/x86/platform/efi/efi.cline 121 in functionefi_find_mirror()
-/usr/src/linux/arch/x86/platform/efi/quirks.cline 253 in functionefi_free_boot_services(void)Searching the web lead me first to a solution which I believe to be wrong, changing the comparison operator in
for_each_efi_memory_desc. It also lead me to someone mentioning that efi.memmap.map is not used when running under xen. That info may also be bogus for all I know.
Not sure which part the "bogus" here is meant to apply to: Do you mean the statement is bogus (in which case I wonder why), or do you mean the data pointed to would be bogus (in which case I wonder what data you think about when the pointer is NULL)?
Jan
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Quoted 12 lines · Jan Beulich
Quoted 1 line
Quoted 1 line
Quoted 1 line · On 29.08.16 at 01:14, <[email protected]> wrote:
First of all - please don't cross post.
Quoted 8 lines
Den 17. aug. 2016 21:56, I wrote (to xen-users, as I am no developer):
Quoted 4 lines
I'm on gentoo, running gentoo-sources kernel for dom0.
I am unable to run gentoo-sources-4.7.{0,1}. I'm running under xen, currently at 4.6.3-r1
I am now on linux gentoo-sources-4.7.2, and the bug is stil present.
Quoted 7 lines
Quoted 3 lines
I have done some digging on my own, and found that protecting two instances of "
for_each_efi_memory_desc(md){" with something like "if( efi.memmap.map != NULL) {" will allow my dom0 to boot and run.Which is basically the equivalent of e.g.
It does not look like it was ever applied?
Quoted 20 lines
(this first one that a quick search found)
Quoted 11 lines
My line-numbers may be a bit off due to copious use of
pr_info.The locations are:
-linux/arch/x86/platform/efi/efi.cline 121 in functionefi_find_mirror()
-/usr/src/linux/arch/x86/platform/efi/quirks.cline 253 in functionefi_free_boot_services(void)Searching the web lead me first to a solution which I believe to be wrong, changing the comparison operator in
for_each_efi_memory_desc. It also lead me to someone mentioning that efi.memmap.map is not used when running under xen. That info may also be bogus for all I know.Not sure which part the "bogus" here is meant to apply to: Do you mean the statement is bogus (in which case I wonder why), or do you mean the data pointed to would be bogus (in which case I wonder what data you think about when the pointer is NULL)?
Quoted 7 lines
Jan
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Quoted 17 lines
Quoted 1 line
Quoted 1 line · On 29.08.16 at 16:26, <[email protected]> wrote:
Quoted 15 lines · Jan Beulich
Quoted 1 line
Quoted 1 line
Quoted 1 line · On 29.08.16 at 01:14, <[email protected]> wrote:
First of all - please don't cross post.
Quoted 11 lines
Den 17. aug. 2016 21:56, I wrote (to xen-users, as I am no developer):
Quoted 4 lines
I'm on gentoo, running gentoo-sources kernel for dom0.
I am unable to run gentoo-sources-4.7.{0,1}. I'm running under xen, currently at 4.6.3-r1
I am now on linux gentoo-sources-4.7.2, and the bug is stil present.
I have done some digging on my own, and found that protecting two instances
of "
for_each_efi_memory_desc(md){" with something like "if(
Quoted 8 lines
efi.memmap.map
Quoted 5 lines
Quoted 1 line
!= NULL) {" will allow my dom0 to boot and run.
Which is basically the equivalent of e.g.
It does not look like it was ever applied?
Afaik it's on its (admittedly slow) way to Linus.
Jan
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Den 29. aug. 2016 13:04, skrev Jan Beulich:
Quoted 8 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line · On 29.08.16 at 01:14, <[email protected]> wrote:
Den 17. aug. 2016 21:56, I wrote (to xen-users, as I am no developer):
Quoted 6 lines
Quoted 4 lines
I'm on gentoo, running gentoo-sources kernel for dom0.
I am unable to run gentoo-sources-4.7.{0,1}. I'm running under xen, currently at 4.6.3-r1
I am now on linux gentoo-sources-4.7.2, and the bug is stil present.
Quoted 8 lines
Quoted 3 lines
I have done some digging on my own, and found that protecting two instances of "
for_each_efi_memory_desc(md){" with something like "if( efi.memmap.map != NULL) {" will allow my dom0 to boot and run.Which is basically the equivalent of e.g.
http://lkml.iu.edu/hypermail/linux/kernel/1608.2/03448.html
(this first one that a quick search found)
Thanks :-) . I only googled my problem, not my half-assed solution.
Quoted 12 lines
My line-numbers may be a bit off due to copious use of
pr_info.The locations are:
-linux/arch/x86/platform/efi/efi.cline 121 in functionefi_find_mirror()
-/usr/src/linux/arch/x86/platform/efi/quirks.cline 253 in functionefi_free_boot_services(void)Searching the web lead me first to a solution which I believe to be wrong, changing the comparison operator in
for_each_efi_memory_desc. It also lead me to someone mentioning that efi.memmap.map is not used when running under xen. That info may also be bogus for all I know.
Quoted 4 lines
Not sure which part the "bogus" here is meant to apply to: Do you mean the statement is bogus (in which case I wonder why), or do you mean the data pointed to would be bogus (in which case I wonder what data you think about when the pointer is NULL)?
I just mean that I found something on the net and forgot where it came from, and it should not be taken for truth without independent verification, i.e. my "solution" might just be nonsense. I'll shut up now :-) , and go back to lurking.
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel