From 0882ae87482fb10de91ef0546dff5a34832f1861 Mon Sep 17 00:00:00 2001 From: David-John Willis Date: Thu, 3 Jun 2010 18:58:26 +0100 Subject: [PATCH] udev 151: Update omap3-pandora mount.sh to do a lazy (-l) umount when a device is removed. --- recipes/udev/udev-151/omap3-pandora/mount.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/recipes/udev/udev-151/omap3-pandora/mount.sh b/recipes/udev/udev-151/omap3-pandora/mount.sh index 21440eeca4..7ba7ba7e98 100644 --- a/recipes/udev/udev-151/omap3-pandora/mount.sh +++ b/recipes/udev/udev-151/omap3-pandora/mount.sh @@ -1,8 +1,8 @@ #!/bin/sh # # Called from udev -# Attemp to mount any added block devices -# and remove any removed devices +# +# Attempt to mount any added block devices and remove any removed devices. # MOUNT="/bin/mount" @@ -62,7 +62,10 @@ fi if [ "$ACTION" = "remove" ] && [ -x "$UMOUNT" ] && [ -n "$DEVNAME" ]; then for mnt in `cat /proc/mounts | grep "$DEVNAME" | cut -f 2 -d " " ` do - $UMOUNT $mnt + # 20100306: Remove the mount point forcibly (Lazy) as the user has already removed the device by the + # DJWillis: time this fires so any handles are bad anyway. This should stop 'stale' folders being + # left around all the time. + $UMOUNT -l $mnt done # Remove empty directories from auto-mounter -- 2.39.5