Re: [PATCH] Fix mpage_writepage() for pages with buffers

2017-10-11 Thread Matthew Wilcox
On Tue, Oct 10, 2017 at 01:31:44PM -0700, Linus Torvalds wrote: > On Tue, Oct 10, 2017 at 12:44 PM, Andrew Morton > wrote: > > > > This is all pretty mature code (isn't it?). Any idea why this bug > > popped up now? I have no idea why it's suddenly popped up. It

Re: [PATCH] Fix mpage_writepage() for pages with buffers

2017-10-10 Thread Linus Torvalds
On Tue, Oct 10, 2017 at 12:44 PM, Andrew Morton wrote: > > This is all pretty mature code (isn't it?). Any idea why this bug > popped up now? Also, while the patch looks sane, the clean_buffers(page, PAGE_SIZE); line really threw me. That's an insane value

Re: [PATCH] Fix mpage_writepage() for pages with buffers

2017-10-10 Thread Andrew Morton
On Fri, 6 Oct 2017 14:15:41 -0700 Matthew Wilcox wrote: > When using FAT on a block device which supports rw_page, we can hit > BUG_ON(!PageLocked(page)) in try_to_free_buffers(). This is because we > call clean_buffers() after unlocking the page we've written. Introduce a

Re: [PATCH] Fix mpage_writepage() for pages with buffers

2017-10-09 Thread Johannes Thumshirn
Acked-by: Johannes Thumshirn -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB

[PATCH] Fix mpage_writepage() for pages with buffers

2017-10-06 Thread Matthew Wilcox
When using FAT on a block device which supports rw_page, we can hit BUG_ON(!PageLocked(page)) in try_to_free_buffers(). This is because we call clean_buffers() after unlocking the page we've written. Introduce a new clean_page_buffers() which cleans all buffers associated with a page and call