[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] Enabling AMD-Vi IOMMU panics Xen




On Sat, Apr 9, 2016 at 10:19 PM, kmalkki <kyosti.malkki@xxxxxxxxx> wrote:
0001-IOMMU.patch
+++ b/src/cpu/amd/pi/heapmanager.c
@@ -36,7 +36,7 @@ void EmptyHeap(void)
     memset(BiosManagerPtr, 0, BIOS_HEAP_SIZE);
 }
 
-#if IS_ENABLED(CONFIG_NORTHBRIDGE_AMD_PI_00630F01) && !defined(__PRE_RAM__)
+#if IS_ENABLED(CONFIG_NORTHBRIDGE_AMD_PI_00730F01) && !defined(__PRE_RAM__)

What does this change do? It doesn't look like it's used by the IOMMU
 
0002-apu2.patch
+++ b/src/mainboard/pcengines/apu2/agesawrapper.c
@@ -468,6 +467,10 @@ AGESA_STATUS agesawrapper_amdinitlate(void)
     /* NOTE: if not call amdcreatestruct, the initializer(AmdInitLateInitializer) would not be called */
     AmdCreateStruct(&AmdParamStruct);
     AmdLateParams = (AMD_LATE_PARAMS *)AmdParamStruct.NewStructPtr;
+
+    AmdLateParams->GnbLateConfiguration.GnbIoapicId = 0x05;
+    AmdLateParams->GnbLateConfiguration.FchIoapicId = 0x04;

Looks like I forgot to add these two lines to my own version of the patch! This adds the missing IOAPIC entries to the IVRS table.
To think I searched both the BKDG and IOMMU spec but forgot the AGESA documentation...

That said, even with your additions to the patch, I tried setting ivrs_iommu[5] to all the "non-device" devices returned from lspci (i.e., devices 00, 02, 14 and 18 and all their individual functions), I still got the same panic at hvm_find_io_handler+0x6f that you can see at the bottom of "iommu=no-intremap.log" (http://lists.xen.org/archives/html/xen-users/2016-03/txtkvG3rJp7O1.txt) in my first post.
So now I'm thinking the IVRS table isn't wrong (with the northbridge IOAPIC at 00:00.0), but there might be an issue with the IOMMU itself or Xen.

How would I go working out if it's a Xen issue or the IOMMU's? How can I get Xen to coredump when it panics? Are there any particular functions of interest related to the panic I should start investigating from, or should I just follow the stacktrace up?
Should I bring xen-devel into this discussion, considering it is a panic?
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.