Patchwork [base,03/13] busybox-mdev: fix init script to support persistent /dev

login
register
mail settings
Submitter Jacob Kjaergaard
Date Sept. 30, 2013, 8:21 a.m.
Message ID <f5a5fa6f5895b949bc6084e06dd7efacf7842215.1380529272.git.jacob.kjaergaard@prevas.dk>
Download mbox | patch
Permalink /patch/278945/
State Accepted
Delegated to: Esben Haabendal
Headers show

Comments

Jacob Kjaergaard - Sept. 30, 2013, 8:21 a.m.
From: Jacob Kjaergaard <jacob.kjaergaard@prevas.dk>

---
 recipes/busybox/files/busybox-mdev |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Esben Haabendal - Oct. 14, 2013, noon
<jabk@prevas.dk> writes:

> From: Jacob Kjaergaard <jacob.kjaergaard@prevas.dk>
>
> ---
>  recipes/busybox/files/busybox-mdev |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/recipes/busybox/files/busybox-mdev b/recipes/busybox/files/busybox-mdev
> index 64ebfb6..9aea4a6 100755
> --- a/recipes/busybox/files/busybox-mdev
> +++ b/recipes/busybox/files/busybox-mdev
> @@ -65,7 +65,7 @@ mount -t devpts devpts /dev/pts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE
>  mkdir -m 755 -p /dev/shm
>  
>  # Make extraneous links
> -ln -sf /proc/self/fd /dev/fd
> +ln -sf /proc/self/fd /dev/.

What exactly do you say this fixes?  Doesn't the changed command always
do the same as the original command?

>  ln -sf /proc/self/fd/0 /dev/stdin
>  ln -sf /proc/self/fd/1 /dev/stdout
>  ln -sf /proc/self/fd/2 /dev/stderr

/Esben
Esben Haabendal - Oct. 21, 2013, 11:20 a.m.
Merged to master (removed the '.' as agreed).

/Esben

Patch

diff --git a/recipes/busybox/files/busybox-mdev b/recipes/busybox/files/busybox-mdev
index 64ebfb6..9aea4a6 100755
--- a/recipes/busybox/files/busybox-mdev
+++ b/recipes/busybox/files/busybox-mdev
@@ -65,7 +65,7 @@  mount -t devpts devpts /dev/pts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE
 mkdir -m 755 -p /dev/shm
 
 # Make extraneous links
-ln -sf /proc/self/fd /dev/fd
+ln -sf /proc/self/fd /dev/.
 ln -sf /proc/self/fd/0 /dev/stdin
 ln -sf /proc/self/fd/1 /dev/stdout
 ln -sf /proc/self/fd/2 /dev/stderr