Back to index

lightning-sunbird  0.9+nobinonly
Defines
ioccom.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define IOCPARM_MASK   0x1fff /* parameter length, at most 13 bits */
#define IOCPARM_LEN(x)   (((x) >> 16) & IOCPARM_MASK)
#define IOCBASECMD(x)   ((x) & ~(IOCPARM_MASK << 16))
#define IOCGROUP(x)   (((x) >> 8) & 0xff)
#define IOCPARM_MAX   NBPG /* max size of ioctl, mult. of NBPG */
#define IOC_VOID   0x20000000 /* no parameters */
#define IOC_OUT   0x40000000 /* copy out parameters */
#define IOC_IN   0x80000000 /* copy in parameters */
#define IOC_INOUT   (IOC_IN|IOC_OUT)
#define IOC_DIRMASK   0xe0000000 /* mask for IN/OUT/VOID */
#define _IOC(inout, group, num, len)   (inout | ((len & IOCPARM_MASK) << 16) | ((group) << 8) | (num))
#define _IO(g, n)   _IOC(IOC_VOID, (g), (n), 0)
#define _IOR(g, n, t)   _IOC(IOC_OUT, (g), (n), sizeof(t))
#define _IOW(g, n, t)   _IOC(IOC_IN, (g), (n), sizeof(t))
#define _IOWR(g, n, t)   _IOC(IOC_INOUT, (g), (n), sizeof(t))

Define Documentation

#define _IO (   g,
  n 
)    _IOC(IOC_VOID, (g), (n), 0)

Definition at line 59 of file ioccom.h.

#define _IOC (   inout,
  group,
  num,
  len 
)    (inout | ((len & IOCPARM_MASK) << 16) | ((group) << 8) | (num))

Definition at line 57 of file ioccom.h.

#define _IOR (   g,
  n,
  t 
)    _IOC(IOC_OUT, (g), (n), sizeof(t))

Definition at line 60 of file ioccom.h.

#define _IOW (   g,
  n,
  t 
)    _IOC(IOC_IN, (g), (n), sizeof(t))

Definition at line 61 of file ioccom.h.

#define _IOWR (   g,
  n,
  t 
)    _IOC(IOC_INOUT, (g), (n), sizeof(t))

Definition at line 63 of file ioccom.h.

#define IOC_DIRMASK   0xe0000000 /* mask for IN/OUT/VOID */

Definition at line 55 of file ioccom.h.

#define IOC_IN   0x80000000 /* copy in parameters */

Definition at line 53 of file ioccom.h.

Definition at line 54 of file ioccom.h.

#define IOC_OUT   0x40000000 /* copy out parameters */

Definition at line 52 of file ioccom.h.

#define IOC_VOID   0x20000000 /* no parameters */

Definition at line 51 of file ioccom.h.

#define IOCBASECMD (   x)    ((x) & ~(IOCPARM_MASK << 16))

Definition at line 47 of file ioccom.h.

#define IOCGROUP (   x)    (((x) >> 8) & 0xff)

Definition at line 48 of file ioccom.h.

#define IOCPARM_LEN (   x)    (((x) >> 16) & IOCPARM_MASK)

Definition at line 46 of file ioccom.h.

#define IOCPARM_MASK   0x1fff /* parameter length, at most 13 bits */

Definition at line 45 of file ioccom.h.

#define IOCPARM_MAX   NBPG /* max size of ioctl, mult. of NBPG */

Definition at line 50 of file ioccom.h.