Re: [PATCH] init: Add handshake to poweroff/reboot for signal handler setup

2018-02-13 Thread Deb McLemore
>From the original thread, we tried the suggestion, but when the do_execve is >done from kernel_init for Busybox /sbin/init (to start PID=1) all process zombies are flushed (the usermode helper that kicks Busybox /sbin/poweroff started by PID=2, before PID=1 is do_execve'd from kernel init). 

Re: [PATCH] init: Add handshake to poweroff/reboot for signal handler setup

2018-02-13 Thread Laurent Bercot
Even when process=1 is started, it still leaves a window when the signal handler setup has not been completed. Yes, but you can still use kill(pid, 0) to check whether init is ready to receive signals: doublefork a zombie and repeatedly kill it with signal 0. When you get -1 ESRCH, it means

Re: [PATCH] init: Add handshake to poweroff/reboot for signal handler setup

2018-02-13 Thread Laurent Bercot
+ fdrc = connect(fdBB2, + (struct sockaddr *)_addr2, + sizeof(sa_family_t) + + BB_SIGNALS_SOCKET_STR_LEN); +

Re: [PATCH] init: Add handshake to poweroff/reboot for signal handler setup

2018-02-13 Thread Deb McLemore
Even when process=1 is started, it still leaves a window when the signal handler setup has not been completed. bb_signals is for all signal handling setup. On 02/13/2018 02:41 PM, Denys Vlasenko wrote: > On Sat, Nov 25, 2017 at 3:09 AM, Deb McLemore > wrote: >> Add

Re: [PATCH] init: Add handshake to poweroff/reboot for signal handler setup

2018-02-13 Thread Denys Vlasenko
On Sat, Nov 25, 2017 at 3:09 AM, Deb McLemore wrote: > Add an abstract socket to synchronize the readiness of init to receive > the SIGUSR2 to catch poweroff/reboot during an IPL phase (e.g. soft power > off via BMC). > > Signed-off-by: Deb McLemore

Re: [PATCH] Prevent arping from freezing when no packet is received

2018-02-13 Thread Denys Vlasenko
On Mon, Feb 12, 2018 at 3:23 PM, Ortmann, Michael wrote: > I'm not sure. The last sigprocmask call restores the original signal mask of > the thread. > It looks kind of pointless since the two blocked signals are unblocked by the > sigprocmask(SIG_UNBLOCK) call in

Re: [BUG] 'case' does not match double-quoted backslash

2018-02-13 Thread Denys Vlasenko
Fixed in git, thanks. On Tue, Feb 13, 2018 at 11:42 AM, Martijn Dekker wrote: > Op 13-02-18 om 08:12 schreef dietmar.schind...@manroland-web.com: >> Von: Kang-Che Sung >> Gesendet: Dienstag, 13. Februar 2018 04:52 >>> It says the backslash is special only when followed by the $

Re: [BUG] 'case' does not match double-quoted backslash

2018-02-13 Thread Martijn Dekker
Op 13-02-18 om 08:12 schreef dietmar.schind...@manroland-web.com: > Von: Kang-Che Sung > Gesendet: Dienstag, 13. Februar 2018 04:52 >> It says the backslash is special only when followed by the $ ` " \ >> characters. >> That is, \$ \` \" \\ and \ are special, but none of these >> includes the \z