summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/udev/udev-extraconf
diff options
context:
space:
mode:
authorColin McAllister <colinmca242@gmail.com>2024-09-06 10:21:56 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-09-10 13:05:00 +0100
commit8c820896b8786fada1125f8c945f4469bd5c5611 (patch)
treeeac75e5ab627816bf59ac5b8c16f94aa2959b149 /meta/recipes-core/udev/udev-extraconf
parent87c29b5a947956ab64c3fe881dfbc7eee5fef9e4 (diff)
downloadpoky-8c820896b8786fada1125f8c945f4469bd5c5611.tar.gz
udev-extraconf: Add collect flag to mount
Adds extra "--collect" flag to the mount command within automount_systemd. This is intended to fix an observed deadlock after rapidly inserting and removing external media. This is because if the mount command fails, the transient mount will enter a failed state. The next time the media is inserted, automount_systemd bails because the first consition finds that the file path for the failed transient mount still exists. This leaves the external media unmounted and cannot be mounted until the mount is fixed via systemctl or the device is rebooted. Adding "--collect" ensures that the transient mount is cleaned up after entering a failed state, which ensures that the media can still be mounted when it's re-inserted. (From OE-Core rev: f0cda74d73eb8c14cd6f695f514108f1e94984a6) Signed-off-by: Colin McAllister <colinmca242@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/udev/udev-extraconf')
-rw-r--r--meta/recipes-core/udev/udev-extraconf/mount.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/recipes-core/udev/udev-extraconf/mount.sh b/meta/recipes-core/udev/udev-extraconf/mount.sh
index c19e2aa68a..eb84a468be 100644
--- a/meta/recipes-core/udev/udev-extraconf/mount.sh
+++ b/meta/recipes-core/udev/udev-extraconf/mount.sh
@@ -98,7 +98,7 @@ automount_systemd() {
98 ;; 98 ;;
99 esac 99 esac
100 100
101 if ! $MOUNT --no-block -t auto $DEVNAME "$MOUNT_BASE/$name" 101 if ! $MOUNT --collect --no-block -t auto $DEVNAME "$MOUNT_BASE/$name"
102 then 102 then
103 #logger "mount.sh/automount" "$MOUNT -t auto $DEVNAME \"$MOUNT_BASE/$name\" failed!" 103 #logger "mount.sh/automount" "$MOUNT -t auto $DEVNAME \"$MOUNT_BASE/$name\" failed!"
104 rm_dir "$MOUNT_BASE/$name" 104 rm_dir "$MOUNT_BASE/$name"