Re: [patch] mm: compaction: make compact_control order signed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 02/01/2012 09:41 AM, Dan Carpenter wrote:
"order" is -1 when compacting via /proc/sys/vm/compact_memory.  Making
it unsigned causes a bug in __compact_pgdat() when we test:

	if (cc->order<  0 || !compaction_deferred(zone, cc->order))
		compact_zone(zone, cc);

Good catch!  I had not even thought to check whether
order was signed in struct compact_control, when I
saw code using -1 as an order in various places :)

Signed-off-by: Dan Carpenter<dan.carpenter@xxxxxxxxxx>

Reviewed-by: Rik van Riel <riel@xxxxxxxxxx>

--
All rights reversed

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  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@xxxxxxxxx";> email@xxxxxxxxx </a>


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]