rpms/kernel/F-11 linux-2.6-ppc64-vs-broadcom.patch, 1.1, 1.2 kernel.spec, 1.1713, 1.1714

David Woodhouse dwmw2 at fedoraproject.org
Fri Aug 21 10:08:51 UTC 2009


Author: dwmw2

Update of /cvs/pkgs/rpms/kernel/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv23535

Modified Files:
	kernel.spec 
Added Files:
	linux-2.6-ppc64-vs-broadcom.patch 
Log Message:
backport fix for 514787

linux-2.6-ppc64-vs-broadcom.patch:
 dma.c |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

Index: linux-2.6-ppc64-vs-broadcom.patch
===================================================================
RCS file: linux-2.6-ppc64-vs-broadcom.patch
diff -N linux-2.6-ppc64-vs-broadcom.patch
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ linux-2.6-ppc64-vs-broadcom.patch	21 Aug 2009 10:08:51 -0000	1.2
@@ -0,0 +1,48 @@
+From b2f2e8fee3d62f621e795f25b2fc0f51bbdb4af9 Mon Sep 17 00:00:00 2001
+From: Benjamin Herrenschmidt <benh at kernel.crashing.org>
+Date: Mon, 10 Aug 2009 16:36:38 +1000
+Subject: [PATCH] powerpc/dma: pci_set_dma_mask() shouldn't fail if mask fits in RAM
+
+On an iMac G5, the b43 driver is failing to initialise because trying to
+set the dma mask to 30-bit fails. Even though there's only 512MiB of RAM
+in the machine anyway:
+	https://bugzilla.redhat.com/show_bug.cgi?id=514787
+
+We should probably let it succeed if the available RAM in the system
+doesn't exceed the requested limit.
+
+Signed-off-by: David Woodhouse <David.Woodhouse at intel.com>
+Signed-off-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
+---
+ arch/powerpc/kernel/dma.c |    6 +++---
+ 1 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/arch/powerpc/kernel/dma.c b/arch/powerpc/kernel/dma.c
+index 20a60d6..ccf129d 100644
+--- a/arch/powerpc/kernel/dma.c
++++ b/arch/powerpc/kernel/dma.c
+@@ -7,6 +7,7 @@
+ 
+ #include <linux/device.h>
+ #include <linux/dma-mapping.h>
++#include <linux/lmb.h>
+ #include <asm/bug.h>
+ #include <asm/abs_addr.h>
+ 
+@@ -90,11 +91,10 @@ static void dma_direct_unmap_sg(struct device *dev, struct scatterlist *sg,
+ static int dma_direct_dma_supported(struct device *dev, u64 mask)
+ {
+ #ifdef CONFIG_PPC64
+-	/* Could be improved to check for memory though it better be
+-	 * done via some global so platforms can set the limit in case
++	/* Could be improved so platforms can set the limit in case
+ 	 * they have limited DMA windows
+ 	 */
+-	return mask >= DMA_BIT_MASK(32);
++	return mask >= (lmb_end_of_DRAM() - 1);
+ #else
+ 	return 1;
+ #endif
+-- 
+1.6.2.5
+


Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-11/kernel.spec,v
retrieving revision 1.1713
retrieving revision 1.1714
diff -u -p -r1.1713 -r1.1714
--- kernel.spec	19 Aug 2009 14:21:39 -0000	1.1713
+++ kernel.spec	21 Aug 2009 10:08:50 -0000	1.1714
@@ -605,6 +605,7 @@ Patch141: linux-2.6-ps3-storage-alias.pa
 Patch143: linux-2.6-g5-therm-shutdown.patch
 Patch144: linux-2.6-vio-modalias.patch
 Patch147: linux-2.6-imac-transparent-bridge.patch
+Patch148: linux-2.6-ppc64-vs-broadcom.patch
 
 Patch150: linux-2.6.29-sparc-IOC_TYPECHECK.patch
 
@@ -1161,7 +1162,9 @@ ApplyPatch linux-2.6-g5-therm-shutdown.p
 ApplyPatch linux-2.6-vio-modalias.patch
 # Work around PCIe bridge setup on iSight
 ApplyPatch linux-2.6-imac-transparent-bridge.patch
-
+# Fix b43 support on no-iommu devices with <1GiB RAM
+ApplyPatch linux-2.6-ppc64-vs-broadcom.patch
+ 
 #
 # SPARC64
 #
@@ -1903,6 +1906,9 @@ fi
 # and build.
 
 %changelog
+* Fri Aug 21 2009 David Woodhouse <David.Woodhouse at intel.com>
+- Fix b43 on iMac G5 (#514787)
+
 * Tue Aug 18 2009 Kyle McMartin <kyle at redhat.com>
 - Backport several upstream commits 52dec22e739eec8f3a0154f768a599f5489048bd
   to improve mmap_min_addr.




More information about the scm-commits mailing list