udev: create /var/volatile/tmp to avoid dead link
authorChen Qi <Qi.Chen@windriver.com>
Tue, 23 Apr 2013 04:31:40 +0000 (12:31 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sun, 28 Apr 2013 11:12:21 +0000 (12:12 +0100)
commit43b6572171737ee888f71e8b6f5d3fab5cecea4f
tree8b892e828d4cc2aae9cc6a587ff6718854ba077d
parent8f98cecf3ae08f043e90fe4d576077f76e31a210
udev: create /var/volatile/tmp to avoid dead link

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]

(From OE-Core rev: 2f93c8466ca146c965585ea38210ddb5fb5754bd)

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-core/udev/udev/init