]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
Tidy up io_linux.h so unknown architecture result in compile-time error again
authorRichard P. Curnow <rc@rc0.org.uk>
Sun, 22 Jan 2006 23:38:43 +0000 (23:38 +0000)
committerRichard P. Curnow <rc@rc0.org.uk>
Sun, 22 Jan 2006 23:38:43 +0000 (23:38 +0000)
io_linux.h

index 4efe6372a524874204d7267a92811382df321f35..b686c135450d17d1732c5edc0264a3f1e7c662bd 100644 (file)
@@ -6,24 +6,26 @@
 
 /* Hmm.  These constants vary a bit between systems. */
 /* (__sh__ includes both sh and sh64) */
-#if defined(__alpha__) || defined(__sparc__) || defined(__mips__) || defined(__ppc__) || defined(__ppc64__) || defined(__sparc64__)
+#if defined(__i386__) || defined(__sh__)
 #define CHRONY_IOC_NRBITS      8
 #define CHRONY_IOC_TYPEBITS    8
-#define CHRONY_IOC_SIZEBITS    13
+#define CHRONY_IOC_SIZEBITS    14
 #define CHRONY_IOC_DIRBITS     2
 
-#define CHRONY_IOC_NONE         1U
-#define CHRONY_IOC_READ         2U
-#define CHRONY_IOC_WRITE        4U
-#else
+#define CHRONY_IOC_NONE        0U
+#define CHRONY_IOC_WRITE       1U
+#define CHRONY_IOC_READ        2U
+#elif defined(__alpha__) || defined(__sparc__) || defined(__mips__) || defined(__ppc__) || defined(__ppc64__) || defined(__sparc64__)
 #define CHRONY_IOC_NRBITS      8
 #define CHRONY_IOC_TYPEBITS    8
-#define CHRONY_IOC_SIZEBITS    14
+#define CHRONY_IOC_SIZEBITS    13
 #define CHRONY_IOC_DIRBITS     2
 
-#define CHRONY_IOC_NONE                0U
-#define CHRONY_IOC_WRITE       1U
-#define CHRONY_IOC_READ                2U
+#define CHRONY_IOC_NONE        1U
+#define CHRONY_IOC_READ        2U
+#define CHRONY_IOC_WRITE       4U
+#else
+#error "I don't know the values of the _IOC_* constants for your architecture"
 #endif
 
 #define CHRONY_IOC_NRMASK      ((1 << CHRONY_IOC_NRBITS)-1)