Skip to contentSkip to conversation

udev: create /var/volatile/tmp to avoid dead link

PATCH New [email protected] 1 participant 2 messages Apr 23, 2013

lore
Share & tools
lore
#0 lore raw

cover udev: create /var/volatile/tmp to avoid dead link

From: Chen Qi <[email protected]>

The following changes since commit 361d686408b9a0b2ab2f1caf2b74adfe1ad1020c:

elfutils: split libraries into separate packages (2013-04-22 14:45:04 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib ChenQi/udev-early-mount
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/udev-early-mount

Chen Qi (1):
udev: create /var/volatile/tmp to avoid dead link

 meta/recipes-core/udev/udev/init |    1 +
 1 file changed, 1 insertion(+)
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/1 udev: create /var/volatile/tmp to avoid dead link

From: Chen Qi <[email protected]>

If it's not first boot, /tmp has already been symlinked to /var/volatile/tmp. But the udev service starts before populate-volatile.sh starts. This leads to a dead link at /tmp. As a result, trying to create any file under /tmp will fail.

If a USB is plugged in before the populate-volatile.sh script starts, the /tmp/.automount-$name file will not be created correctly. As a result, when the USB is unplugged, the /media/$name directory is not removed.

So we create /var/volatile/tmp directory in the udev script to avoid this dead link problem.

[YOCTO #3404]

---
 meta/recipes-core/udev/udev/init |    1 +
 1 file changed, 1 insertion(+)
meta/recipes-core/udev/udev/init +1 -0
index 1f871da..cd87f50 100644
@@ -51,6 +51,7 @@ case "$1" in
     [ -e /dev/shm ] || mkdir -m 1777 /dev/shm
     mount -a -t tmpfs 2>/dev/null
     mkdir -p /var/volatile/run
+    mkdir -p /var/volatile/tmp
 
     # cache handling
     if [ "$DEVCACHE" != "" ]; then
Signature · 1 line
1.7.9.5