login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2008
»
May
»
9
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Glauber Costa
Subject:
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
Date: Friday, May 9, 2008 - 5:48 am
Takashi Iwai wrote:
quoted text
> At Fri, 09 May 2008 03:37:54 +0200, > Rene Herman wrote: >> Good day. >> >> commit 8779f2fc3b84ebb6c5181fb13d702e9944c16069 >> >> "x86: don't try to allocate from DMA zone at first" >> >> breaks all of ISA DMA. Or all of ALSA ISA DMA at least. All >> ISA soundcards are silent following that commit -- no error >> messages, everything appears fine, just silence. >> >> It won't just revert due to 32/64 merge. >> >> Rene. > > Thanks for catching it. Yeah, the patch looks buggy. We had an > implicit assumption that dev = NULL for ISA devices that require 24bit > DMA. > > How about the patch below? It's against the latest Linus git tree. > > > thanks, > > Takashi > > > [PATCH] x86: Fix dma_alloc_coherent() for ISA devices > > The recent work on x86 dma_alloc_coherent() breaks the ISA DMA buffer > allocation, which is represented by "dev = NULL" and requires 24bit > DMA implicitly. > > Signed-off-by: Takashi Iwai <tiwai@suse.de>
Woke up and saw it, got worried, but there is already a fix. ;-) Nice work! And thank you
quoted text
> --- > > diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c > index 0c37f16..c5ef1af 100644 > --- a/arch/x86/kernel/pci-dma.c > +++ b/arch/x86/kernel/pci-dma.c > @@ -385,11 +385,13 @@ dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_handle, > if (dma_alloc_from_coherent_mem(dev, size, dma_handle, &memory)) > return memory; > > - if (!dev) > + if (!dev) { > dev = &fallback_dev; > + gfp |= GFP_DMA; > + } > dma_mask = dev->coherent_dma_mask; > if (dma_mask == 0) > - dma_mask = DMA_32BIT_MASK; > + dma_mask = (gfp & GFP_DMA) ? DMA_24BIT_MASK : DMA_32BIT_MASK; > > /* Device not DMA able */ > if (dev->dma_mask == NULL) > @@ -403,7 +405,7 @@ dma_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_handle, > larger than 16MB and in this case we have a chance of > finding fitting memory in the next higher zone first. If > not retry with true GFP_DMA. -AK */ > - if (dma_mask <= DMA_32BIT_MASK) > + if (dma_mask <= DMA_32BIT_MASK && !(gfp & GFP_DMA)) > gfp |= GFP_DMA32; > #endif >
--
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Thu May 8, 6:37 pm)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Takashi Iwai
, (Thu May 8, 11:06 pm)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Ingo Molnar
, (Fri May 9, 1:55 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Ingo Molnar
, (Fri May 9, 1:58 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Fri May 9, 5:03 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Ingo Molnar
, (Fri May 9, 5:28 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Pete Clements
, (Fri May 9, 5:29 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Glauber Costa
, (Fri May 9, 5:48 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Jesse Barnes
, (Fri May 9, 10:20 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Fri May 9, 4:00 pm)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Ingo Molnar
, (Tue May 13, 7:36 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Tue May 13, 8:26 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Bjorn Helgaas
, (Tue May 13, 9:59 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Alan Cox
, (Tue May 13, 10:01 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Tue May 13, 10:33 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Bjorn Helgaas
, (Tue May 13, 4:18 pm)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Takashi Iwai
, (Wed May 14, 2:25 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Wed May 14, 5:46 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Takashi Iwai
, (Wed May 14, 6:01 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Bjorn Helgaas
, (Wed May 14, 8:26 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Wed May 14, 8:40 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Takashi Iwai
, (Wed May 14, 8:53 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Wed May 14, 11:41 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Bjorn Helgaas
, (Wed May 14, 11:50 am)
Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Wed May 14, 12:09 pm)
[PATCH] Re: 2.6.26-rc1 regression: ISA DMA broken (bisected)
, Rene Herman
, (Fri May 30, 2:15 pm)
[DEVICE MODEL] dev->dma_mask
, Rene Herman
, (Fri May 30, 2:28 pm)
Re: [PATCH] Re: 2.6.26-rc1 regression: ISA DMA broken (bis ...
, Bjorn Helgaas
, (Fri May 30, 2:43 pm)
Re: [PATCH] Re: 2.6.26-rc1 regression: ISA DMA broken (bis ...
, Rene Herman
, (Fri May 30, 3:11 pm)
[PATCH] ISA: set 24-bit dma_mask for ISA devices.
, Rene Herman
, (Fri May 30, 3:37 pm)
Re: [PATCH] ISA: set 24-bit dma_mask for ISA devices.
, Andrew Morton
, (Fri May 30, 3:55 pm)
Re: [PATCH] ISA: set 24-bit dma_mask for ISA devices.
, Rene Herman
, (Fri May 30, 4:50 pm)
[PATCH] PNP: set the pnp_card dma_mask for use by ISAPnP cards
, Rene Herman
, (Fri May 30, 4:54 pm)
[PATCH] ISA: set 24-bit dma_mask for ISA devices.
, Rene Herman
, (Fri May 30, 4:55 pm)
Re: [PATCH] PNP: set the pnp_card dma_mask for use by ISAP ...
, Takashi Iwai
, (Sat May 31, 1:55 am)
Re: [PATCH] ISA: set 24-bit dma_mask for ISA devices.
, Takashi Iwai
, (Sat May 31, 1:56 am)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Ingo Molnar
Re: [patch 00/13] Syslets, "Threadlets", generic AIO support, v3
Vivek Goyal
[PATCH] x86_64: Display more intutive error message if kernel is not 2MB aligned
Andi Kleen
[PATCH] [0/35] Some x86 2.6.22 candidate patches for review
Andrew Morton
Re: [PATCH] lazy freeing of memory through MADV_FREE 2/2
Peter Zijlstra
Re: [RFC PATCH 1/2] Marker probes in futex.c
git
:
Felipe Contreras
Re: [kernel.org users] [RFD] On deprecating "git-foo" for builtins
Johannes Schindelin
[PATCH] fetch: refuse to fetch into the current branch in a non-bare repository
Johannes Schindelin
Re: [PATCH] Fix install-doc-quick target
Nicolas Pitre
Re: About git and the use of SHA-1
Alex Riesen
Re: git exclude patterns for directory
linux-netdev
:
Ursula Braun
[patch 2/8] [PATCH] af_iucv: sync sk shutdown flag if iucv path is quiesced
David Dillow
Re: [PATCH 2.6.30-rc4] r8169: avoid losing MSI interrupts
Andi Kleen
Re: RFC: Nagle latency tuning
Paul E. McKenney
Re: [PATCH 1/3] rcu: Introduce hlist_nulls variant of hlist
Russell King
Re: [BUG] New Kernel Bugs
git-commits-head
:
Linux Kernel Mailing List
sh: Fix compile error by operands(mov.l) in sh3/entry.S
Linux Kernel Mailing List
New device ID for sc92031 [1088:2031]
Linux Kernel Mailing List
powerpc/kexec: Add support for FSL-BookE
Linux Kernel Mailing List
drivers/acpi: use kasprintf
Linux Kernel Mailing List
[ARM] 5388/1: Add hwcap bits for VFPv3 and VFPv3D16
openbsd-misc
:
Andres Salazar
About priorities in /etc/resolv.conf
Rob Shepherd
x86 hardware for router system
Henning Brauer
Re: Sun Blade 1000?
Mitja Muženič
Re: isakmpd -- NCP IPsec client: peer proposed invalid phase 2 IDs
Damien Miller
Re: Patching a SSH 'Weakness'
Colocation donated by:
Syndicate