]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
Fix a gfp.h BUG by masking off GFP flags before swiotlb_alloc_coherent.
authorChris Wright <chrisw@sous-sol.org>
Tue, 24 Jan 2006 19:37:47 +0000 (11:37 -0800)
committerChris Wright <chrisw@sous-sol.org>
Tue, 24 Jan 2006 19:37:47 +0000 (11:37 -0800)
Fix from Andi, fwd from Andrew.

queue/mask-off-GFP-flags-before-swiotlb_alloc_coherent.patch [new file with mode: 0644]
queue/series

diff --git a/queue/mask-off-GFP-flags-before-swiotlb_alloc_coherent.patch b/queue/mask-off-GFP-flags-before-swiotlb_alloc_coherent.patch
new file mode 100644 (file)
index 0000000..e69b053
--- /dev/null
@@ -0,0 +1,38 @@
+From stable-bounces@linux.kernel.org  Sat Jan 21 13:18:41 2006
+Date: Sat, 21 Jan 2006 13:13:13 -0800
+From: Andrew Morton <akpm@osdl.org>
+To: stable@kernel.org
+Message-Id: <20060121131313.551c624f.akpm@osdl.org>
+Cc: Andi Kleen <ak@muc.de>
+Subject: [PATCH] Mask off GFP flags before swiotlb_alloc_coherent
+
+From: Andi Kleen <ak@muc.de>
+
+Mask off GFP flags before swiotlb_alloc_coherent
+
+Signed-off-by: Andi Kleen <ak@suse.de>
+Signed-off-by: Chris Wright <chris@sous-sol.org>
+---
+
+akpm: Guys, this is a simple patch from Andi to fix a gfp.h BUG due to us
+passing bad gfp flags into gfp_zone.
+
+This is not a 2.6.16-x backport - because the pci-gart code in mainline gt
+radically redone.
+
+This is, I think, a new problem for -stable.  This code hasn't had the
+normal external testing...
+
+ arch/x86_64/kernel/pci-gart.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- linux-2.6.15.1.orig/arch/x86_64/kernel/pci-gart.c
++++ linux-2.6.15.1/arch/x86_64/kernel/pci-gart.c
+@@ -244,6 +244,7 @@ dma_alloc_coherent(struct device *dev, s
+                                          get_order(size));
+                               if (swiotlb) {
++                                      gfp &= ~(GFP_DMA32|GFP_DMA);
+                                       return
+                                       swiotlb_alloc_coherent(dev, size,
+                                                              dma_handle,
index 63f8dd271ccc32c86c3e1bdb826cb0b316e3febd..738fa17236a41578fbf04182fb2ef32d8bc76768 100644 (file)
@@ -6,3 +6,4 @@ fix-oops-in-ufs_fill_super-at-mount-time.patch
 elevator-as-back-compatibility.patch
 sparc64-fix-timekeeping-on-ultra-IIe-machines.patch
 net-make-second-arg-to-skb_reserved-signed.patch
+mask-off-GFP-flags-before-swiotlb_alloc_coherent.patch