virtiofs: enable test case for mapping virtiofs MAP_PRIVATE (#13964)

Co-authored-by: Ben Hillis <benhill@ntdev.microsoft.com>

Ben Hillis committed Dec 23, 2025 at 09:26 UTC f459aef63d207a8fb5e27bda8eb6361a5cf21097
1 file changed +5 -1
test/linux/unit_tests/drvfs.c
+5 -1
@@ -3475,6 +3475,10 @@ Return Value:
3475 // is what execve uses.
3476 //
3477
3478 + LxtCheckMapErrno(Mapping = mmap(NULL, 2, PROT_READ, MAP_PRIVATE, Fd, 0));
3479 + LxtCheckMemoryEqual(Mapping, "MZ", 2);
3480 + LxtCheckResult(munmap(Mapping, 2));
3481 +
3482 if (g_LxtFsInfo.FsType != LxtFsTypeVirtioFs)
3483 {
3484 LxtCheckMapErrno(Mapping = mmap(NULL, 2, PROT_READ, MAP_SHARED, Fd, 0));
@@ -3482,7 +3486,7 @@ Return Value:
3486 }
3487 else
3488 {
3485 - LxtLogInfo("TODO: debug virtiofs handling of app exec links");
3489 + LxtLogInfo("TODO: virtiofs does not support MAP_SHARED");
3490 }
3491
3492 ErrorExit: