Linux Test Project
 help / color / mirror / Atom feed
From: Brian Mak via ltp <ltp@lists.linux.it>
To: ltp@lists.linux.it
Cc: Brian Mak <bmak@nvidia.com>
Subject: [LTP] [PATCH 1/2] lib: Add ntfs3 magic
Date: Fri, 20 Nov 2026 16:36:52 -0800	[thread overview]
Message-ID: <20261121003653.179935-2-bmak@nvidia.com> (raw)
In-Reply-To: <20261121003653.179935-1-bmak@nvidia.com>

Tests currently running on ntfs3 print "unknown" as the filesystem name:
  tse_swap.c:228: TFAIL: swapon() on unknown failed: EINVAL (22)

Add TST_NTFS3_MAGIC and map it to "ntfs3".

Signed-off-by: Brian Mak <bmak@nvidia.com>
---
 include/tst_fs.h  | 1 +
 lib/tst_fs_type.c | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/include/tst_fs.h b/include/tst_fs.h
index 80eb1292e..0a6c863cb 100644
--- a/include/tst_fs.h
+++ b/include/tst_fs.h
@@ -34,6 +34,7 @@
 #define TST_FUSE_MAGIC     0x65735546
 #define TST_VFAT_MAGIC     0x4d44 /* AKA MSDOS */
 #define TST_EXFAT_MAGIC    0x2011BAB0UL
+#define TST_NTFS3_MAGIC    0x7366746e
 
 /* fs/bcachefs/bcachefs_format.h */
 #define TST_BCACHE_MAGIC		0xca451a4e
diff --git a/lib/tst_fs_type.c b/lib/tst_fs_type.c
index e9efb89dc..703225c09 100644
--- a/lib/tst_fs_type.c
+++ b/lib/tst_fs_type.c
@@ -74,6 +74,8 @@ const char *tst_fs_type_name(long f_type)
 		return "vfat";
 	case TST_EXFAT_MAGIC:
 		return "exfat";
+	case TST_NTFS3_MAGIC:
+		return "ntfs3";
 	default:
 		return "unknown";
 	}
-- 
2.53.0


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  reply	other threads:[~2026-11-23 10:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-21  0:36 [LTP] [PATCH 0/2] ntfs3: Add magic and fix swapfile creation Brian Mak via ltp
2026-11-21  0:36 ` Brian Mak via ltp [this message]
2026-11-23 12:27   ` [LTP] [PATCH 1/2] lib: Add ntfs3 magic Cyril Hrubis
2026-11-21  0:36 ` [LTP] [PATCH 2/2] tse_swap: Fill swapfile with zeroes on ntfs3 Brian Mak via ltp
2026-11-23 12:16   ` Cyril Hrubis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261121003653.179935-2-bmak@nvidia.com \
    --to=ltp@lists.linux.it \
    --cc=bmak@nvidia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox