1. 17 Apr, 2019 2 commits
  2. 16 Apr, 2019 2 commits
    • Jakob Unterwurzacher's avatar
      Add TestParallelDiropsHang / emulate gvfs-udisks2-volume-monitor · 6560fb0d
      Jakob Unterwurzacher authored
      There is a hang that appears when enabling CAP_PARALLEL_DIROPS on Linux
      4.15.0: https://github.com/hanwen/go-fuse/issues/281
      
      The hang was originally triggered by gvfs-udisks2-volume-monitor. This
      test emulates what gvfs-udisks2-volume-monitor does.
      
      On 4.15.0 kernels, the test will get stuck, and after 120 seconds you
      get a kernel backtrace like this:
      
      [ 1813.463679] INFO: task nodefs.test:2357 blocked for more than 120 seconds.
      [ 1813.463685]       Not tainted 4.15.0-45-generic #48~16.04.1-Ubuntu
      [ 1813.463687] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
      [ 1813.463689] nodefs.test     D    0  2357   2311 0x00000004
      [ 1813.463691] Call Trace:
      [ 1813.463709]  __schedule+0x3d6/0x8b0
      [ 1813.463712]  schedule+0x36/0x80
      [ 1813.463714]  schedule_preempt_disabled+0xe/0x10
      [ 1813.463716]  __mutex_lock.isra.2+0x2ae/0x4e0
      [ 1813.463720]  ? ___slab_alloc+0x223/0x4e0
      [ 1813.463722]  ? _cond_resched+0x1a/0x50
      [ 1813.463724]  __mutex_lock_slowpath+0x13/0x20
      [ 1813.463725]  ? __mutex_lock_slowpath+0x13/0x20
      [ 1813.463727]  mutex_lock+0x2f/0x40
      [ 1813.463729]  fuse_lock_inode+0x2a/0x30
      [ 1813.463732]  fuse_lookup+0x31/0x140
      [ 1813.463735]  ? d_alloc_parallel+0xc1/0x4c0
      [ 1813.463738]  fuse_atomic_open+0x6d/0xf0
      [ 1813.463740]  path_openat+0xc5d/0x13f0
      [ 1813.463744]  do_filp_open+0x99/0x110
      [ 1813.463747]  ? __check_object_size+0xfc/0x1a0
      [ 1813.463749]  ? __alloc_fd+0x46/0x170
      [ 1813.463752]  do_sys_open+0x12d/0x290
      [ 1813.463754]  ? do_sys_open+0x12d/0x290
      [ 1813.463756]  SyS_openat+0x14/0x20
      [ 1813.463759]  do_syscall_64+0x73/0x130
      [ 1813.463762]  entry_SYSCALL_64_after_hwframe+0x3d/0xa2
      6560fb0d
    • Jakob Unterwurzacher's avatar
      dirstream_linux: fix zero terminator search · 25ee0996
      Jakob Unterwurzacher authored
      The old code searched for the first non-null byte from the end of
      the slice. This assumes that all bytes after the name are initialized
      to zero, which does not hold true on Linux 4.15.
      
      Instead, search for the first null byte from the start of the slice,
      which is guaranteed by man(3) readdir.
      
      Fixes https://github.com/hanwen/go-fuse/issues/287
      25ee0996
  3. 09 Apr, 2019 5 commits
  4. 08 Apr, 2019 8 commits
  5. 07 Apr, 2019 3 commits
    • Han-Wen Nienhuys's avatar
      nodefs: protect dirsteam overflow with lock · 7572e9d8
      Han-Wen Nienhuys authored
      Appeases the race detector.
      7572e9d8
    • Jakob Unterwurzacher's avatar
      nodefs: add TestReadDirStress · 623db2fc
      Jakob Unterwurzacher authored
      This currently fails on Linux 5.0 and may be related to
      https://github.com/hanwen/go-fuse/issues/287 .
      
      1 jakob@brikett:~/go/src/github.com/hanwen/go-fuse/nodefs$ go test
      21:42:47.356529 writer: Write/Writev failed, err: 2=no such file or directory. opcode: RELEASE
      21:42:47.598309 writer: Write/Writev failed, err: 22=invalid argument. opcode: READDIRPLUS
      21:42:47.604424 writer: Write/Writev failed, err: 22=invalid argument. opcode: READDIRPLUS
      21:42:47.606073 writer: Write/Writev failed, err: 22=invalid argument. opcode: READDIRPLUS
      --- FAIL: TestReadDirStress (0.36s)
          simple_test.go:270: goroutine 2 iteration 5: readdirent: input/output error
          simple_test.go:270: goroutine 1 iteration 9: readdirent: input/output error
          simple_test.go:270: goroutine 3 iteration 10: readdirent: input/output error
          simple_test.go:43: /usr/bin/fusermount: entry for /tmp/TestReadDirStress639795934/mnt not found in /etc/mtab
               (code exit status 1)
      
      FAIL
      exit status 1
      FAIL	github.com/hanwen/go-fuse/nodefs	0.994s
      623db2fc
    • Han-Wen Nienhuys's avatar
      nodefs: protect against double close · a856a74e
      Han-Wen Nienhuys authored
      Access file descriptors under lock, and set to -1 on close. This
      avoids confusing errors if Close() is doubly called
      a856a74e
  6. 06 Apr, 2019 10 commits
  7. 05 Apr, 2019 2 commits
  8. 04 Apr, 2019 3 commits
  9. 03 Apr, 2019 1 commit
  10. 01 Apr, 2019 4 commits