Re: [PATCH 1/3] [BUGFIX] memory hotplug: fix next blockcalculation in is_removable

From: Mel Gorman
Date: Wed Sep 08 2010 - 07:23:24 EST


On Tue, Sep 07, 2010 at 10:32:44AM +0900, KAMEZAWA Hiroyuki wrote:
> From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx>
>
> next_active_pageblock() is for finding next _used_ freeblock. It skips
> several blocks when it finds there are a chunk of free pages lager than
> pageblock. But it has 2 bugs.
>
> 1. We have no lock. page_order(page) - pageblock_order can be minus.
> 2. pageblocks_stride += is wrong. it should skip page_order(p) of pages.
>
> Changelog: 2010/09/07
> - fix range check of order returned by page_order().
>
> Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx>

Acked-by: Mel Gorman <mel@xxxxxxxxx>

--
Mel Gorman
Part-time Phd Student Linux Technology Center
University of Limerick IBM Dublin Software Lab
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/