public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH v1] ioctl_loop01.c: Use proper device for partitioning
@ 2025-09-01  7:47 Wei Gao via ltp
  2025-09-01 10:38 ` Petr Vorel
  2025-09-02  3:12 ` [LTP] [PATCH v2] " Wei Gao via ltp
  0 siblings, 2 replies; 21+ messages in thread
From: Wei Gao via ltp @ 2025-09-01  7:47 UTC (permalink / raw)
  To: ltp; +Cc: Jan Kara

This is same patch used on ioctl09,the page cache of loop0 can cache old
version of the partition table which is then used by the partitioning
code. Fix the problem by calling parted against the loop device directly.

Link: https://lore.kernel.org/ltp/20250829141932.31997-1-jack@suse.cz/
Signed-off-by: Wei Gao <wegao@suse.com>
---
 testcases/kernel/syscalls/ioctl/ioctl_loop01.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testcases/kernel/syscalls/ioctl/ioctl_loop01.c b/testcases/kernel/syscalls/ioctl/ioctl_loop01.c
index c9137bf1e..5ee7a474a 100644
--- a/testcases/kernel/syscalls/ioctl/ioctl_loop01.c
+++ b/testcases/kernel/syscalls/ioctl/ioctl_loop01.c
@@ -98,7 +98,7 @@ static void verify_ioctl_loop(void)
 static void setup(void)
 {
 	int ret;
-	const char *const cmd_parted[] = {"parted", "-s", "test.img", "mklabel", "msdos", "mkpart",
+	const char *const cmd_parted[] = {"parted", "-s", dev_path, "mklabel", "msdos", "mkpart",
 	                                  "primary", "ext4", "1M", "10M", NULL};
 
 	dev_num = tst_find_free_loopdev(dev_path, sizeof(dev_path));
-- 
2.51.0


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

^ permalink raw reply related	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2025-09-24 13:17 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-01  7:47 [LTP] [PATCH v1] ioctl_loop01.c: Use proper device for partitioning Wei Gao via ltp
2025-09-01 10:38 ` Petr Vorel
2025-09-02  2:16   ` Wei Gao via ltp
2025-09-02  3:12 ` [LTP] [PATCH v2] " Wei Gao via ltp
2025-09-02 10:44   ` Petr Vorel
2025-09-02 11:18   ` [LTP] [PATCH v3] " Wei Gao via ltp
2025-09-03 12:48     ` Petr Vorel
2025-09-09 11:50     ` Cyril Hrubis
2025-09-10  1:35       ` Wei Gao via ltp
2025-09-18 14:53         ` Petr Vorel
2025-09-18 15:35           ` Cyril Hrubis
2025-09-19 13:22             ` Petr Vorel
2025-09-22  7:28               ` Cyril Hrubis
2025-09-22  7:32                 ` Petr Vorel
2025-09-24  2:26             ` Wei Gao via ltp
2025-09-24  7:03               ` Petr Vorel
2025-09-24  9:54               ` Cyril Hrubis
2025-09-24 10:40                 ` Wei Gao via ltp
2025-09-24 10:54                   ` Cyril Hrubis
2025-09-24 12:55                     ` Petr Vorel
2025-09-24 13:17                       ` Cyril Hrubis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox