Skip to contentSkip to conversation

PATCH ppc: Merge a few more include files

PATCH [email protected] 1 participant 1 message Sep 7, 2005

lore
Share & tools
lore
#0 lore raw

Merge a few asm-ppc and asm-ppc64 header files.
Note: the merge of setup.h intentionally does not carry forward the m68k cruft. That means this patch continues to break the already broken amiga on the ppc32.

 include/asm-powerpc/msgbuf.h   |   33 +++++++++++++++++++
 include/asm-powerpc/param.h    |   24 ++++++++++++++
 include/asm-powerpc/setup.h    |    9 +++++
 include/asm-powerpc/timex.h    |   49 ++++++++++++++++++++++++++++
 include/asm-powerpc/topology.h |   70 ++++++++++++++++++++++++++++++++++++++++
 include/asm-powerpc/user.h     |   55 +++++++++++++++++++++++++++++++
 include/asm-ppc/msgbuf.h       |   25 --------------
 include/asm-ppc/param.h        |   24 --------------
 include/asm-ppc/setup.h        |   14 --------
 include/asm-ppc/timex.h        |   40 -----------------------
 include/asm-ppc/topology.h     |    6 ---
 include/asm-ppc/user.h         |   54 -------------------------------
 include/asm-ppc64/msgbuf.h     |   27 ---------------
 include/asm-ppc64/param.h      |   31 ------------------
 include/asm-ppc64/setup.h      |    6 ---
 include/asm-ppc64/timex.h      |   26 ---------------
 include/asm-ppc64/topology.h   |   69 ---------------------------------------
 include/asm-ppc64/user.h       |   58 ---------------------------------
 18 files changed, 240 insertions(+), 380 deletions(-)

---

include/asm-powerpc/msgbuf.h new file +33 -0
new file mode 100644
@@ -0,0 +1,33 @@
+#ifndef _ASM_POWERPC_MSGBUF_H
+#define _ASM_POWERPC_MSGBUF_H
+
+/*
+ * The msqid64_ds structure for the PowerPC architecture.
+ * Note extra padding because this structure is passed back and forth
+ * between kernel and user space.
+ */
+
+struct msqid64_ds {
+	struct ipc64_perm msg_perm;
+#ifndef __powerpc64__
+	unsigned int	__unused1;
+#endif
+	__kernel_time_t msg_stime;	/* last msgsnd time */
+#ifndef __powerpc64__
+	unsigned int	__unused2;
+#endif
+	__kernel_time_t msg_rtime;	/* last msgrcv time */
+#ifndef __powerpc64__
+	unsigned int	__unused3;
+#endif
+	__kernel_time_t msg_ctime;	/* last change time */
+	unsigned long  msg_cbytes;	/* current number of bytes on queue */
+	unsigned long  msg_qnum;	/* number of messages in queue */
+	unsigned long  msg_qbytes;	/* max number of bytes on queue */
+	__kernel_pid_t msg_lspid;	/* pid of last msgsnd */
+	__kernel_pid_t msg_lrpid;	/* last receive pid */
+	unsigned long  __unused4;
+	unsigned long  __unused5;
+};
+
+#endif	/* _ASM_POWERPC_MSGBUF_H */
include/asm-powerpc/param.h new file +24 -0
new file mode 100644
@@ -0,0 +1,24 @@
+#ifndef _ASM_POWERPC_PARAM_H
+#define _ASM_POWERPC_PARAM_H
+
+#include <linux/config.h>
+
+#ifdef __KERNEL__
+#define HZ		CONFIG_HZ	/* internal kernel timer frequency */
+#define USER_HZ		100		/* for user interfaces in "ticks" */
+#define CLOCKS_PER_SEC	(USER_HZ)	/* frequency at which times() counts */
+#endif /* __KERNEL__ */
+
+#ifndef HZ
+#define HZ 100
+#endif
+
+#define EXEC_PAGESIZE	4096
+
+#ifndef NOGROUP
+#define NOGROUP		(-1)
+#endif
+
+#define MAXHOSTNAMELEN	64	/* max length of hostname */
+
+#endif	/* _ASM_POWERPC_PARAM_H */
include/asm-powerpc/setup.h new file +9 -0
new file mode 100644
@@ -0,0 +1,9 @@
+#ifndef _ASM_POWERPC_SETUP_H
+#define _ASM_POWERPC_SETUP_H
+
+#ifdef __KERNEL__
+
+#define COMMAND_LINE_SIZE	512
+
+#endif	/* __KERNEL__ */
+#endif	/* _ASM_POWERPC_SETUP_H */
include/asm-powerpc/timex.h new file +49 -0

49 lines not on this page · raw message

include/asm-powerpc/topology.h new file +70 -0

70 lines not on this page · raw message

include/asm-powerpc/user.h new file +55 -0

55 lines not on this page · raw message

include/asm-ppc/msgbuf.h deleted +0 -25
deleted file mode 100644
@@ -1,25 +0,0 @@
-#ifndef _PPC_MSGBUF_H
-#define _PPC_MSGBUF_H
-
-/*
- * The msqid64_ds structure for the PPC architecture.
- */
-
-struct msqid64_ds {
-	struct ipc64_perm msg_perm;
-	unsigned int	__unused1;
-	__kernel_time_t msg_stime;	/* last msgsnd time */
-	unsigned int	__unused2;
-	__kernel_time_t msg_rtime;	/* last msgrcv time */
-	unsigned int	__unused3;
-	__kernel_time_t msg_ctime;	/* last change time */
-	unsigned long  msg_cbytes;	/* current number of bytes on queue */
-	unsigned long  msg_qnum;	/* number of messages in queue */
-	unsigned long  msg_qbytes;	/* max number of bytes on queue */
-	__kernel_pid_t msg_lspid;	/* pid of last msgsnd */
-	__kernel_pid_t msg_lrpid;	/* last receive pid */
-	unsigned long  __unused4;
-	unsigned long  __unused5;
-};
-
-#endif /* _PPC_MSGBUF_H */
include/asm-ppc/param.h deleted +0 -24
deleted file mode 100644
@@ -1,24 +0,0 @@
-#ifndef _ASM_PPC_PARAM_H
-#define _ASM_PPC_PARAM_H
-
-#include <linux/config.h>
-
-#ifdef __KERNEL__
-#define HZ		CONFIG_HZ	/* internal timer frequency */
-#define USER_HZ		100		/* for user interfaces in "ticks" */
-#define CLOCKS_PER_SEC	(USER_HZ)	/* frequency at which times() counts */
-#endif /* __KERNEL__ */
-
-#ifndef HZ
-#define HZ 100
-#endif
-
-#define EXEC_PAGESIZE	4096
-
-#ifndef NOGROUP
-#define NOGROUP		(-1)
-#endif
-
-#define MAXHOSTNAMELEN	64	/* max length of hostname */
-
-#endif
include/asm-ppc/setup.h deleted +0 -14
deleted file mode 100644
@@ -1,14 +0,0 @@
-#ifdef __KERNEL__
-#ifndef _PPC_SETUP_H
-#define _PPC_SETUP_H
-
-#define m68k_num_memory num_memory
-#define m68k_memory memory
-
-#include <asm-m68k/setup.h>
-/* We have a bigger command line buffer. */
-#undef COMMAND_LINE_SIZE
-#define COMMAND_LINE_SIZE	512
-
-#endif /* _PPC_SETUP_H */
-#endif /* __KERNEL__ */
include/asm-ppc/timex.h deleted +0 -40
deleted file mode 100644
@@ -1,40 +0,0 @@
-/*
- * include/asm-ppc/timex.h
- *
- * ppc architecture timex specifications
- */
-#ifdef __KERNEL__
-#ifndef _ASMppc_TIMEX_H
-#define _ASMppc_TIMEX_H
-
-#include <linux/config.h>
-#include <asm/cputable.h>
-
-#define CLOCK_TICK_RATE	1193180 /* Underlying HZ */
-
-typedef unsigned long cycles_t;
-
-/*
- * For the "cycle" counter we use the timebase lower half.
- * Currently only used on SMP.
- */
-
-static inline cycles_t get_cycles(void)
-{
-	cycles_t ret = 0;
-
-	__asm__ __volatile__(
-		"98:	mftb %0\n"
-		"99:\n"
-		".section __ftr_fixup,\"a\"\n"
-		"	.long %1\n"
-		"	.long 0\n"
-		"	.long 98b\n"
-		"	.long 99b\n"
-		".previous"
-		: "=r" (ret) : "i" (CPU_FTR_601));
-	return ret;
-}
-
-#endif
-#endif /* __KERNEL__ */
include/asm-ppc/topology.h deleted +0 -6
deleted file mode 100644
@@ -1,6 +0,0 @@
-#ifndef _ASM_PPC_TOPOLOGY_H
-#define _ASM_PPC_TOPOLOGY_H
-
-#include <asm-generic/topology.h>
-
-#endif /* _ASM_PPC_TOPOLOGY_H */
include/asm-ppc/user.h deleted +0 -54

54 lines not on this page · raw message

include/asm-ppc64/msgbuf.h deleted +0 -27
deleted file mode 100644
@@ -1,27 +0,0 @@
-#ifndef _PPC64_MSGBUF_H
-#define _PPC64_MSGBUF_H
-
-/* 
- * The msqid64_ds structure for the PPC architecture.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version
- * 2 of the License, or (at your option) any later version.
- */
-
-struct msqid64_ds {
-	struct ipc64_perm msg_perm;
-	__kernel_time_t msg_stime;	/* last msgsnd time */
-	__kernel_time_t msg_rtime;	/* last msgrcv time */
-	__kernel_time_t msg_ctime;	/* last change time */
-	unsigned long  msg_cbytes;	/* current number of bytes on queue */
-	unsigned long  msg_qnum;	/* number of messages in queue */
-	unsigned long  msg_qbytes;	/* max number of bytes on queue */
-	__kernel_pid_t msg_lspid;	/* pid of last msgsnd */
-	__kernel_pid_t msg_lrpid;	/* last receive pid */
-	unsigned long  __unused1;
-	unsigned long  __unused2;
-};
-
-#endif /* _PPC64_MSGBUF_H */
include/asm-ppc64/param.h deleted +0 -31
deleted file mode 100644
@@ -1,31 +0,0 @@
-#ifndef _ASM_PPC64_PARAM_H
-#define _ASM_PPC64_PARAM_H
-
-#include <linux/config.h>
-
-/*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version
- * 2 of the License, or (at your option) any later version.
- */
-
-#ifdef __KERNEL__
-# define HZ		CONFIG_HZ	/* Internal kernel timer frequency */
-# define USER_HZ	100		/* .. some user interfaces are in "ticks" */
-# define CLOCKS_PER_SEC	(USER_HZ)	/* like times() */
-#endif
-
-#ifndef HZ
-#define HZ 100
-#endif
-
-#define EXEC_PAGESIZE	4096
-
-#ifndef NOGROUP
-#define NOGROUP		(-1)
-#endif
-
-#define MAXHOSTNAMELEN	64	/* max length of hostname */
-
-#endif /* _ASM_PPC64_PARAM_H */
include/asm-ppc64/setup.h deleted +0 -6
deleted file mode 100644
@@ -1,6 +0,0 @@
-#ifndef _PPC_SETUP_H
-#define _PPC_SETUP_H
-
-#define COMMAND_LINE_SIZE 512
-
-#endif /* _PPC_SETUP_H */
include/asm-ppc64/timex.h deleted +0 -26
deleted file mode 100644
@@ -1,26 +0,0 @@
-/*
- * linux/include/asm-ppc/timex.h
- *
- * PPC64 architecture timex specifications
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version
- * 2 of the License, or (at your option) any later version.
- */
-#ifndef _ASMPPC64_TIMEX_H
-#define _ASMPPC64_TIMEX_H
-
-#define CLOCK_TICK_RATE	1193180 /* Underlying HZ */
-
-typedef unsigned long cycles_t;
-
-static inline cycles_t get_cycles(void)
-{
-	cycles_t ret;
-
-	__asm__ __volatile__("mftb %0" : "=r" (ret) : );
-	return ret;
-}
-
-#endif
include/asm-ppc64/topology.h deleted +0 -69

69 lines not on this page · raw message

include/asm-ppc64/user.h deleted +0 -58

58 lines not on this page · raw message