Module Name:    src
Committed By:   jmcneill
Date:           Mon Oct 19 11:49:56 UTC 2020

Modified Files:
        src/sys/external/bsd/common/include/linux: kernel.h

Log Message:
Define __BIG_ENDIAN or __LITTLE_ENDIAN depending on target endianness


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/external/bsd/common/include/linux/kernel.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/external/bsd/common/include/linux/kernel.h
diff -u src/sys/external/bsd/common/include/linux/kernel.h:1.25 src/sys/external/bsd/common/include/linux/kernel.h:1.26
--- src/sys/external/bsd/common/include/linux/kernel.h:1.25	Fri Feb 14 14:34:57 2020
+++ src/sys/external/bsd/common/include/linux/kernel.h	Mon Oct 19 11:49:56 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: kernel.h,v 1.25 2020/02/14 14:34:57 maya Exp $	*/
+/*	$NetBSD: kernel.h,v 1.26 2020/10/19 11:49:56 jmcneill Exp $	*/
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -36,6 +36,7 @@
 #include <sys/types.h>
 #include <sys/param.h>
 #include <sys/systm.h>
+#include <sys/endian.h>
 
 #include <lib/libkern/libkern.h>
 
@@ -53,6 +54,12 @@
 
 #define	oops_in_progress	(panicstr != NULL)
 
+#if BYTE_ORDER == BIG_ENDIAN
+#define	__BIG_ENDIAN		_BIG_ENDIAN
+#else
+#define	__LITTLE_ENDIAN		_LITTLE_ENDIAN
+#endif
+
 #define	IS_ENABLED(option)	(option)
 #define	IS_BUILTIN(option)	(1) /* Probably... */
 

Reply via email to