diff options
author | Bruce Cran <bruce@cran.org.uk> | 2013-02-21 11:02:41 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2013-02-21 11:02:41 +0100 |
commit | 35922a2138c5adc91a2b4b185b5d756900bde87d (patch) | |
tree | 9fa4f652df24809a9be60087a22bfb8fcba12991 /os/windows/posix | |
parent | 427899c4c9a09e245f0dd1210e824cfcea8212f8 (diff) | |
download | fio-35922a2138c5adc91a2b4b185b5d756900bde87d.tar.gz fio-35922a2138c5adc91a2b4b185b5d756900bde87d.tar.bz2 |
Update all Windows files except dobuild.cmd to use LF line endings
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'os/windows/posix')
-rw-r--r-- | os/windows/posix/include/arpa/inet.h | 26 | ||||
-rw-r--r-- | os/windows/posix/include/asm/types.h | 16 | ||||
-rw-r--r-- | os/windows/posix/include/dirent.h | 48 | ||||
-rw-r--r-- | os/windows/posix/include/dlfcn.h | 22 | ||||
-rw-r--r-- | os/windows/posix/include/libgen.h | 12 | ||||
-rw-r--r-- | os/windows/posix/include/netdb.h | 8 | ||||
-rw-r--r-- | os/windows/posix/include/netinet/in.h | 42 | ||||
-rw-r--r-- | os/windows/posix/include/poll.h | 8 | ||||
-rw-r--r-- | os/windows/posix/include/semaphore.h | 8 | ||||
-rw-r--r-- | os/windows/posix/include/sys/ipc.h | 8 | ||||
-rw-r--r-- | os/windows/posix/include/sys/mman.h | 72 | ||||
-rw-r--r-- | os/windows/posix/include/sys/poll.h | 30 | ||||
-rw-r--r-- | os/windows/posix/include/sys/resource.h | 38 | ||||
-rw-r--r-- | os/windows/posix/include/sys/shm.h | 82 | ||||
-rw-r--r-- | os/windows/posix/include/sys/socket.h | 8 | ||||
-rw-r--r-- | os/windows/posix/include/sys/uio.h | 32 | ||||
-rw-r--r-- | os/windows/posix/include/sys/un.h | 26 | ||||
-rw-r--r-- | os/windows/posix/include/sys/wait.h | 24 | ||||
-rw-r--r-- | os/windows/posix/include/syslog.h | 36 |
19 files changed, 273 insertions, 273 deletions
diff --git a/os/windows/posix/include/arpa/inet.h b/os/windows/posix/include/arpa/inet.h index df9e2780..7e3bfb7e 100644 --- a/os/windows/posix/include/arpa/inet.h +++ b/os/windows/posix/include/arpa/inet.h @@ -1,13 +1,13 @@ -#ifndef ARPA_INET_H
-#define ARPA_INET_H
-
-#include <winsock2.h>
-#include <inttypes.h>
-
-typedef int socklen_t;
-
-const char *inet_ntop(int af, const void *restrict src,
- char *restrict dst, socklen_t size);
-int inet_pton(int af, const char *restrict src, void *restrict dst);
-
-#endif /* ARPA_INET_H */
+#ifndef ARPA_INET_H +#define ARPA_INET_H + +#include <winsock2.h> +#include <inttypes.h> + +typedef int socklen_t; + +const char *inet_ntop(int af, const void *restrict src, + char *restrict dst, socklen_t size); +int inet_pton(int af, const char *restrict src, void *restrict dst); + +#endif /* ARPA_INET_H */ diff --git a/os/windows/posix/include/asm/types.h b/os/windows/posix/include/asm/types.h index 89ab3d09..7e1489ae 100644 --- a/os/windows/posix/include/asm/types.h +++ b/os/windows/posix/include/asm/types.h @@ -1,8 +1,8 @@ -#ifndef ASM_TYPES_H
-#define ASM_TYPES_H
-
-typedef unsigned short __u16;
-typedef unsigned int __u32;
-typedef unsigned long long __u64;
-
-#endif /* ASM_TYPES_H */
+#ifndef ASM_TYPES_H +#define ASM_TYPES_H + +typedef unsigned short __u16; +typedef unsigned int __u32; +typedef unsigned long long __u64; + +#endif /* ASM_TYPES_H */ diff --git a/os/windows/posix/include/dirent.h b/os/windows/posix/include/dirent.h index eef6a880..379fdf0f 100644 --- a/os/windows/posix/include/dirent.h +++ b/os/windows/posix/include/dirent.h @@ -1,24 +1,24 @@ -#ifndef DIRENT_H
-#define DIRENT_H
-
-#include <windows.h>
-
-struct dirent
-{
- ino_t d_ino; /* File serial number */
- char d_name[MAX_PATH]; /* Name of entry */
-};
-
-struct dirent_ctx
-{
- HANDLE find_handle;
- char dirname[MAX_PATH];
-};
-
-typedef struct dirent_ctx DIR;
-
-DIR *opendir(const char *dirname);
-struct dirent *readdir(DIR *dirp);
-int closedir(DIR *dirp);
-
-#endif /* DIRENT_H */
+#ifndef DIRENT_H +#define DIRENT_H + +#include <windows.h> + +struct dirent +{ + ino_t d_ino; /* File serial number */ + char d_name[MAX_PATH]; /* Name of entry */ +}; + +struct dirent_ctx +{ + HANDLE find_handle; + char dirname[MAX_PATH]; +}; + +typedef struct dirent_ctx DIR; + +DIR *opendir(const char *dirname); +struct dirent *readdir(DIR *dirp); +int closedir(DIR *dirp); + +#endif /* DIRENT_H */ diff --git a/os/windows/posix/include/dlfcn.h b/os/windows/posix/include/dlfcn.h index aaffb52f..57f29303 100644 --- a/os/windows/posix/include/dlfcn.h +++ b/os/windows/posix/include/dlfcn.h @@ -1,11 +1,11 @@ -#ifndef DLFCN_H
-#define DLFCN_H
-
-#define RTLD_LAZY 1
-
-void *dlopen(const char *file, int mode);
-int dlclose(void *handle);
-void *dlsym(void *restrict handle, const char *restrict name);
-char *dlerror(void);
-
-#endif /* DLFCN_H */
+#ifndef DLFCN_H +#define DLFCN_H + +#define RTLD_LAZY 1 + +void *dlopen(const char *file, int mode); +int dlclose(void *handle); +void *dlsym(void *restrict handle, const char *restrict name); +char *dlerror(void); + +#endif /* DLFCN_H */ diff --git a/os/windows/posix/include/libgen.h b/os/windows/posix/include/libgen.h index 9d97c253..5c4fb232 100644 --- a/os/windows/posix/include/libgen.h +++ b/os/windows/posix/include/libgen.h @@ -1,6 +1,6 @@ -#ifndef LIBGEN_H
-#define LIBGEN_H
-
-char *basename(char *path);
-
-#endif /* LIBGEN_H */
+#ifndef LIBGEN_H +#define LIBGEN_H + +char *basename(char *path); + +#endif /* LIBGEN_H */ diff --git a/os/windows/posix/include/netdb.h b/os/windows/posix/include/netdb.h index 237288b3..5dace165 100644 --- a/os/windows/posix/include/netdb.h +++ b/os/windows/posix/include/netdb.h @@ -1,4 +1,4 @@ -#ifndef NETDB_H
-#define NETDB_H
-
-#endif /* NETDB_H */
+#ifndef NETDB_H +#define NETDB_H + +#endif /* NETDB_H */ diff --git a/os/windows/posix/include/netinet/in.h b/os/windows/posix/include/netinet/in.h index 814a30eb..b58c209f 100644 --- a/os/windows/posix/include/netinet/in.h +++ b/os/windows/posix/include/netinet/in.h @@ -1,21 +1,21 @@ -#ifndef NETINET_IN_H
-#define NETINET_IN_H
-
-#include <inttypes.h>
-#include <sys/un.h>
-
-struct in6_addr
-{
- uint8_t s6_addr[16];
-};
-
-struct sockaddr_in6
-{
- sa_family_t sin6_family; /* AF_INET6 */
- in_port_t sin6_port; /* Port number */
- uint32_t sin6_flowinfo; /* IPv6 traffic class and flow information */
- struct in6_addr sin6_addr; /* IPv6 address */
- uint32_t sin6_scope_id; /* Set of interfaces for a scope */
-};
-
-#endif /* NETINET_IN_H */
+#ifndef NETINET_IN_H +#define NETINET_IN_H + +#include <inttypes.h> +#include <sys/un.h> + +struct in6_addr +{ + uint8_t s6_addr[16]; +}; + +struct sockaddr_in6 +{ + sa_family_t sin6_family; /* AF_INET6 */ + in_port_t sin6_port; /* Port number */ + uint32_t sin6_flowinfo; /* IPv6 traffic class and flow information */ + struct in6_addr sin6_addr; /* IPv6 address */ + uint32_t sin6_scope_id; /* Set of interfaces for a scope */ +}; + +#endif /* NETINET_IN_H */ diff --git a/os/windows/posix/include/poll.h b/os/windows/posix/include/poll.h index f5c47e78..058e23ad 100644 --- a/os/windows/posix/include/poll.h +++ b/os/windows/posix/include/poll.h @@ -1,4 +1,4 @@ -#ifndef POLL_H
-#define POLL_H
-
-#endif /* POLL_H */
+#ifndef POLL_H +#define POLL_H + +#endif /* POLL_H */ diff --git a/os/windows/posix/include/semaphore.h b/os/windows/posix/include/semaphore.h index d58f899d..39cd624a 100644 --- a/os/windows/posix/include/semaphore.h +++ b/os/windows/posix/include/semaphore.h @@ -1,4 +1,4 @@ -#ifndef SEMAPHORE_H
-#define SEMAPHORE_H
-
-#endif /* SEMAPHORE_H */
+#ifndef SEMAPHORE_H +#define SEMAPHORE_H + +#endif /* SEMAPHORE_H */ diff --git a/os/windows/posix/include/sys/ipc.h b/os/windows/posix/include/sys/ipc.h index 2601a539..abf26e8d 100644 --- a/os/windows/posix/include/sys/ipc.h +++ b/os/windows/posix/include/sys/ipc.h @@ -1,4 +1,4 @@ -#ifndef SYS_IPC_H
-#define SYS_IPC_H
-
-#endif /* SYS_IPC_H */
+#ifndef SYS_IPC_H +#define SYS_IPC_H + +#endif /* SYS_IPC_H */ diff --git a/os/windows/posix/include/sys/mman.h b/os/windows/posix/include/sys/mman.h index ea139ee1..8edd9fc0 100644 --- a/os/windows/posix/include/sys/mman.h +++ b/os/windows/posix/include/sys/mman.h @@ -1,36 +1,36 @@ -#ifndef SYS_MMAN_H
-#define SYS_MMAN_H
-
-#include <sys/types.h>
-
-#define PROT_NONE 0x1
-#define PROT_READ 0x2
-#define PROT_WRITE 0x4
-
-#define MAP_ANON 0x1
-#define MAP_ANONYMOUS MAP_ANON
-#define MAP_FIXED 0x2
-#define MAP_HASSEMAPHORE 0x4
-#define MAP_INHERIT 0x8
-#define MAP_NOCORE 0x10
-#define MAP_NOSYNC 0x20
-#define MAP_PREFAULT_READ 0x40
-#define MAP_PRIVATE 0x80
-#define MAP_SHARED 0x100
-#define MAP_STACK 0x200
-
-#define MAP_FAILED NULL
-
-#define MS_ASYNC 0x1
-#define MS_SYNC 0x2
-#define MS_INVALIDATE 0x3
-
-int posix_madvise(void *addr, size_t len, int advice);
-void *mmap(void *addr, size_t len, int prot, int flags,
- int fildes, off_t off);
-int munmap(void *addr, size_t len);
-int msync(void *addr, size_t len, int flags);
-int munlock(const void * addr, size_t len);
-int mlock(const void *addr, size_t len);
-
-#endif /* SYS_MMAN_H */
+#ifndef SYS_MMAN_H +#define SYS_MMAN_H + +#include <sys/types.h> + +#define PROT_NONE 0x1 +#define PROT_READ 0x2 +#define PROT_WRITE 0x4 + +#define MAP_ANON 0x1 +#define MAP_ANONYMOUS MAP_ANON +#define MAP_FIXED 0x2 +#define MAP_HASSEMAPHORE 0x4 +#define MAP_INHERIT 0x8 +#define MAP_NOCORE 0x10 +#define MAP_NOSYNC 0x20 +#define MAP_PREFAULT_READ 0x40 +#define MAP_PRIVATE 0x80 +#define MAP_SHARED 0x100 +#define MAP_STACK 0x200 + +#define MAP_FAILED NULL + +#define MS_ASYNC 0x1 +#define MS_SYNC 0x2 +#define MS_INVALIDATE 0x3 + +int posix_madvise(void *addr, size_t len, int advice); +void *mmap(void *addr, size_t len, int prot, int flags, + int fildes, off_t off); +int munmap(void *addr, size_t len); +int msync(void *addr, size_t len, int flags); +int munlock(const void * addr, size_t len); +int mlock(const void *addr, size_t len); + +#endif /* SYS_MMAN_H */ diff --git a/os/windows/posix/include/sys/poll.h b/os/windows/posix/include/sys/poll.h index e1626b25..f009d6e4 100644 --- a/os/windows/posix/include/sys/poll.h +++ b/os/windows/posix/include/sys/poll.h @@ -1,15 +1,15 @@ -#ifndef SYS_POLL_H
-#define SYS_POLL_H
-
-typedef int nfds_t;
-
-struct pollfd
-{
- int fd;
- short events;
- short revents;
-};
-
-int poll(struct pollfd fds[], nfds_t nfds, int timeout);
-
-#endif /* SYS_POLL_H */
+#ifndef SYS_POLL_H +#define SYS_POLL_H + +typedef int nfds_t; + +struct pollfd +{ + int fd; + short events; + short revents; +}; + +int poll(struct pollfd fds[], nfds_t nfds, int timeout); + +#endif /* SYS_POLL_H */ diff --git a/os/windows/posix/include/sys/resource.h b/os/windows/posix/include/sys/resource.h index fd46b288..aa957058 100644 --- a/os/windows/posix/include/sys/resource.h +++ b/os/windows/posix/include/sys/resource.h @@ -1,19 +1,19 @@ -#ifndef SYS_RESOURCE_H
-#define SYS_RESOURCE_H
-
-#define RUSAGE_SELF 0
-#define RUSAGE_THREAD 1
-
-struct rusage
-{
- struct timeval ru_utime;
- struct timeval ru_stime;
- int ru_nvcsw;
- int ru_minflt;
- int ru_majflt;
- int ru_nivcsw;
-};
-
-int getrusage(int who, struct rusage *r_usage);
-
-#endif /* SYS_RESOURCE_H */
+#ifndef SYS_RESOURCE_H +#define SYS_RESOURCE_H + +#define RUSAGE_SELF 0 +#define RUSAGE_THREAD 1 + +struct rusage +{ + struct timeval ru_utime; + struct timeval ru_stime; + int ru_nvcsw; + int ru_minflt; + int ru_majflt; + int ru_nivcsw; +}; + +int getrusage(int who, struct rusage *r_usage); + +#endif /* SYS_RESOURCE_H */ diff --git a/os/windows/posix/include/sys/shm.h b/os/windows/posix/include/sys/shm.h index 6ed59577..c0592749 100644 --- a/os/windows/posix/include/sys/shm.h +++ b/os/windows/posix/include/sys/shm.h @@ -1,41 +1,41 @@ -#ifndef SYS_SHM_H
-#define SYS_SHM_H
-
-#define IPC_RMID 0x1
-#define IPC_CREAT 0x2
-#define IPC_PRIVATE 0x4
-
-typedef int uid_t;
-typedef int gid_t;
-
-typedef int shmatt_t;
-typedef int key_t;
-
-struct ipc_perm
-{
- uid_t uid; /* owner's user ID */
- gid_t gid; /* owner's group ID */
- uid_t cuid; /* creator's user ID */
- gid_t cgid; /* creator's group ID */
- mode_t mode; /* read/write permission */
-};
-
-
-struct shmid_ds
-{
- struct ipc_perm shm_perm; /* operation permission structure */
- size_t shm_segsz; /* size of segment in bytes */
- pid_t shm_lpid; /* process ID of last shared memory operation */
- pid_t shm_cpid; /* process ID of creator */
- shmatt_t shm_nattch; /* number of current attaches */
- time_t shm_atime; /* time of last shmat() */
- time_t shm_dtime; /* time of last shmdt() */
- time_t shm_ctime; /* time of last change by shmctl() */
-};
-
-int shmctl(int shmid, int cmd, struct shmid_ds *buf);
-int shmget(key_t key, size_t size, int shmflg);
-void *shmat(int shmid, const void *shmaddr, int shmflg);
-int shmdt(const void *shmaddr);
-
-#endif /* SYS_SHM_H */
+#ifndef SYS_SHM_H +#define SYS_SHM_H + +#define IPC_RMID 0x1 +#define IPC_CREAT 0x2 +#define IPC_PRIVATE 0x4 + +typedef int uid_t; +typedef int gid_t; + +typedef int shmatt_t; +typedef int key_t; + +struct ipc_perm +{ + uid_t uid; /* owner's user ID */ + gid_t gid; /* owner's group ID */ + uid_t cuid; /* creator's user ID */ + gid_t cgid; /* creator's group ID */ + mode_t mode; /* read/write permission */ +}; + + +struct shmid_ds +{ + struct ipc_perm shm_perm; /* operation permission structure */ + size_t shm_segsz; /* size of segment in bytes */ + pid_t shm_lpid; /* process ID of last shared memory operation */ + pid_t shm_cpid; /* process ID of creator */ + shmatt_t shm_nattch; /* number of current attaches */ + time_t shm_atime; /* time of last shmat() */ + time_t shm_dtime; /* time of last shmdt() */ + time_t shm_ctime; /* time of last change by shmctl() */ +}; + +int shmctl(int shmid, int cmd, struct shmid_ds *buf); +int shmget(key_t key, size_t size, int shmflg); +void *shmat(int shmid, const void *shmaddr, int shmflg); +int shmdt(const void *shmaddr); + +#endif /* SYS_SHM_H */ diff --git a/os/windows/posix/include/sys/socket.h b/os/windows/posix/include/sys/socket.h index eef3b45b..4da6f2f8 100644 --- a/os/windows/posix/include/sys/socket.h +++ b/os/windows/posix/include/sys/socket.h @@ -1,4 +1,4 @@ -#ifndef SYS_SOCKET_H
-#define SYS_SOCKET_H
-
-#endif /* SYS_SOCKET_H */
+#ifndef SYS_SOCKET_H +#define SYS_SOCKET_H + +#endif /* SYS_SOCKET_H */ diff --git a/os/windows/posix/include/sys/uio.h b/os/windows/posix/include/sys/uio.h index 077550c6..25f83d60 100644 --- a/os/windows/posix/include/sys/uio.h +++ b/os/windows/posix/include/sys/uio.h @@ -1,16 +1,16 @@ -#ifndef SYS_UIO_H
-#define SYS_UIO_H
-
-#include <inttypes.h>
-#include <unistd.h>
-
- struct iovec
- {
- void *iov_base; /* Base address of a memory region for input or output */
- size_t iov_len; /* The size of the memory pointed to by iov_base */
-};
-
- ssize_t readv(int fildes, const struct iovec *iov, int iovcnt);
- ssize_t writev(int fildes, const struct iovec *iov, int iovcnt);
-
-#endif /* SYS_UIO_H */
+#ifndef SYS_UIO_H +#define SYS_UIO_H + +#include <inttypes.h> +#include <unistd.h> + + struct iovec + { + void *iov_base; /* Base address of a memory region for input or output */ + size_t iov_len; /* The size of the memory pointed to by iov_base */ +}; + + ssize_t readv(int fildes, const struct iovec *iov, int iovcnt); + ssize_t writev(int fildes, const struct iovec *iov, int iovcnt); + +#endif /* SYS_UIO_H */ diff --git a/os/windows/posix/include/sys/un.h b/os/windows/posix/include/sys/un.h index 64e57a5b..b9ea6301 100644 --- a/os/windows/posix/include/sys/un.h +++ b/os/windows/posix/include/sys/un.h @@ -1,13 +1,13 @@ -#ifndef SYS_UN_H
-#define SYS_UN_H
-
-typedef int sa_family_t;
-typedef int in_port_t;
-
- struct sockaddr_un
- {
- sa_family_t sun_family; /* Address family */
- char sun_path[]; /* Socket pathname */
-};
-
-#endif /* SYS_UN_H */
+#ifndef SYS_UN_H +#define SYS_UN_H + +typedef int sa_family_t; +typedef int in_port_t; + + struct sockaddr_un + { + sa_family_t sun_family; /* Address family */ + char sun_path[]; /* Socket pathname */ +}; + +#endif /* SYS_UN_H */ diff --git a/os/windows/posix/include/sys/wait.h b/os/windows/posix/include/sys/wait.h index 9e68d541..5b8fd3ae 100644 --- a/os/windows/posix/include/sys/wait.h +++ b/os/windows/posix/include/sys/wait.h @@ -1,12 +1,12 @@ -#ifndef SYS_WAIT_H
-#define SYS_WAIT_H
-
-#define WIFSIGNALED(a) 0
-#define WIFEXITED(a) 0
-#define WTERMSIG(a) 0
-#define WEXITSTATUS(a) 0
-#define WNOHANG 0
-
-pid_t waitpid(pid_t, int *stat_loc, int options);
-
-#endif /* SYS_WAIT_H */
+#ifndef SYS_WAIT_H +#define SYS_WAIT_H + +#define WIFSIGNALED(a) 0 +#define WIFEXITED(a) 0 +#define WTERMSIG(a) 0 +#define WEXITSTATUS(a) 0 +#define WNOHANG 0 + +pid_t waitpid(pid_t, int *stat_loc, int options); + +#endif /* SYS_WAIT_H */ diff --git a/os/windows/posix/include/syslog.h b/os/windows/posix/include/syslog.h index 172261cd..b8582e95 100644 --- a/os/windows/posix/include/syslog.h +++ b/os/windows/posix/include/syslog.h @@ -1,18 +1,18 @@ -#ifndef SYSLOG_H
-#define SYSLOG_H
-
-int syslog();
-
-#define LOG_INFO 0x1
-#define LOG_ERROR 0x2
-#define LOG_WARN 0x4
-
-#define LOG_NDELAY 0x1
-#define LOG_NOWAIT 0x2
-#define LOG_PID 0x4
-#define LOG_USER 0x8
-
-void closelog(void);
-void openlog(const char *ident, int logopt, int facility);
-
-#endif /* SYSLOG_H */
+#ifndef SYSLOG_H +#define SYSLOG_H + +int syslog(); + +#define LOG_INFO 0x1 +#define LOG_ERROR 0x2 +#define LOG_WARN 0x4 + +#define LOG_NDELAY 0x1 +#define LOG_NOWAIT 0x2 +#define LOG_PID 0x4 +#define LOG_USER 0x8 + +void closelog(void); +void openlog(const char *ident, int logopt, int facility); + +#endif /* SYSLOG_H */ |