Commit 2a28f98c authored by Fabian Frederick's avatar Fabian Frederick Committed by Linus Torvalds

ocfs2: use swap() in dx_leaf_sort_swap()

Use kernel.h macro definition.

Thanks to Julia Lawall for Coccinelle scripting support.
Signed-off-by: default avatarFabian Frederick <fabf@skynet.be>
Cc: Julia Lawall <julia.lawall@lip6.fr>
Cc: Mark Fasheh <mfasheh@suse.com>
Cc: Joel Becker <jlbec@evilplan.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent ae1f0814
...@@ -3543,13 +3543,10 @@ static void dx_leaf_sort_swap(void *a, void *b, int size) ...@@ -3543,13 +3543,10 @@ static void dx_leaf_sort_swap(void *a, void *b, int size)
{ {
struct ocfs2_dx_entry *entry1 = a; struct ocfs2_dx_entry *entry1 = a;
struct ocfs2_dx_entry *entry2 = b; struct ocfs2_dx_entry *entry2 = b;
struct ocfs2_dx_entry tmp;
BUG_ON(size != sizeof(*entry1)); BUG_ON(size != sizeof(*entry1));
tmp = *entry1; swap(*entry1, *entry2);
*entry1 = *entry2;
*entry2 = tmp;
} }
static int ocfs2_dx_leaf_same_major(struct ocfs2_dx_leaf *dx_leaf) static int ocfs2_dx_leaf_same_major(struct ocfs2_dx_leaf *dx_leaf)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment