public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ppc64: Fix g5-only build
@ 2004-10-26  7:28 Benjamin Herrenschmidt
  2004-10-26 16:41 ` John Rose
  0 siblings, 1 reply; 3+ messages in thread
From: Benjamin Herrenschmidt @ 2004-10-26  7:28 UTC (permalink / raw)
  To: Andrew Morton; +Cc: Linus Torvalds, Linux Kernel list

Hi !

The iommu_free_table() patch broke g5 only build by adding back some incestuous
relationship between generic code and pSeries code.
This patch wraps this in #ifdef as a quick fix until the original author of the
patch comes up with a better solution.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>

Index: linux-work/arch/ppc64/kernel/prom.c
===================================================================
--- linux-work.orig/arch/ppc64/kernel/prom.c	2004-10-26 13:15:54.000000000 +1000
+++ linux-work/arch/ppc64/kernel/prom.c	2004-10-26 17:22:28.397358448 +1000
@@ -1818,8 +1818,13 @@
 		return -EBUSY;
 	}
 
+	/* XXX This is a layering violation, should be moved to the caller
+	 * --BenH.
+	 */
+#ifdef CONFIG_PPC_PSERIES
 	if (np->iommu_table)
 		iommu_free_table(np);
+#endif /* CONFIG_PPC_PSERIES */
 
 	write_lock(&devtree_lock);
 	OF_MARK_STALE(np);
Index: linux-work/include/asm-ppc64/iommu.h
===================================================================
--- linux-work.orig/include/asm-ppc64/iommu.h	2004-10-26 13:15:55.000000000 +1000
+++ linux-work/include/asm-ppc64/iommu.h	2004-10-26 17:19:17.086442128 +1000
@@ -111,9 +111,17 @@
 extern void iommu_setup_u3(void);
 
 /* Creates table for an individual device node */
+/* XXX: This isn't generic, please name it accordingly or add
+ * some ppc_md. hooks for iommu implementations to do what they
+ * need to do. --BenH.
+ */
 extern void iommu_devnode_init(struct device_node *dn);
 
 /* Frees table for an individual device node */
+/* XXX: This isn't generic, please name it accordingly or add
+ * some ppc_md. hooks for iommu implementations to do what they
+ * need to do. --BenH.
+ */
 extern void iommu_free_table(struct device_node *dn);
 
 #endif /* CONFIG_PPC_MULTIPLATFORM */



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2004-10-26 23:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-10-26  7:28 [PATCH] ppc64: Fix g5-only build Benjamin Herrenschmidt
2004-10-26 16:41 ` John Rose
2004-10-26 23:49   ` Benjamin Herrenschmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox