]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: allocate backref_ctx on stack in find_extent_clone
authorGoldwyn Rodrigues <rgoldwyn@suse.com>
Tue, 27 Jul 2021 21:17:31 +0000 (16:17 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 23 Aug 2021 11:19:10 +0000 (13:19 +0200)
commit640d7b0ffc16442ca4771aa8cd92fcf5b2ba5b5b
tree7606a139f8de49c09b2e521ae443f4ce7542579f
parent8e415af622dff4ba5bebf606e9c24b065845c9ab
btrfs: allocate backref_ctx on stack in find_extent_clone

Instead of using kmalloc() to allocate backref_ctx, allocate backref_ctx
on stack. The size is reasonably small.

sizeof(backref_ctx) = 48

Reviewed-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: Goldwyn Rodrigues <rgoldwyn@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/send.c