[XFS] Fix racy access to pb_flags. pagebuf_rele() modified pb_flags after
the pagebuf had been unlocked if the buffer was delwri. At high load, this could result in a race when the superblock was being synced that would result the flags being incorrect and the iodone functions being executed incorrectly. This then leads to iclog callback failures or AIL list corruptions resulting in filesystem shutdowns. SGI-PV: 923981 SGI-Modid: xfs-linux:xfs-kern:23616a Signed-off-by: David Chinner <dgc@sgi.com> Signed-off-by: Nathan Scott <nathans@sgi.com>
This commit is contained in:
committed by
Nathan Scott
parent
ba403ab43e
commit
2f92658751
@ -89,6 +89,7 @@ typedef enum page_buf_flags_e { /* pb_flags values */
|
||||
_PBF_PAGE_CACHE = (1 << 17),/* backed by pagecache */
|
||||
_PBF_KMEM_ALLOC = (1 << 18),/* backed by kmem_alloc() */
|
||||
_PBF_RUN_QUEUES = (1 << 19),/* run block device task queue */
|
||||
_PBF_DELWRI_Q = (1 << 21), /* buffer on delwri queue */
|
||||
} page_buf_flags_t;
|
||||
|
||||
#define PBF_UPDATE (PBF_READ | PBF_WRITE)
|
||||
@ -337,8 +338,6 @@ extern void pagebuf_trace(
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/* These are just for xfs_syncsub... it sets an internal variable
|
||||
* then passes it to VOP_FLUSH_PAGES or adds the flags to a newly gotten buf_t
|
||||
*/
|
||||
|
Reference in New Issue
Block a user