missing: use integer types used by kernel

By using them, we can decrease included headers except linux/types.h.
This commit is contained in:
Yu Watanabe 2018-12-06 06:24:20 +01:00
parent 666a84eaca
commit 9cb6c6ecb0
2 changed files with 24 additions and 23 deletions

View File

@ -2,6 +2,7 @@
#pragma once
#include <linux/input.h>
#include <linux/types.h>
/* linux@c7dc65737c9a607d3e6f8478659876074ad129b8 (3.12) */
#ifndef EVIOCREVOKE
@ -11,9 +12,9 @@
/* linux@06a16293f71927f756dcf37558a79c0b05a91641 (4.4) */
#ifndef EVIOCSMASK
struct input_mask {
uint32_t type;
uint32_t codes_size;
uint64_t codes_ptr;
__u32 type;
__u32 codes_size;
__u64 codes_ptr;
};
#define EVIOCGMASK _IOR('E', 0x92, struct input_mask)

View File

@ -11,32 +11,32 @@
/* a528d35e8bfcc521d7cb70aaf03e1bd296c8493f (4.11) */
#if !HAVE_STRUCT_STATX
struct statx_timestamp {
int64_t tv_sec;
uint32_t tv_nsec;
uint32_t __reserved;
__s64 tv_sec;
__u32 tv_nsec;
__s32 __reserved;
};
struct statx {
uint32_t stx_mask;
uint32_t stx_blksize;
uint64_t stx_attributes;
uint32_t stx_nlink;
uint32_t stx_uid;
uint32_t stx_gid;
uint16_t stx_mode;
uint16_t __spare0[1];
uint64_t stx_ino;
uint64_t stx_size;
uint64_t stx_blocks;
uint64_t stx_attributes_mask;
__u32 stx_mask;
__u32 stx_blksize;
__u64 stx_attributes;
__u32 stx_nlink;
__u32 stx_uid;
__u32 stx_gid;
__u16 stx_mode;
__u16 __spare0[1];
__u64 stx_ino;
__u64 stx_size;
__u64 stx_blocks;
__u64 stx_attributes_mask;
struct statx_timestamp stx_atime;
struct statx_timestamp stx_btime;
struct statx_timestamp stx_ctime;
struct statx_timestamp stx_mtime;
uint32_t stx_rdev_major;
uint32_t stx_rdev_minor;
uint32_t stx_dev_major;
uint32_t stx_dev_minor;
uint64_t __spare2[14];
__u32 stx_rdev_major;
__u32 stx_rdev_minor;
__u32 stx_dev_major;
__u32 stx_dev_minor;
__u64 __spare2[14];
};
#endif