diff options
Diffstat (limited to 'meta/recipes-core/udev/udev-extraconf')
-rw-r--r-- | meta/recipes-core/udev/udev-extraconf/mount.sh | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/meta/recipes-core/udev/udev-extraconf/mount.sh b/meta/recipes-core/udev/udev-extraconf/mount.sh index cb57e47a90..3e4f21f2eb 100644 --- a/meta/recipes-core/udev/udev-extraconf/mount.sh +++ b/meta/recipes-core/udev/udev-extraconf/mount.sh | |||
@@ -20,7 +20,7 @@ done | |||
20 | automount() { | 20 | automount() { |
21 | name="`basename "$DEVNAME"`" | 21 | name="`basename "$DEVNAME"`" |
22 | 22 | ||
23 | ! test -d "/media/$name" && mkdir -p "/media/$name" | 23 | ! test -d "/run/media/$name" && mkdir -p "/run/media/$name" |
24 | # Silent util-linux's version of mounting auto | 24 | # Silent util-linux's version of mounting auto |
25 | if [ "x`readlink $MOUNT`" = "x/bin/mount.util-linux" ] ; | 25 | if [ "x`readlink $MOUNT`" = "x/bin/mount.util-linux" ] ; |
26 | then | 26 | then |
@@ -38,12 +38,12 @@ automount() { | |||
38 | ;; | 38 | ;; |
39 | esac | 39 | esac |
40 | 40 | ||
41 | if ! $MOUNT -t auto $DEVNAME "/media/$name" | 41 | if ! $MOUNT -t auto $DEVNAME "/run/media/$name" |
42 | then | 42 | then |
43 | #logger "mount.sh/automount" "$MOUNT -t auto $DEVNAME \"/media/$name\" failed!" | 43 | #logger "mount.sh/automount" "$MOUNT -t auto $DEVNAME \"/run/media/$name\" failed!" |
44 | rm_dir "/media/$name" | 44 | rm_dir "/run/media/$name" |
45 | else | 45 | else |
46 | logger "mount.sh/automount" "Auto-mount of [/media/$name] successful" | 46 | logger "mount.sh/automount" "Auto-mount of [/run/media/$name] successful" |
47 | touch "/tmp/.automount-$name" | 47 | touch "/tmp/.automount-$name" |
48 | fi | 48 | fi |
49 | } | 49 | } |
@@ -60,7 +60,7 @@ rm_dir() { | |||
60 | 60 | ||
61 | # No ID_FS_TYPE for cdrom device, yet it should be mounted | 61 | # No ID_FS_TYPE for cdrom device, yet it should be mounted |
62 | name="`basename "$DEVNAME"`" | 62 | name="`basename "$DEVNAME"`" |
63 | [ -e /sys/block/$name/device/media ] && media_type=`cat /sys/block/$name/device/media` | 63 | [ -e /sys/block/$name/device/run/media ] && media_type=`cat /sys/block/$name/device/run/media` |
64 | 64 | ||
65 | if [ "$ACTION" = "add" ] && [ -n "$DEVNAME" ] && [ -n "$ID_FS_TYPE" -o "$media_type" = "cdrom" ]; then | 65 | if [ "$ACTION" = "add" ] && [ -n "$DEVNAME" ] && [ -n "$ID_FS_TYPE" -o "$media_type" = "cdrom" ]; then |
66 | if [ -x "$PMOUNT" ]; then | 66 | if [ -x "$PMOUNT" ]; then |
@@ -87,5 +87,5 @@ if [ "$ACTION" = "remove" ] && [ -x "$UMOUNT" ] && [ -n "$DEVNAME" ]; then | |||
87 | 87 | ||
88 | # Remove empty directories from auto-mounter | 88 | # Remove empty directories from auto-mounter |
89 | name="`basename "$DEVNAME"`" | 89 | name="`basename "$DEVNAME"`" |
90 | test -e "/tmp/.automount-$name" && rm_dir "/media/$name" | 90 | test -e "/tmp/.automount-$name" && rm_dir "/run/media/$name" |
91 | fi | 91 | fi |