Re: [PATCH] [0/13] General DMA zone rework

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Luiz Fernando N. Capitulino
Date: Tuesday, March 11, 2008 - 10:26 am

Em Mon, 10 Mar 2008 19:08:43 +0100
Andi Kleen <andi@firstfloor.org> escreveu:

| > you have or only the subset you posted?
| 
| Best you test all together. The subsets are independent
| (as in kernel should work with any subset of them), but 
| they all clean up DMA memory related issues.

 Ok, now it works with the test case fixed:

"""
testing mask alloc upto 24 bits
verify & free
mask fffff
mask 1fffff
mask 3fffff
mask 7fffff
mask ffffff
done
"""

 Do you remember the BUG_ON() I was getting because of the
sound card driver [1] ?

 It seems to me that the problem is that it's setting
__GFP_COMP. The following patch fixes it for me:

"""
Index: linux-2.6.24/sound/core/memalloc.c
===================================================================
--- linux-2.6.24.orig/sound/core/memalloc.c
+++ linux-2.6.24/sound/core/memalloc.c
@@ -218,7 +218,6 @@ static void *snd_malloc_dev_pages(struct
 	snd_assert(dma != NULL, return NULL);
 	pg = get_order(size);
 	gfp_flags = GFP_KERNEL
-		| __GFP_COMP	/* compound page lets parts be mapped */
 		| __GFP_NORETRY /* don't trigger OOM-killer */
 		| __GFP_NOWARN; /* no stack trace print - this call is non-critical */
 	res = dma_alloc_coherent(dev, PAGE_SIZE << pg, dma, gfp_flags);
"""

 Also, I think you forgot to protect the __free_pages_mask()
call with "#ifdef CONFIG_MASK_ALLOC" in patch mask-compat.

 Question: let's say that the devices I have consumes only
5MB of the whole reserved pool (16MB), of course that it's
ok to reduce the pool to 5MB, right?

 I have more machines to test this stuff...

[1] http://users.mandriva.com.br/~lcapitulino/tmp/minicom.cap

-- 
Luiz Fernando N. Capitulino
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] [0/13] General DMA zone rework, Andi Kleen, (Fri Mar 7, 2:07 am)
[PATCH] [2/13] Make get_order(0) return 0, Andi Kleen, (Fri Mar 7, 2:07 am)
[PATCH] [3/13] Make kvm bad_page symbol static, Andi Kleen, (Fri Mar 7, 2:07 am)
[PATCH] [6/13] Core maskable allocator, Andi Kleen, (Fri Mar 7, 2:07 am)
[PATCH] [7/13] Implement compat hooks for GFP_DMA, Andi Kleen, (Fri Mar 7, 2:07 am)
[PATCH] [8/13] Enable the mask allocator for x86, Andi Kleen, (Fri Mar 7, 2:07 am)
[PATCH] [9/13] Remove set_dma_reserve, Andi Kleen, (Fri Mar 7, 2:07 am)
Re: [PATCH] [6/13] Core maskable allocator, Johannes Weiner, (Fri Mar 7, 3:53 am)
Re: [PATCH] [6/13] Core maskable allocator, Andi Kleen, (Fri Mar 7, 4:14 am)
Re: [PATCH] [0/13] General DMA zone rework, Rene Herman, (Fri Mar 7, 8:18 am)
Re: [PATCH] [0/13] General DMA zone rework, Rene Herman, (Fri Mar 7, 8:22 am)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Fri Mar 7, 8:31 am)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Fri Mar 7, 8:34 am)
Re: [PATCH] [6/13] Core maskable allocator, Randy Dunlap, (Fri Mar 7, 10:05 am)
Re: [PATCH] [6/13] Core maskable allocator, Andi Kleen, (Fri Mar 7, 10:31 am)
Re: [PATCH] [6/13] Core maskable allocator, Randy Dunlap, (Fri Mar 7, 10:33 am)
Re: [PATCH] [6/13] Core maskable allocator, Andi Kleen, (Fri Mar 7, 10:43 am)
Re: [PATCH] [6/13] Core maskable allocator, Randy Dunlap, (Fri Mar 7, 10:51 am)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Sam Ravnborg, (Fri Mar 7, 11:32 am)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Andi Kleen, (Fri Mar 7, 12:03 pm)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Sam Ravnborg, (Fri Mar 7, 12:09 pm)
Re: [PATCH] [0/13] General DMA zone rework, Luiz Fernando N. Cap ..., (Fri Mar 7, 1:51 pm)
Re: [PATCH] [6/13] Core maskable allocator, Cyrill Gorcunov, (Fri Mar 7, 2:13 pm)
Re: [PATCH] [6/13] Core maskable allocator, Andi Kleen, (Fri Mar 7, 4:28 pm)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Fri Mar 7, 5:46 pm)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Christoph Lameter, (Fri Mar 7, 7:37 pm)
Re: [PATCH] [0/13] General DMA zone rework, Christoph Lameter, (Fri Mar 7, 7:42 pm)
Re: [PATCH] [6/13] Core maskable allocator, KAMEZAWA Hiroyuki, (Fri Mar 7, 10:03 pm)
Re: [PATCH] [6/13] Core maskable allocator, KAMEZAWA Hiroyuki, (Fri Mar 7, 10:41 pm)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Yinghai Lu, (Fri Mar 7, 11:35 pm)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Christoph Lameter, (Sat Mar 8, 12:31 am)
Re: [PATCH] [6/13] Core maskable allocator, Andi Kleen, (Sat Mar 8, 4:41 am)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Sat Mar 8, 4:57 am)
Re: [PATCH] [8/13] Enable the mask allocator for x86, Christoph Lameter, (Mon Mar 10, 10:13 am)
Re: [PATCH] [0/13] General DMA zone rework, Christoph Lameter, (Mon Mar 10, 10:14 am)
Re: [PATCH] [0/13] General DMA zone rework, Luiz Fernando N. Cap ..., (Mon Mar 10, 11:03 am)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Mon Mar 10, 11:08 am)
Re: [PATCH] [6/13] Core maskable allocator , Jonathan Corbet, (Tue Mar 11, 8:34 am)
Re: [PATCH] [6/13] Core maskable allocator, Andi Kleen, (Tue Mar 11, 8:54 am)
Re: [PATCH] [0/13] General DMA zone rework, Luiz Fernando N. Cap ..., (Tue Mar 11, 10:26 am)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Tue Mar 11, 10:35 am)
Re: [PATCH] [0/13] General DMA zone rework, Luiz Fernando N. Cap ..., (Tue Mar 11, 11:00 am)
Re: [PATCH] [0/13] General DMA zone rework, Andi Kleen, (Tue Mar 11, 11:49 am)
Re: [PATCH] [0/13] General DMA zone rework, Luiz Fernando N. Cap ..., (Tue Mar 11, 12:36 pm)