diff options
author | Theodore Ts'o <tytso@mit.edu> | 2010-11-08 13:45:33 -0500 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2010-11-08 13:45:33 -0500 |
commit | 83668e7141c7a0aa4035bde94344b81f9cf966ab (patch) | |
tree | 34d9fd52470b475d6e9d88ece8ca1ba80bf85a42 /fs/ext4/ext4.h | |
parent | f7ad6d2e9201a6e1c9ee6530a291452eb695feb8 (diff) | |
download | linux-3.10-83668e7141c7a0aa4035bde94344b81f9cf966ab.tar.gz linux-3.10-83668e7141c7a0aa4035bde94344b81f9cf966ab.tar.bz2 linux-3.10-83668e7141c7a0aa4035bde94344b81f9cf966ab.zip |
ext4: fix potential race when freeing ext4_io_page structures
Use an atomic_t and make sure we don't free the structure while we
might still be submitting I/O for that page.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/ext4.h')
-rw-r--r-- | fs/ext4/ext4.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h index 670d1343f91..6a5edea2d70 100644 --- a/fs/ext4/ext4.h +++ b/fs/ext4/ext4.h @@ -177,7 +177,7 @@ struct mpage_da_data { struct ext4_io_page { struct page *p_page; - int p_count; + atomic_t p_count; }; #define MAX_IO_PAGES 128 |