Message ID | 20220113210825.h8DHZZey9%akpm@linux-foundation.org |
---|---|
State | New |
Headers | show |
Series | [to-be-updated] btrfs-avoid-live-lock-in-search_ioctl-on-hardware-with-sub-page-faults.patch removed from -mm tree | expand |
--- a/fs/btrfs/ioctl.c~btrfs-avoid-live-lock-in-search_ioctl-on-hardware-with-sub-page-faults +++ a/fs/btrfs/ioctl.c @@ -2225,7 +2225,8 @@ static noinline int search_ioctl(struct while (1) { ret = -EFAULT; - if (fault_in_writeable(ubuf + sk_offset, *buf_size - sk_offset)) + if (fault_in_exact_writeable(ubuf + sk_offset, + *buf_size - sk_offset)) break; ret = btrfs_search_forward(root, &key, path, sk->min_transid);