[PATCH] xfs: stop using the page cache to back the buffer cache

Christoph Hellwig hch at infradead.org
Fri Mar 11 04:16:42 CST 2011


> +		if (((unsigned long)(bp->b_addr + bp->b_buffer_length - 1) &
> +								PAGE_MASK) !=
> +		    ((unsigned long)bp->b_addr & PAGE_MASK)) {
> +			/* b_addr spans two pages - use alloc_page instead */
> +			kmem_free(bp->b_addr);
> +			bp->b_addr = NULL;
> +			goto use_alloc_page;
> +		}

Did you manage to hit this case?  If it happens with any frequency under
real workloads we really need to find a wayto avoid the allocation to
start with.


Otherwise looks good,

Reviewed-by: Christoph Hellwig <hch at lst.de>




More information about the xfs mailing list