Extract the FD sets in select and pselect6
authorJulien Desfossez <jdesfossez@efficios.com>
Sat, 30 Apr 2016 15:09:27 +0000 (11:09 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 2 May 2016 16:43:16 +0000 (12:43 -0400)
commit29751f7ce6ed098d4181309b4cf977e837fad526
treee38907ea1e1297e4fbac2ca257f1b883a673bb85
parent907b79ee82c14888c76902807bd4a240d1251ad4
Extract the FD sets in select and pselect6

Instead of extracting the user-space pointers of the 3 fd_set, we now
extract the bitmask of the FDs in the sets (in, out, ex) in the form of
an array of uint8_t (1024 FDs is the limit in the kernel).

In this example, we select in input FDs 5 to 19 (0xFFFF0), it returns
that one FD is ready: FD 12 (0x1000).

syscall_entry_select: {
  n = 20,
  _fdset_in_length = 3, fdset_in = [ [0] = 0xF0, [1] = 0xFF, [2] = 0xF ],
  _fdset_out_length = 0, fdset_out = [ ],
  _fdset_ex_length = 0, fdset_ex = [ ],
  tvp = 0
 }

syscall_exit_select: {
  ret = 1,
  _fdset_in_length = 3, fdset_in = [ [0] = 0x0, [1] = 0x10, [2] = 0x0 ],
  _fdset_out_length = 0, fdset_out = [ ],
  _fdset_ex_length = 0, fdset_ex = [ ],
  tvp = 0
}

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
instrumentation/syscalls/headers/syscalls_pointers_override.h
This page took 0.025524 seconds and 5 git commands to generate.