-
Philippe Gerum authored
struct siginfo is large enough so that we don't want to copy it over entirely several times, regardless of the amount of data actually conveyed by the relevant si_code. This patch limits such copy to the relevant siginfo bits depending on the si_code, and makes sure that no more than two copies are required for transferring those bits from a sender in kernel space to the waiter in user-space. To this end, the ->signal_copyinfo() handler is introduced in the Cobalt extension ops, for transferring any non-standard bits. At this chance, we also fixed the return values of sigwaitinfo() and sigtimedwait(), to return the signal number as expected.
98882071