Re: [PATCH 2/5] mm, highmem: remove useless pool_lock

From: Minchan Kim
Date: Sun Oct 28 2012 - 21:47:04 EST


On Mon, Oct 29, 2012 at 04:12:53AM +0900, Joonsoo Kim wrote:
> The pool_lock protects the page_address_pool from concurrent access.
> But, access to the page_address_pool is already protected by kmap_lock.
> So remove it.
>
> Signed-off-by: Joonsoo Kim <js1304@xxxxxxxxx>
Reviewed-by: Minchan Kin <minchan@xxxxxxxxxx>

Looks good to me.
Just a nitpick.

Please write comment about locking rule like below.

>
> diff --git a/mm/highmem.c b/mm/highmem.c
> index b3b3d68..017bad1 100644
> --- a/mm/highmem.c
> +++ b/mm/highmem.c
> @@ -328,7 +328,6 @@ struct page_address_map {
> * page_address_map freelist, allocated from page_address_maps.
> */

/* page_address_pool is protected by kmap_lock */

> static struct list_head page_address_pool; /* freelist */
> -static spinlock_t pool_lock; /* protects page_address_pool */
>

--
Kind regards,
Minchan Kim
--
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/