Home
last modified time | relevance | path

Searched hist:"7286 a35e" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/fs/afs/
H A Dwrite.c7286a35e Thu Mar 16 11:27:48 CDT 2017 David Howells <dhowells@redhat.com> afs: Fix afs_kill_pages()

Fix afs_kill_pages() in two ways:

(1) If a writeback has been partially flushed, then if we try and kill the
pages it contains, some of them may no longer be undergoing writeback
and end_page_writeback() will assert.

Fix this by checking to see whether the page in question is actually
undergoing writeback before ending that writeback.

(2) The loop that scans for pages to kill doesn't increase the first page
index, and so the loop may not terminate, but it will try to process
the same pages over and over again.

Fix this by increasing the first page index to one after the last page
we processed.

Signed-off-by: David Howells <dhowells@redhat.com>
7286a35e Thu Mar 16 11:27:48 CDT 2017 David Howells <dhowells@redhat.com> afs: Fix afs_kill_pages()

Fix afs_kill_pages() in two ways:

(1) If a writeback has been partially flushed, then if we try and kill the
pages it contains, some of them may no longer be undergoing writeback
and end_page_writeback() will assert.

Fix this by checking to see whether the page in question is actually
undergoing writeback before ending that writeback.

(2) The loop that scans for pages to kill doesn't increase the first page
index, and so the loop may not terminate, but it will try to process
the same pages over and over again.

Fix this by increasing the first page index to one after the last page
we processed.

Signed-off-by: David Howells <dhowells@redhat.com>