1 ext4: use swap() in mext_page_double_lock()
3 From: Fabian Frederick <fabf@skynet.be>
5 Use kernel.h macro definition.
7 Thanks to Julia Lawall for Coccinelle scripting support.
9 Signed-off-by: Fabian Frederick <fabf@skynet.be>
10 Signed-off-by: Theodore Ts'o <tytso@mit.edu>
12 fs/ext4/move_extent.c | 9 +++------
13 1 file changed, 3 insertions(+), 6 deletions(-)
15 diff --git a/fs/ext4/move_extent.c b/fs/ext4/move_extent.c
16 index 370420b..8c04afb 100644
17 --- a/fs/ext4/move_extent.c
18 +++ b/fs/ext4/move_extent.c
19 @@ -166,12 +166,9 @@ mext_page_double_lock(struct inode *inode1, struct inode *inode2,
21 wait_on_page_writeback(page[0]);
22 wait_on_page_writeback(page[1]);
23 - if (inode1 > inode2) {
29 + if (inode1 > inode2)
30 + swap(page[0], page[1]);