Re: [patch 3/8] mm: rotate_reclaimable_page() cleanup

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

 



On Mon, 2008-03-17 at 20:19 +0100, Miklos Szeredi wrote:
> plain text document attachment (rotate_reclaimable_page_cleanup.patch)
> From: Miklos Szeredi <mszeredi@xxxxxxx>
> 
> Clean up messy conditional calling of test_clear_page_writeback() from
> both rotate_reclaimable_page() and end_page_writeback().

> -int rotate_reclaimable_page(struct page *page)
> +void  rotate_reclaimable_page(struct page *page)
>  {
> -	struct pagevec *pvec;
> -	unsigned long flags;
> -
> -	if (PageLocked(page))
> -		return 1;
> -	if (PageDirty(page))
> -		return 1;
> -	if (PageActive(page))
> -		return 1;
> -	if (!PageLRU(page))
> -		return 1;

Might be me, but I find the above easier to read than

> +	if (!PageLocked(page) && !PageDirty(page) && !PageActive(page) &&
> +	    PageLRU(page)) {
>  



--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux