summaryrefslogtreecommitdiff
path: root/include/iopause.h
blob: e3cfa01d2ecf3a946e69dfa61726c8887d4842de (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#ifndef IOPAUSE_H
#define IOPAUSE_H

#define IOPAUSE_POLL

#include <sys/types.h>
#ifdef HAS_POLL_H
#include <poll.h>

typedef struct pollfd iopause_fd;
#define IOPAUSE_READ POLLIN
#define IOPAUSE_WRITE POLLOUT
#else
typedef struct {
  int fd;
  short events;
  short revents;
} iopause_fd;
#define IOPAUSE_READ 1
#define IOPAUSE_WRITE 4
#endif

#include "taia.h"

extern int iopause(iopause_fd *,unsigned int,struct taia *,struct taia *);
extern unsigned long pollmax;

#endif