Thread (30 messages) 30 messages, 12 authors, 2011-06-12

Re: [PATCH] Make GFP_DMA allocations w/o ZONE_DMA emit a warning instead of failing

From: Dmitry Eremin-Solenikov <hidden>
Date: 2011-06-01 15:07:50
Also in: lkml

On 6/1/11, KOSAKI Motohiro [off-list ref] wrote:
2011/6/1 Dmitry Eremin-Solenikov [off-list ref]:
quoted
Please be more polite to other people. After a197b59ae6 all allocations
with GFP_DMA set on nodes without ZONE_DMA fail nearly silently (only
one warning during bootup is emited, no matter how many things fail).
This is a very crude change on behaviour. To be more civil, instead of
failing emit noisy warnings each time smbd. tries to allocate a GFP_DMA
memory on non-ZONE_DMA node.

This change should be reverted after one or two major releases, but
we should be more accurate rather than hoping for the best.

Signed-off-by: Dmitry Eremin-Solenikov <redacted>
Cc: David Rientjes <rientjes@google.com>
Cc: Russell King - ARM Linux <redacted>
Cc: Mel Gorman <redacted>
Cc: KOSAKI Motohiro <redacted>
Cc: KAMEZAWA Hiroyuki <redacted>
Cc: Rik van Riel <redacted>
Cc: Andrew Morton <akpm@linux-foundation.org>
Instaed of, shouldn't we revert a197b59ae6? Some arch don't have
DMA_ZONE at all.
and a197b59ae6 only care x86 embedded case. If we accept your patch, I
can imagine
other people will claim warn foold is a bug. ;)
I think that argument from a197b59ae6 is correct. Allocating with GFP_DMA
should fail if there is no ZONE_DMA. On the other hand linux/gfp.h clearly
specifies: "...Ignored on some platforms, used as appropriate on others".

So it's up to mm gurus to decide which way is correct. I'd be happy as long
as we don't have such nasty change of behaviour.
However, I think, you should explain which platform and drivers hit
this breakage.
Otherwise developers can't learn which platform should care.
I've hit this with IrDA driver on PXA. Also I've seen the report regarding
other ARM platform (ep-something). Thus I've included Russell in the cc.

-- 
With best wishes
Dmitry

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help