generic/127 failure on xfs with hacked fsx

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



While testing overlayfs I found something which appears to be an
unwanted side effect of xfs_release().

Apply the attached patch to xfstests and run generic/127.

Result is:

    +ltp/fsx -q -l 262144 -o 65536 -S 191110531 -N 100000 fsx_std_mmap
    +Mapped Read: non-zero data past EOF (0x8aa1) page offset 0xaa2 is 0xa091
    +LOG DUMP (70315 total operations):

Thanks,
Miklos
---
 ltp/fsx.c |    9 +++++++++
 1 file changed, 9 insertions(+)

--- a/ltp/fsx.c
+++ b/ltp/fsx.c
@@ -647,6 +647,14 @@ check_trunc_hack(void)
 	}
 }
 
+static void openclose(int fd)
+{
+	char path[32];
+
+	sprintf(path, "/proc/self/fd/%i", fd);
+	close(open(path, O_RDONLY));
+}
+
 void
 doflush(unsigned offset, unsigned size)
 {
@@ -799,6 +807,7 @@ domapread(unsigned offset, unsigned size
 	        prterr("domapread: mmap");
 		report_failure(190);
 	}
+	openclose(fd);
 	memcpy(temp_buf, p + pg_offset, size);
 
 	check_eofpage("Read", offset, p, size);

[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux