Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 7 Oct 2021 03:28:16 GMT
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: f76c1f3538b7 - stable/12 - Fix build for mips.XLP64 kernel, by re-ordering headers
Message-ID:  <202110070328.1973SG0F060881@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/12 has been updated by kevans:

URL: https://cgit.FreeBSD.org/src/commit/?id=f76c1f3538b7e2a9a783af0c22283e3a3db3906f

commit f76c1f3538b7e2a9a783af0c22283e3a3db3906f
Author:     Ravi Pokala <rpokala@FreeBSD.org>
AuthorDate: 2020-03-31 20:09:20 +0000
Commit:     Kyle Evans <kevans@FreeBSD.org>
CommitDate: 2021-10-07 03:27:27 +0000

    Fix build for mips.XLP64 kernel, by re-ordering headers
    
    The log for the failure contained errors like this:
    
    | In file included from ${SRCTOP}/sys/mips/nlm/dev/net/xlpge.c:34:
    | In file included from ${SRCTOP}/sys/sys/systm.h:44:
    | In file included from ./machine/atomic.h:849:
    | ${SRCTOP}/sys/sys/_atomic_subword.h:222:37: error: unknown type name 'u_long'; did you mean 'long'?
    | atomic_testandset_acq_long(volatile u_long *p, u_int v)
    |                                     ^~~~~~
    |                                     long
    
    And similar "unknown type name" errors for u_int, not recognizing bool as a type, etc.
    
    This was caused by including <sys/param.h> too far down; move it up where it belongs.
    
    While here, add a blank line after '__FBSDID()', in keeping with convention.
    
    (cherry picked from commit 144af011b4ee87ed3eba4f2c9f6780f4543ba554)
---
 sys/mips/nlm/dev/net/xlpge.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/sys/mips/nlm/dev/net/xlpge.c b/sys/mips/nlm/dev/net/xlpge.c
index ac0c4d6e843d..ec6f42a4a2fb 100644
--- a/sys/mips/nlm/dev/net/xlpge.c
+++ b/sys/mips/nlm/dev/net/xlpge.c
@@ -30,10 +30,11 @@
 
 #include <sys/cdefs.h>
 __FBSDID("$FreeBSD$");
+
+#include <sys/param.h>
 #include <sys/endian.h>
 #include <sys/systm.h>
 #include <sys/sockio.h>
-#include <sys/param.h>
 #include <sys/lock.h>
 #include <sys/mutex.h>
 #include <sys/proc.h>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202110070328.1973SG0F060881>