Skip to contentSkip to conversation

hfsplus-fix-remount-issue.patch removed from -mm tree

merged [email protected] 1 participant 1 message Mar 6, 2014 Hfsplus filesystem

lore
Share & tools
lore
#0 lore raw

Subject: [merged] hfsplus-fix-remount-issue.patch removed from -mm tree
To: [email protected],[email protected],[email protected],[email protected]
From: [email protected]
Date: Thu, 06 Mar 2014 12:37:48 -0800

The patch titled
Subject: hfsplus: fix remount issue
has been removed from the -mm tree. Its filename was
hfsplus-fix-remount-issue.patch

This patch was dropped because it was merged into mainline or a subsystem tree

------------------------------------------------------
From: Vyacheslav Dubeyko <[email protected]>
Subject: hfsplus: fix remount issue

Current implementation of HFS+ driver has small issue with remount option.
Namely, for example, you are unable to remount from RO mode into RW mode
by means of command "mount -o remount,rw /dev/loop0 /mnt/hfsplus". Trying to execute sequence of commands results in an error message:

mount /dev/loop0 /mnt/hfsplus
mount -o remount,ro /dev/loop0 /mnt/hfsplus
mount -o remount,rw /dev/loop0 /mnt/hfsplus

mount: you must specify the filesystem type

mount -t hfsplus -o remount,rw /dev/loop0 /mnt/hfsplus

mount: /mnt/hfsplus not mounted or bad option

The reason of such issue is failure of mount syscall:

mount("/dev/loop0", "/mnt/hfsplus", 0x2282a60, MS_MGC_VAL|MS_REMOUNT, NULL) = -1 EINVAL (Invalid argument)

Namely, hfsplus_parse_options_remount() method receives empty "input" argument and return false in such case. As a result, hfsplus_remount() returns -EINVAL error code.

This patch fixes the issue by means of return true for the case of empty "input" argument in hfsplus_parse_options_remount() method.

---

 fs/hfsplus/options.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/hfsplus/options.c renamed from fs/hfsplus/options.c~hfsplus-fix-remount-issue +1 -1
diff -puN fs/hfsplus/options.c~hfsplus-fix-remount-issue fs/hfsplus/options.c
@@ -75,7 +75,7 @@ int hfsplus_parse_options_remount(char *
 	int token;
 
 	if (!input)
-		return 0;
+		return 1;
 
 	while ((p = strsep(&input, ",")) != NULL) {
 		if (!*p)

_

Patches currently in -mm which might be from [email protected] are

origin.patch hfsplus-add-hfsx-subfolder-count-support.patch hfsplus-fix-concurrent-acess-of-alloc_blocks.patch hfsplus-fix-concurrent-acess-of-alloc_blocks-fix.patch hfsplus-fix-concurrent-acess-of-alloc_blocks-fix-fix.patch hfsplus-fix-longname-handling.patch