Re: [PATCH] btrfs: oops in device_list_add()

2019-01-28 Thread David Sterba
On Sun, Jan 27, 2019 at 04:58:00AM +, Al Viro wrote: > alloc_fs_devices() can return ERR_PTR(-ENOMEM), so > dereferencing its result before the check for IS_ERR() is > a bad idea... > > Fixes: d1a63002829a4 > Signed-off-by: Al Viro Thanks, added to 5.0-rc queue.

Re: [PATCH] btrfs: oops in device_list_add()

2019-01-28 Thread Anand Jain
On 1/27/19 12:58 PM, Al Viro wrote: alloc_fs_devices() can return ERR_PTR(-ENOMEM), so dereferencing its result before the check for IS_ERR() is a bad idea... Fixes: d1a63002829a4 Signed-off-by: Al Viro nice catch. Reviewed-by: Anand Jain --- diff --git a/fs/btrfs/volumes.c b/

Re: [PATCH] btrfs: oops in device_list_add()

2019-01-27 Thread Nikolay Borisov
On 27.01.19 г. 6:58 ч., Al Viro wrote: > alloc_fs_devices() can return ERR_PTR(-ENOMEM), so > dereferencing its result before the check for IS_ERR() is > a bad idea... > > Fixes: d1a63002829a4 > Signed-off-by: Al Viro Thought this was already fixed, doh... Reviewed-by: Nikolay Borisov

[PATCH] btrfs: oops in device_list_add()

2019-01-26 Thread Al Viro
alloc_fs_devices() can return ERR_PTR(-ENOMEM), so dereferencing its result before the check for IS_ERR() is a bad idea... Fixes: d1a63002829a4 Signed-off-by: Al Viro --- diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index 85149f27644d..72adc5643bde 100644 --- a/fs/btrfs/volumes.c