]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: use list_last_entry in add_falloc_range
authorNikolay Borisov <nborisov@suse.com>
Mon, 31 May 2021 07:37:03 +0000 (10:37 +0300)
committerDavid Sterba <dsterba@suse.com>
Mon, 21 Jun 2021 13:19:07 +0000 (15:19 +0200)
commit733a7bc22826322a47e1b03bb42e4b8f38c0dd5f
treeefc89545f5b39d978604feca6ae9719e4876fb93
parent50356eae9f4e8e3abc2229da7988c4d4a5805f32
btrfs: use list_last_entry in add_falloc_range

Instead of calling list_entry with head->prev simply call
list_last_entry which makes it obvious which member of the list is
being referred. This allows to remove the extra 'prev' pointer.

Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/file.c