Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 85efde6f authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Ingo Molnar
Browse files

make exported headers use strict posix types



A number of standard posix types are used in exported headers, which
is not allowed if __STRICT_KERNEL_NAMES is defined. In order to
get rid of the non-__STRICT_KERNEL_NAMES part and to make sane headers
the default, we have to change them all to safe types.

There are also still some leftovers in reiserfs_fs.h, elfcore.h
and coda.h, but these files have not compiled in user space for
a long time.

This leaves out the various integer types ({u_,u,}int{8,16,32,64}_t),
which we take care of separately.

Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Acked-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
Cc: David Airlie <airlied@linux.ie>
Cc: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Cc: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Cc: netdev@vger.kernel.org
Cc: linux-ppp@vger.kernel.org
Cc: Jaroslav Kysela <perex@perex.cz>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: default avatarH. Peter Anvin <hpa@linux.intel.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent 9d50638b
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -117,9 +117,9 @@
struct flock {
	short	l_type;
	short	l_whence;
	off_t	l_start;
	off_t	l_len;
	pid_t	l_pid;
	__kernel_off_t	l_start;
	__kernel_off_t	l_len;
	__kernel_pid_t	l_pid;
	__ARCH_FLOCK_PAD
};
#endif
@@ -140,9 +140,9 @@ struct flock {
struct flock64 {
	short  l_type;
	short  l_whence;
	loff_t l_start;
	loff_t l_len;
	pid_t  l_pid;
	__kernel_loff_t l_start;
	__kernel_loff_t l_len;
	__kernel_pid_t  l_pid;
	__ARCH_FLOCK64_PAD
};
#endif
+7 −7
Original line number Diff line number Diff line
@@ -23,7 +23,7 @@ typedef union sigval {
#endif

#ifndef __ARCH_SI_UID_T
#define __ARCH_SI_UID_T	uid_t
#define __ARCH_SI_UID_T	__kernel_uid32_t
#endif

/*
@@ -47,13 +47,13 @@ typedef struct siginfo {

		/* kill() */
		struct {
			pid_t _pid;		/* sender's pid */
			__kernel_pid_t _pid;	/* sender's pid */
			__ARCH_SI_UID_T _uid;	/* sender's uid */
		} _kill;

		/* POSIX.1b timers */
		struct {
			timer_t _tid;		/* timer id */
			__kernel_timer_t _tid;	/* timer id */
			int _overrun;		/* overrun count */
			char _pad[sizeof( __ARCH_SI_UID_T) - sizeof(int)];
			sigval_t _sigval;	/* same as below */
@@ -62,18 +62,18 @@ typedef struct siginfo {

		/* POSIX.1b signals */
		struct {
			pid_t _pid;		/* sender's pid */
			__kernel_pid_t _pid;	/* sender's pid */
			__ARCH_SI_UID_T _uid;	/* sender's uid */
			sigval_t _sigval;
		} _rt;

		/* SIGCHLD */
		struct {
			pid_t _pid;		/* which child */
			__kernel_pid_t _pid;	/* which child */
			__ARCH_SI_UID_T _uid;	/* sender's uid */
			int _status;		/* exit code */
			clock_t _utime;
			clock_t _stime;
			__kernel_clock_t _utime;
			__kernel_clock_t _stime;
		} _sigchld;

		/* SIGILL, SIGFPE, SIGSEGV, SIGBUS */
+7 −7
Original line number Diff line number Diff line
@@ -77,20 +77,20 @@ typedef struct _agp_setup {
 * The "prot" down below needs still a "sleep" flag somehow ...
 */
typedef struct _agp_segment {
	off_t pg_start;		/* starting page to populate    */
	size_t pg_count;	/* number of pages              */
	__kernel_off_t pg_start;	/* starting page to populate    */
	__kernel_size_t pg_count;	/* number of pages              */
	int prot;			/* prot flags for mmap          */
} agp_segment;

typedef struct _agp_region {
	pid_t pid;		/* pid of process               */
	size_t seg_count;	/* number of segments           */
	__kernel_pid_t pid;		/* pid of process       */
	__kernel_size_t seg_count;	/* number of segments   */
	struct _agp_segment *seg_list;
} agp_region;

typedef struct _agp_allocate {
	int key;		/* tag of allocation            */
	size_t pg_count;	/* number of pages              */
	__kernel_size_t pg_count;/* number of pages             */
	__u32 type;		/* 0 == normal, other devspec   */
   	__u32 physical;         /* device specific (some devices  
				 * need a phys address of the     
@@ -100,7 +100,7 @@ typedef struct _agp_allocate {

typedef struct _agp_bind {
	int key;		/* tag of allocation            */
	off_t pg_start;		/* starting page to populate    */
	__kernel_off_t pg_start;/* starting page to populate    */
} agp_bind;

typedef struct _agp_unbind {
+10 −10
Original line number Diff line number Diff line
@@ -65,20 +65,20 @@ struct proc_event {
		} ack;

		struct fork_proc_event {
			pid_t parent_pid;
			pid_t parent_tgid;
			pid_t child_pid;
			pid_t child_tgid;
			__kernel_pid_t parent_pid;
			__kernel_pid_t parent_tgid;
			__kernel_pid_t child_pid;
			__kernel_pid_t child_tgid;
		} fork;

		struct exec_proc_event {
			pid_t process_pid;
			pid_t process_tgid;
			__kernel_pid_t process_pid;
			__kernel_pid_t process_tgid;
		} exec;

		struct id_proc_event {
			pid_t process_pid;
			pid_t process_tgid;
			__kernel_pid_t process_pid;
			__kernel_pid_t process_tgid;
			union {
				__u32 ruid; /* task uid */
				__u32 rgid; /* task gid */
@@ -90,8 +90,8 @@ struct proc_event {
		} id;

		struct exit_proc_event {
			pid_t process_pid;
			pid_t process_tgid;
			__kernel_pid_t process_pid;
			__kernel_pid_t process_tgid;
			__u32 exit_code, exit_signal;
		} exit;
	} event_data;
+3 −3
Original line number Diff line number Diff line
@@ -82,9 +82,9 @@ struct cyclades_monitor {
 * open)
 */
struct cyclades_idle_stats {
    time_t	   in_use;	/* Time device has been in use (secs) */
    time_t	   recv_idle;	/* Time since last char received (secs) */
    time_t	   xmit_idle;	/* Time since last char transmitted (secs) */
    __kernel_time_t in_use;	/* Time device has been in use (secs) */
    __kernel_time_t recv_idle;	/* Time since last char received (secs) */
    __kernel_time_t xmit_idle;	/* Time since last char transmitted (secs) */
    unsigned long  recv_bytes;	/* Bytes received */
    unsigned long  xmit_bytes;	/* Bytes transmitted */
    unsigned long  overruns;	/* Input overruns */
Loading