From: Jason Fritcher Subject: Re: Xen BUG at page_alloc.c:1738 (Xen 4.5) Date: Thu, 28 May 2015 23:24:46 -0700 Message-ID: <69067923-F217-459E-8CF0-CCF046919AB3@wolfnet.org> Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2098\)) Content-Type: multipart/mixed; boundary="===============2854693475044081893==" Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org --===============2854693475044081893== Content-Type: multipart/signed; boundary="Apple-Mail=_529F400C-51E2-4017-8442-F1B9041399E6"; protocol="application/pkcs7-signature"; micalg=sha1 --Apple-Mail=_529F400C-51E2-4017-8442-F1B9041399E6 Content-Type: multipart/alternative; boundary="Apple-Mail=_19EEC47E-0E5F-41EE-ABC5-535F17B73B43" --Apple-Mail=_19EEC47E-0E5F-41EE-ABC5-535F17B73B43 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 On Wed, 20 May 2015, Major Hayden wrote: > On 05/20/2015 05:41 AM, Jan Beulich wrote: > > Considering that no-one else is seeing this - is this perhaps = connected > > to you building Xen with pre-release gcc 5.0.1? This is also because = in > > order for the above to indeed occur, mmio_ro_do_page_fault()'s > > put_page() would need to drop the last reference of a page, yet > > page_get_owner_and_reference() doesn't obtain a reference when > > a page is unallocated (and hence unowned), i.e. normally a page > > would have a refcount of at least 2 here. Hence this would be > > possible only due to a race, but the exact same race to be observed > > on different hardware _and_ under an emulator is extremely unlikely. You could try with the xen.gz file from=20 = https://copr-be.cloud.fedoraproject.org/results/myoung/xentest/fedora-21-x= 86_64/xen-4.5.1-0.rc1.fc21/xen-hypervisor-4.5.1-0.rc1.fc21.x86_64.rpm = It is roughly the same version of xen but built against Fedora 21 and = gcc=20 4.9.2. If that works then it probably is gcc 5. Greetings, I have run into pretty much the same issue as the original poster. I am running a recently updated Arch Linux system, with GCC 5.1.0, using = UEFI and gummiboot to boot. I currently have a build of Xen 4.4.1, built = with GCC 4.9.2 from before my last update, that is functioning correctly = on this machine. But the builds of Xen 4.5.0, using GCC 5 and = mingw64-binutils for the EFI binary, are all failing when Xen starts the = Linux kernel, with the same error mentioned in the subject. Below is the = boot log I captured via the serial port. http://pastebin.com/bBC78306 Wondering if my specific toolchain was the issue, I downloaded the = Fedora 22 version of xen-hypervisor and installed its EFI Xen binary = over my compiled binary and received an identical error message, with = slightly different addresses in the panic dump. The Fedora version was = compiled with GCC 5.0.1. Below is the boot log I captured from that = binary. http://pastebin.com/jvg1JazC After finding this thread, and specifically, the quoted message above, I = downloaded that xen-hypervisor package and installed its EFI Xen binary. = That binary boots successfully, as seen by the captured boot log below. http://pastebin.com/DKxwaU2U So, while I=E2=80=99m not familiar enough with Xen to begin to have an = idea of what could possibly be wrong with Xen or GCC 5 to be causing = this bug, I=E2=80=99d like to do what I can to track down the issue so I = can get a working build of Xen 4.5. :) Thanks! =E2=80=94 Jason Fritcher --Apple-Mail=_19EEC47E-0E5F-41EE-ABC5-535F17B73B43 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8
On Wed, 20 May 2015, Major Hayden =
wrote:

> On 05/20/2015 05:41 AM, Jan Beulich wrote:
> > Considering that no-one else is seeing this - is =
this perhaps connected
> > to you building Xen with pre-release gcc 5.0.1? =
This is also because in
> > order for the above to indeed occur, =
mmio_ro_do_page_fault()'s
> > put_page() would need to drop the last reference =
of a page, yet
> > page_get_owner_and_reference() doesn't obtain a =
reference when
> > a page is unallocated (and hence unowned), i.e. =
normally a page
> > would have a refcount of at least 2 here. Hence =
this would be
> > possible only due to a race, but the exact same =
race to be observed
> > on different hardware _and_ under an emulator is =
extremely unlikely.

You could try with the xen.gz file from=20
https://copr-be.cloud.fedoraproject.org/results/myoung/xentest/=
fedora-21-x86_64/xen-4.5.1-0.rc1.fc21/xen-hypervisor-4.5.1-0.rc1.fc21.x86_=
64.rpm
It is roughly the same version of xen but built against Fedora 21 and =
gcc=20
4.9.2. If that works then it probably is gcc 5.
Greetings,

I have run into pretty much the same = issue as the original poster.

I am running a recently updated Arch = Linux system, with GCC 5.1.0, using UEFI and gummiboot to boot. I = currently have a build of Xen 4.4.1, built with GCC 4.9.2 from before my = last update, that is functioning correctly on this machine. But the = builds of Xen 4.5.0, using GCC 5 and mingw64-binutils for the EFI = binary, are all failing when Xen starts the Linux kernel, with the same = error mentioned in the subject. Below is the boot log I captured via the = serial port.


Wondering if my specific toolchain was = the issue, I downloaded the Fedora 22 version of xen-hypervisor and = installed its EFI Xen binary over my compiled binary and received an = identical error message, with slightly different addresses in the panic = dump. The Fedora version was compiled with GCC 5.0.1. Below is the boot = log I captured from that binary.


After finding this thread, and = specifically, the quoted message above, I downloaded that xen-hypervisor = package and installed its EFI Xen binary. That binary boots = successfully, as seen by the captured boot log below.

So, while I=E2=80=99m not familiar = enough with Xen to begin to have an idea of what could possibly be wrong = with Xen or GCC 5 to be causing this bug, I=E2=80=99d like to do what I = can to track down the issue so I can get a working build of Xen 4.5. = :)

Thanks!

=E2=80=94
Jason Fritcher

= --Apple-Mail=_19EEC47E-0E5F-41EE-ABC5-535F17B73B43-- --Apple-Mail=_529F400C-51E2-4017-8442-F1B9041399E6 Content-Disposition: attachment; filename=smime.p7s Content-Type: application/pkcs7-signature; name=smime.p7s Content-Transfer-Encoding: base64 MIAGCSqGSIb3DQEHAqCAMIACAQExCzAJBgUrDgMCGgUAMIAGCSqGSIb3DQEHAQAAoIIMVzCCBhsw ggUDoAMCAQICAw3GEjANBgkqhkiG9w0BAQsFADCBjDELMAkGA1UEBhMCSUwxFjAUBgNVBAoTDVN0 YXJ0Q29tIEx0ZC4xKzApBgNVBAsTIlNlY3VyZSBEaWdpdGFsIENlcnRpZmljYXRlIFNpZ25pbmcx ODA2BgNVBAMTL1N0YXJ0Q29tIENsYXNzIDEgUHJpbWFyeSBJbnRlcm1lZGlhdGUgQ2xpZW50IENB MB4XDTE1MDQyMDA1MDk1MFoXDT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MBwGCSqG SIb3DQEJBTEPFw0xNTA1MjkwNjI0NDhaMCMGCSqGSIb3DQEJBDEWBBSDbhfCKsR6jy1huZWivE73 q2UIXjCBpQYJKwYBBAGCNxAEMYGXMIGUMIGMMQswCQYDVQQGEwJJTDEWMBQGA1UEChMNU3RhcnRD b20gTHRkLjErMCkGA1UECxMiU2VjdXJlIERpZ2l0YWwgQ2VydGlmaWNhdGUgU2lnbmluZzE4MDYG A1UEAxMvU3RhcnRDb20gQ2xhc3MgMSBQcmltYXJ5IEludGVybWVkaWF0ZSBDbGllbnQgQ0ECAw3G EjCBpwYLKoZIhvcNAQkQAgsxgZeggZQwgYwxCzAJBgNVBAYTAklMMRYwFAYDVQQKEw1TdGFydENv bSBMdGQuMSswKQYDVQQLEyJTZWN1cmUgRGlnaXRhbCBDZXJ0aWZpY2F0ZSBTaWduaW5nMTgwNgYD VQQDEy9TdGFydENvbSBDbGFzcyAxIFByaW1hcnkgSW50ZXJtZWRpYXRlIENsaWVudCBDQQIDDcYS MA0GCSqGSIb3DQEBAQUABIIBAIL8ApOf+PdiBHWqKZCFmVMaraEIRTGcTrNXlRMcL+5NuQuQsF80 ccb9/5eKThzAkf5k+H1pDBBmniNN1/tfu5nD3ayz9fsTXsYxqTfROhB7dP5T3QLPo96rtb7SvEOU g3CsJAR/T29ONd38MutmI0m7e9PbvdrO2/K/hgD61XEU21XpYU8PW7aYEco2MlsVRO3VhfRCKliN d5bnMHwDReBabpcs59zSgTNlPkRIV6RhgYLziNPyY11Rc3SGvExb2PH6SyTj79gVySo/IZC+owUs nFkCC3psxYqBAk63vq3FlJxPu+rl+cMoxB50jpAMyILLJWxKi8qR3Tw2aWE1TCgAAAAAAAA= --Apple-Mail=_529F400C-51E2-4017-8442-F1B9041399E6-- --===============2854693475044081893== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============2854693475044081893==--