[PPC64] Patch to correct alignment for lppaca in paca_struct

will schmidt will_schmidt at vnet.ibm.com
Tue Dec 7 04:16:25 EST 2004


Hi,

We found that we were failing register_vpa calls in cases where the lppaca
structure (part of the PACA) crosses a page boundary.   (LTC bug 12689).

This was causing us (lparcfg specifically) some grief as the xSharedProc bit was not being set.

The attached patch changes the alignment of the lppaca structure, and a few comments so we understand why.


-Will


Signed-off-by:  Will Schmidt  <willschm at us.ibm.com>


--- a/include/asm-ppc64/paca.h	2004-12-03 13:03:09.048520608 -0600
+++ b/include/asm-ppc64/paca.h	2004-12-03 13:18:17.433655752 -0600
@@ -99,11 +99,13 @@
  	u64 exdsi[8];		/* used for linear mapping hash table misses */

  	/*
-	 * iSeries structues which the hypervisor knows about - Not
-	 * sure if these particularly need to be cacheline aligned.
+	 * iSeries structues which the hypervisor knows about -
+	 * This structure should not cross a page boundary.
+	 * The vpa_init/register_vpa call is now known to fail if the lppaca
+	 * structure crosses a page boundary.
  	 * The lppaca is also used on POWER5 pSeries boxes.
  	 */
-	struct ItLpPaca lppaca __attribute__((aligned(0x80)));
+	struct ItLpPaca lppaca __attribute__((aligned(0x400)));
  #ifdef CONFIG_PPC_ISERIES
  	struct ItLpRegSave reg_save;
  #endif




More information about the Linuxppc64-dev mailing list