These changes are the raw update to qemu-2.6.
[kvmfornfv.git] / qemu / include / qemu / compatfd.h
1 /*
2  * signalfd/eventfd compatibility
3  *
4  * Copyright IBM, Corp. 2008
5  *
6  * Authors:
7  *  Anthony Liguori   <aliguori@us.ibm.com>
8  *
9  * This work is licensed under the terms of the GNU GPL, version 2.  See
10  * the COPYING file in the top-level directory.
11  *
12  */
13
14 #ifndef QEMU_COMPATFD_H
15 #define QEMU_COMPATFD_H
16
17
18 struct qemu_signalfd_siginfo {
19     uint32_t ssi_signo;   /* Signal number */
20     int32_t  ssi_errno;   /* Error number (unused) */
21     int32_t  ssi_code;    /* Signal code */
22     uint32_t ssi_pid;     /* PID of sender */
23     uint32_t ssi_uid;     /* Real UID of sender */
24     int32_t  ssi_fd;      /* File descriptor (SIGIO) */
25     uint32_t ssi_tid;     /* Kernel timer ID (POSIX timers) */
26     uint32_t ssi_band;    /* Band event (SIGIO) */
27     uint32_t ssi_overrun; /* POSIX timer overrun count */
28     uint32_t ssi_trapno;  /* Trap number that caused signal */
29     int32_t  ssi_status;  /* Exit status or signal (SIGCHLD) */
30     int32_t  ssi_int;     /* Integer sent by sigqueue(2) */
31     uint64_t ssi_ptr;     /* Pointer sent by sigqueue(2) */
32     uint64_t ssi_utime;   /* User CPU time consumed (SIGCHLD) */
33     uint64_t ssi_stime;   /* System CPU time consumed (SIGCHLD) */
34     uint64_t ssi_addr;    /* Address that generated signal
35                              (for hardware-generated signals) */
36     uint8_t  pad[48];     /* Pad size to 128 bytes (allow for
37                              additional fields in the future) */
38 };
39
40 int qemu_signalfd(const sigset_t *mask);
41
42 #endif