Re: [PATCHv2 2/2] mm: downgrade VM_BUG in isolate_lru_page() to warning

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

 



On Tue 02-02-16 19:21:01, Kirill A. Shutemov wrote:
> Calling isolate_lru_page() is wrong and shouldn't happen, but it not
> nessesary fatal: the page just will not be isolated if it's not on LRU.
> 
> Let's downgrade the VM_BUG_ON_PAGE() to WARN_RATELIMIT().

This will trigger for !CONFIG_DEBUG_VM as well which I am not sure is
necessary. I guess isolate_lru_page is not such a hot path so this would
be acceptable.

> Signed-off-by: Kirill A. Shutemov <kirill.shutemov@xxxxxxxxxxxxxxx>

Anyway
Acked-by: Michal Hocko <mhocko@xxxxxxxx>

> ---
>  mm/vmscan.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/mm/vmscan.c b/mm/vmscan.c
> index eb3dd37ccd7c..71b1c29948db 100644
> --- a/mm/vmscan.c
> +++ b/mm/vmscan.c
> @@ -1443,7 +1443,7 @@ int isolate_lru_page(struct page *page)
>  	int ret = -EBUSY;
>  
>  	VM_BUG_ON_PAGE(!page_count(page), page);
> -	VM_BUG_ON_PAGE(PageTail(page), page);
> +	WARN_RATELIMIT(PageTail(page), "trying to isolate tail page");
>  
>  	if (PageLRU(page)) {
>  		struct zone *zone = page_zone(page);
> -- 
> 2.7.0
> 

-- 
Michal Hocko
SUSE Labs

--
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/ .
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]