Commit c1140e63 authored by Rusty Russell's avatar Rusty Russell Committed by Linus Torvalds

[PATCH] sigio delivery fix

Stephen Rothwell <sfr@canb.auug.org.au>: fix for sigio delivery:
  Hi Linus,

  This patch means that we keep the upper 16 bits of the si_code
  field of the siginfo structure that is delivered with and SIGIOs.
  We need this so that the code that actually copies the siginfo_t
  out to user mode knows which part of the union to copy.  We currently
  get away with out this information because we always copy at least
  two ints worth of the union, but this s an ugly hack and I would
  like to tidy it up.

  Comments?
parent 190cd5e5
......@@ -435,7 +435,7 @@ static void send_sigio_to_task(struct task_struct *p,
back to SIGIO in that case. --sct */
si.si_signo = fown->signum;
si.si_errno = 0;
si.si_code = reason & ~__SI_MASK;
si.si_code = reason;
/* Make sure we are called with one of the POLL_*
reasons, otherwise we could leak kernel stack into
userspace. */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment