linux/fs
Cliff Chen 24dace7355 ANDROID: fuse: fix deadlock for reply of FUSE_CANONICAL_PATH
There is a deadlock when the reply of FUSE_CANONICAL_PATH from user-
space client, because the kern_path function will issue a new request
and wait the respond from client which has been in wait state. The ba-
cktrace is like this:

<6>[  518.977731] ntfs-3g         S    0  2138      1 0x04000000
<4>[  518.977745] Call trace:
<4>[  518.977757]  __switch_to+0x130/0x13c
<4>[  518.977767]  __schedule+0x740/0x964
<4>[  518.977777]  schedule+0x70/0x90
<4>[  518.977794]  __fuse_request_send+0x1a0/0x340
<4>[  518.977808]  fuse_simple_request+0x178/0x1c8
<4>[  518.977818]  fuse_lookup_name+0xfc/0x220
<4>[  518.977829]  fuse_lookup+0x48/0x134
<4>[  518.977842]  __lookup_slow+0xc8/0x154
<4>[  518.977853]  walk_component+0x1c0/0x728
<4>[  518.977863]  path_lookupat+0xa8/0x208
<4>[  518.977875]  filename_lookup+0x8c/0x190
<4>[  518.977887]  kern_path+0x30/0x3c
<4>[  518.977901]  fuse_dev_do_write+0x79c/0x114c
<4>[  518.977914]  fuse_dev_write+0x60/0x84
<4>[  518.977928]  do_iter_readv_writev+0x11c/0x158
<4>[  518.977941]  do_iter_write+0x7c/0x1b8
<4>[  518.977953]  vfs_writev+0x84/0xe8
<4>[  518.977966]  do_writev+0x78/0x114
<4>[  518.977979]  __arm64_sys_writev+0x1c/0x24
<4>[  518.977992]  el0_svc_common+0x98/0x160
<4>[  518.978005]  el0_svc_handler+0x5c/0x64
<4>[  518.978015]  el0_svc+0x8/0xc

Fixes: fa199896a3 ("ANDROID: fuse: Add support for d_canonical_path")
Signed-off-by: Cliff Chen <cliff.chen@rock-chips.com>
Change-Id: I13487e5c956c4537c2554a44208d6664653ef4f1
2021-06-08 09:38:35 +08:00
..
9p rk: revert to v4.19 2021-03-17 18:05:39 +08:00
adfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
affs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
afs Merge 5.10.26 into android12-5.10-lts 2021-03-25 17:15:27 +01:00
autofs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
befs
bfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
btrfs Merge 5.10.27 into android12-5.10 2021-04-02 15:25:50 +02:00
cachefiles fs/cachefiles: Remove wait_bit_key layout dependency 2021-03-30 14:32:07 +02:00
ceph rk: revert to v4.19 2021-03-17 18:05:39 +08:00
cifs Merge 5.10.29 into android12-5.10 2021-04-11 09:11:53 +02:00
coda rk: revert to v4.19 2021-03-17 18:05:39 +08:00
configfs FROMLIST: configfs: make directories inherit uid/gid from creator 2021-03-24 21:32:54 +00:00
cramfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
crypto rk: revert to v4.19 2021-03-17 18:05:39 +08:00
debugfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
devpts rk: revert to v4.19 2021-03-17 18:05:39 +08:00
dlm rk: revert to v4.19 2021-03-17 18:05:39 +08:00
ecryptfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
efivarfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
efs
erofs This is the 5.10.21 stable release 2021-03-07 12:53:30 +01:00
exfat exfat: fix shift-out-of-bounds in exfat_fill_super() 2021-03-04 11:38:41 +01:00
exportfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
ext2 rk: revert to v4.19 2021-03-17 18:05:39 +08:00
ext4 ANDROID: mm: allow vmas with vm_ops to be speculatively handled 2021-04-23 18:42:39 -07:00
f2fs f2fs: Fix recovery is too slow when power fail on much fsync 2021-06-08 09:38:35 +08:00
fat rk: revert to v4.19 2021-03-17 18:05:39 +08:00
freevxfs
fscache rk: revert to v4.19 2021-03-17 18:05:39 +08:00
fuse ANDROID: fuse: fix deadlock for reply of FUSE_CANONICAL_PATH 2021-06-08 09:38:35 +08:00
gfs2 Merge 5.10.31 into android12-5.10 2021-04-16 16:01:44 +02:00
hfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
hfsplus rk: revert to v4.19 2021-03-17 18:05:39 +08:00
hostfs hostfs: fix memory handling in follow_link() 2021-04-14 08:42:06 +02:00
hpfs
hugetlbfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
incfs ANDROID: Incremental fs: Fix pseudo-file attributes 2021-04-28 22:07:07 +00:00
iomap Merge 5.10.28 into android12-5.10 2021-04-09 09:29:17 +02:00
isofs isofs: release buffer head before return 2021-03-04 11:38:00 +01:00
jbd2 rk: revert to v4.19 2021-03-17 18:05:39 +08:00
jffs2 rk: revert to v4.19 2021-03-17 18:05:39 +08:00
jfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
kernfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
lockd rk: revert to v4.19 2021-03-17 18:05:39 +08:00
minix rk: revert to v4.19 2021-03-17 18:05:39 +08:00
nfs Merge 5.10.27 into android12-5.10 2021-04-02 15:25:50 +02:00
nfs_common rk: revert to v4.19 2021-03-17 18:05:39 +08:00
nfsd NFSD: fix error handling in NFSv4.0 callbacks 2021-04-07 15:00:05 +02:00
nilfs2 rk: revert to v4.19 2021-03-17 18:05:39 +08:00
nls
notify rk: revert to v4.19 2021-03-17 18:05:39 +08:00
ntfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
ocfs2 Merge 5.10.30 into android12-5.10 2021-04-15 14:23:41 +02:00
omfs
openpromfs
orangefs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
overlayfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
proc BACKPORT: FROMGIT: userfaultfd: add minor fault registration mode 2021-04-09 15:35:59 -07:00
pstore FROMGIT: pstore: Add mem_type property DT parsing support 2021-04-02 10:56:28 +00:00
qnx4
qnx6
quota rk: revert to v4.19 2021-03-17 18:05:39 +08:00
ramfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
reiserfs Merge 5.10.28 into android12-5.10 2021-04-09 09:29:17 +02:00
romfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
sdcardfs
squashfs Merge 5.10.27 into android12-5.10 2021-04-02 15:25:50 +02:00
sysfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
sysv rk: revert to v4.19 2021-03-17 18:05:39 +08:00
tracefs
ubifs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
udf udf: fix silent AED tagLocation corruption 2021-03-17 17:06:23 +01:00
ufs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
unicode rk: revert to v4.19 2021-03-17 18:05:39 +08:00
vboxsf
verity rk: revert to v4.19 2021-03-17 18:05:39 +08:00
xfs rk: revert to v4.19 2021-03-17 18:05:39 +08:00
zonefs zonefs: fix to update .i_wr_refcnt correctly in zonefs_open_zone() 2021-03-25 09:04:05 +01:00
aio.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
anon_inodes.c UPSTREAM: fs: anon_inodes: rephrase to appropriate kernel-doc 2021-03-03 16:18:33 +00:00
attr.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
bad_inode.c
binfmt_aout.c
binfmt_elf_fdpic.c
binfmt_elf.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
binfmt_em86.c
binfmt_flat.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
binfmt_misc.c binfmt_misc: fix possible deadlock in bm_register_write 2021-03-17 17:06:35 +01:00
binfmt_script.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
block_dev.c Merge 5.10.31 into android12-5.10 2021-04-16 16:01:44 +02:00
buffer.c Revert "FROMLIST: fs/buffer.c: Revoke LRU when trying to drop buffers" 2021-03-24 17:40:49 +00:00
char_dev.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
compat_binfmt_elf.c
coredump.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
d_path.c
dax.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
dcache.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
dcookies.c
direct-io.c Merge 5.10.30 into android12-5.10 2021-04-15 14:23:41 +02:00
drop_caches.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
eventfd.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
eventpoll.c ANDROID: fs: Add vendor hooks for ep_create_wakeup_source & timerfd_create 2021-03-24 17:57:22 +00:00
exec.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
fcntl.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
fhandle.c
file_table.c
file.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
filesystems.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
fs_context.c
fs_parser.c
fs_pin.c
fs_struct.c
fs_types.c
fs-writeback.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
fsopen.c
init.c
inode.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
internal.h rk: revert to v4.19 2021-03-17 18:05:39 +08:00
io_uring.c io_uring: don't mark S_ISBLK async work as unbounded 2021-04-16 11:43:21 +02:00
io-wq.c io_uring: always batch cancel in *cancel_files() 2021-02-13 13:54:56 +01:00
io-wq.h io_uring: always batch cancel in *cancel_files() 2021-02-13 13:54:56 +01:00
ioctl.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
Kconfig rk: revert to v4.19 2021-03-17 18:05:39 +08:00
Kconfig.binfmt
kernel_read_file.c
libfs.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
locks.c Revert "nfsd4: a client's own opens needn't prevent delegations" 2021-03-20 10:43:44 +01:00
Makefile rk: revert to v4.19 2021-03-17 18:05:39 +08:00
mbcache.c
mount.h
mpage.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
namei.c Merge 5.10.30 into android12-5.10 2021-04-15 14:23:41 +02:00
namespace.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
no-block.c
nsfs.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
open.c FROMLIST: mm, thp: Relax the VM_DENYWRITE constraint on file-backed THPs 2021-04-28 18:41:35 +00:00
OWNERS ANDROID: Add OWNERS files referring to the respective android-mainline OWNERS 2021-04-03 14:11:30 +00:00
pipe.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
pnode.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
pnode.h mount: fix mounting of detached mounts onto targets that reside on shared mounts 2021-03-17 17:06:13 +01:00
posix_acl.c
proc_namespace.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
read_write.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
readdir.c readdir: make sure to verify directory entry for legacy interfaces too 2021-04-21 13:00:54 +02:00
remap_range.c
select.c kernel, fs: Introduce and use set_restart_fn() and arch_set_restart_data() 2021-03-25 09:04:16 +01:00
seq_file.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
signalfd.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
splice.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
stack.c
stat.c
statfs.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
super.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
sync.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
timerfd.c ANDROID: fs: Add vendor hooks for ep_create_wakeup_source & timerfd_create 2021-03-24 17:57:22 +00:00
userfaultfd.c BACKPORT: FROMGIT: userfaultfd: support minor fault handling for shmem 2021-04-09 15:36:00 -07:00
utimes.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00
xattr.c rk: revert to v4.19 2021-03-17 18:05:39 +08:00