From owner-freebsd-bugs@FreeBSD.ORG Wed Aug 10 19:20:09 2011 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A17421065678 for ; Wed, 10 Aug 2011 19:20:09 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 7F1498FC14 for ; Wed, 10 Aug 2011 19:20:09 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p7AJK9xX080325 for ; Wed, 10 Aug 2011 19:20:09 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p7AJK9Y8080324; Wed, 10 Aug 2011 19:20:09 GMT (envelope-from gnats) Resent-Date: Wed, 10 Aug 2011 19:20:09 GMT Resent-Message-Id: <201108101920.p7AJK9Y8080324@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Robert Millan Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A50E01065672 for ; Wed, 10 Aug 2011 19:17:44 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 94E5A8FC14 for ; Wed, 10 Aug 2011 19:17:44 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id p7AJHilM006110 for ; Wed, 10 Aug 2011 19:17:44 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id p7AJHin7006109; Wed, 10 Aug 2011 19:17:44 GMT (envelope-from nobody) Message-Id: <201108101917.p7AJHin7006109@red.freebsd.org> Date: Wed, 10 Aug 2011 19:17:44 GMT From: Robert Millan To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: misc/159654: 46 kernel headers use register_t but don't #include X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Aug 2011 19:20:09 -0000 >Number: 159654 >Category: misc >Synopsis: 46 kernel headers use register_t but don't #include >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Aug 10 19:20:09 UTC 2011 >Closed-Date: >Last-Modified: >Originator: Robert Millan >Release: FreeBSD 8.1 >Organization: >Environment: GNU/kFreeBSD thorin 8.1-1-amd64 #0 Wed Aug 10 13:58:08 CEST 2011 x86_64 amd64 AMD Athlon(tm) 64 X2 Dual Core Processor 3800+ GNU/kFreeBSD >Description: The following headers use register_t but don't #include : arm/include/frame.h arm/include/profile.h arm/include/proc.h powerpc/include/ucontext.h powerpc/include/pcb.h powerpc/include/spr.h powerpc/include/reg.h powerpc/include/_align.h powerpc/include/profile.h powerpc/include/pcpu.h powerpc/include/pmap.h powerpc/include/proc.h sparc64/include/smp.h sparc64/include/profile.h sparc64/include/cpufunc.h sparc64/include/proc.h ia64/include/profile.h ia64/include/proc.h mips/include/sigframe.h mips/include/ucontext.h mips/include/pcb.h mips/include/db_machdep.h mips/include/reg.h mips/include/frame.h mips/include/proc.h mips/include/trap.h ofed/include/linux/sched.h x86/include/_align.h i386/include/sigframe.h i386/include/apicvar.h i386/include/profile.h i386/include/cpufunc.h i386/include/proc.h amd64/include/pcb.h amd64/include/reg.h amd64/include/apicvar.h amd64/include/frame.h amd64/include/intr_machdep.h amd64/include/profile.h amd64/include/cpufunc.h amd64/include/pcpu.h amd64/include/proc.h sys/sysproto.h sys/sysent.h sys/proc.h sys/ktrace.h >How-To-Repeat: >Fix: Please consider attached patch to add the missing #include. Patch attached with submission follows: Index: arm/include/frame.h =================================================================== --- arm/include/frame.h (revision 224762) +++ arm/include/frame.h (working copy) @@ -52,6 +52,7 @@ #ifndef _LOCORE #include +#include #include Index: arm/include/profile.h =================================================================== --- arm/include/profile.h (revision 224762) +++ arm/include/profile.h (working copy) @@ -37,6 +37,8 @@ #ifndef _MACHINE_PROFILE_H_ #define _MACHINE_PROFILE_H_ +#include + /* * Config generates something to tell the compiler to align functions on 32 * byte boundaries. A strict alignment is good for keeping the tables small. Index: arm/include/proc.h =================================================================== --- arm/include/proc.h (revision 224762) +++ arm/include/proc.h (working copy) @@ -38,6 +38,7 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include #include struct md_utrap { Index: powerpc/include/ucontext.h =================================================================== --- powerpc/include/ucontext.h (revision 224762) +++ powerpc/include/ucontext.h (working copy) @@ -35,6 +35,8 @@ #ifndef _MACHINE_UCONTEXT_H_ #define _MACHINE_UCONTEXT_H_ +#include + typedef struct __mcontext { int mc_vers; int mc_flags; Index: powerpc/include/pcb.h =================================================================== --- powerpc/include/pcb.h (revision 224762) +++ powerpc/include/pcb.h (working copy) @@ -35,6 +35,8 @@ #ifndef _MACHINE_PCB_H_ #define _MACHINE_PCB_H_ +#include + typedef register_t faultbuf[25]; struct pcb { Index: powerpc/include/spr.h =================================================================== --- powerpc/include/spr.h (revision 224762) +++ powerpc/include/spr.h (working copy) @@ -29,6 +29,8 @@ #ifndef _POWERPC_SPR_H_ #define _POWERPC_SPR_H_ +#include + #ifndef _LOCORE #define mtspr(reg, val) \ __asm __volatile("mtspr %0,%1" : : "K"(reg), "r"(val)) Index: powerpc/include/reg.h =================================================================== --- powerpc/include/reg.h (revision 224762) +++ powerpc/include/reg.h (working copy) @@ -4,6 +4,8 @@ #ifndef _POWERPC_REG_H_ #define _POWERPC_REG_H_ +#include + #if defined(_KERNEL) && !defined(KLD_MODULE) && !defined(_STANDALONE) #include "opt_compat.h" #endif Index: powerpc/include/_align.h =================================================================== --- powerpc/include/_align.h (revision 224762) +++ powerpc/include/_align.h (working copy) @@ -41,6 +41,8 @@ #ifndef _POWERPC_INCLUDE__ALIGN_H_ #define _POWERPC_INCLUDE__ALIGN_H_ +#include + /* * Round p (pointer or byte index) up to a correctly-aligned value * for all data types (int, long, ...). The result is unsigned int Index: powerpc/include/profile.h =================================================================== --- powerpc/include/profile.h (revision 224762) +++ powerpc/include/profile.h (working copy) @@ -32,6 +32,8 @@ #ifndef _MACHINE_PROFILE_H_ #define _MACHINE_PROFILE_H_ +#include + #define _MCOUNT_DECL void __mcount #define FUNCTION_ALIGNMENT 4 Index: powerpc/include/pcpu.h =================================================================== --- powerpc/include/pcpu.h (revision 224762) +++ powerpc/include/pcpu.h (working copy) @@ -30,6 +30,7 @@ #ifndef _MACHINE_PCPU_H_ #define _MACHINE_PCPU_H_ +#include #include #include #include Index: powerpc/include/pmap.h =================================================================== --- powerpc/include/pmap.h (revision 224762) +++ powerpc/include/pmap.h (working copy) @@ -66,6 +66,7 @@ #include #include +#include #include #include #include Index: powerpc/include/proc.h =================================================================== --- powerpc/include/proc.h (revision 224762) +++ powerpc/include/proc.h (working copy) @@ -35,6 +35,8 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include + /* * Machine-dependent part of the proc structure */ Index: sparc64/include/smp.h =================================================================== --- sparc64/include/smp.h (revision 224762) +++ sparc64/include/smp.h (working copy) @@ -30,6 +30,8 @@ #ifndef _MACHINE_SMP_H_ #define _MACHINE_SMP_H_ +#include + #ifdef SMP #define CPU_TICKSYNC 1 Index: sparc64/include/profile.h =================================================================== --- sparc64/include/profile.h (revision 224762) +++ sparc64/include/profile.h (working copy) @@ -32,6 +32,8 @@ #ifndef _MACHINE_PROFILE_H_ #define _MACHINE_PROFILE_H_ +#include + #if !defined(_KERNEL) && !defined(_SYS_CDEFS_H_) #error this file needs sys/cdefs.h as a prerequisite #endif Index: sparc64/include/cpufunc.h =================================================================== --- sparc64/include/cpufunc.h (revision 224762) +++ sparc64/include/cpufunc.h (working copy) @@ -29,6 +29,7 @@ #ifndef _MACHINE_CPUFUNC_H_ #define _MACHINE_CPUFUNC_H_ +#include #include #include Index: sparc64/include/proc.h =================================================================== --- sparc64/include/proc.h (revision 224762) +++ sparc64/include/proc.h (working copy) @@ -34,6 +34,7 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include #include struct md_utrap { Index: ia64/include/profile.h =================================================================== --- ia64/include/profile.h (revision 224762) +++ ia64/include/profile.h (working copy) @@ -29,6 +29,8 @@ #ifndef _MACHINE_PROFILE_H_ #define _MACHINE_PROFILE_H_ +#include + #define _MCOUNT_DECL void __mcount #define MCOUNT Index: ia64/include/proc.h =================================================================== --- ia64/include/proc.h (revision 224762) +++ ia64/include/proc.h (working copy) @@ -29,6 +29,8 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include + struct mdthread { int md_spinlock_count; /* (k) */ int md_saved_intr; /* (k) */ Index: mips/include/sigframe.h =================================================================== --- mips/include/sigframe.h (revision 224762) +++ mips/include/sigframe.h (working copy) @@ -32,6 +32,8 @@ #ifndef _MACHINE_SIGFRAME_H_ #define _MACHINE_SIGFRAME_H_ +#include + /* * WARNING: code in locore.s assumes the layout shown for sf_signum * thru sf_addr so... don't alter them! Index: mips/include/ucontext.h =================================================================== --- mips/include/ucontext.h (revision 224762) +++ mips/include/ucontext.h (working copy) @@ -37,6 +37,8 @@ #ifndef _MACHINE_UCONTEXT_H_ #define _MACHINE_UCONTEXT_H_ +#include + #ifndef _LOCORE typedef struct __mcontext { Index: mips/include/pcb.h =================================================================== --- mips/include/pcb.h (revision 224762) +++ mips/include/pcb.h (working copy) @@ -42,6 +42,7 @@ #ifndef _MACHINE_PCB_H_ #define _MACHINE_PCB_H_ +#include #include /* Index: mips/include/db_machdep.h =================================================================== --- mips/include/db_machdep.h (revision 224762) +++ mips/include/db_machdep.h (working copy) @@ -37,6 +37,7 @@ #ifndef _MIPS_DB_MACHDEP_H_ #define _MIPS_DB_MACHDEP_H_ +#include #include #include #include Index: mips/include/reg.h =================================================================== --- mips/include/reg.h (revision 224762) +++ mips/include/reg.h (working copy) @@ -42,6 +42,8 @@ #ifndef _MACHINE_REG_H_ #define _MACHINE_REG_H_ +#include + /* * Location of the users' stored registers relative to ZERO. * must be visible to assembly code. Index: mips/include/frame.h =================================================================== --- mips/include/frame.h (revision 224762) +++ mips/include/frame.h (working copy) @@ -37,6 +37,8 @@ #ifndef _MACHINE_FRAME_H_ #define _MACHINE_FRAME_H_ +#include + struct trapframe { register_t zero; register_t ast; Index: mips/include/proc.h =================================================================== --- mips/include/proc.h (revision 224762) +++ mips/include/proc.h (working copy) @@ -39,6 +39,8 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include + /* * Machine-dependent part of the proc structure. */ Index: mips/include/trap.h =================================================================== --- mips/include/trap.h (revision 224762) +++ mips/include/trap.h (working copy) @@ -42,6 +42,8 @@ #ifndef _MACHINE_TRAP_H_ #define _MACHINE_TRAP_H_ +#include + /* * Trap codes also known in trap.c for name strings. * Used for indexing so modify with care. Index: ofed/include/linux/sched.h =================================================================== --- ofed/include/linux/sched.h (revision 224762) +++ ofed/include/linux/sched.h (working copy) @@ -33,6 +33,7 @@ #include #include #include +#include #define MAX_SCHEDULE_TIMEOUT LONG_MAX Index: x86/include/_align.h =================================================================== --- x86/include/_align.h (revision 224762) +++ x86/include/_align.h (working copy) @@ -41,6 +41,8 @@ #ifndef _X86_INCLUDE__ALIGN_H_ #define _X86_INCLUDE__ALIGN_H_ +#include + /* * Round p (pointer or byte index) up to a correctly-aligned value * for all data types (int, long, ...). The result is unsigned int Index: i386/include/sigframe.h =================================================================== --- i386/include/sigframe.h (revision 224762) +++ i386/include/sigframe.h (working copy) @@ -31,6 +31,8 @@ #ifndef _MACHINE_SIGFRAME_H_ #define _MACHINE_SIGFRAME_H_ +#include + /* * Signal frames, arguments passed to application signal handlers. */ Index: i386/include/apicvar.h =================================================================== --- i386/include/apicvar.h (revision 224762) +++ i386/include/apicvar.h (working copy) @@ -32,6 +32,8 @@ #ifndef _MACHINE_APICVAR_H_ #define _MACHINE_APICVAR_H_ +#include + /* * Local && I/O APIC variable definitions. */ Index: i386/include/profile.h =================================================================== --- i386/include/profile.h (revision 224762) +++ i386/include/profile.h (working copy) @@ -33,6 +33,8 @@ #ifndef _MACHINE_PROFILE_H_ #define _MACHINE_PROFILE_H_ +#include + #ifndef _SYS_CDEFS_H_ #error this file needs sys/cdefs.h as a prerequisite #endif Index: i386/include/cpufunc.h =================================================================== --- i386/include/cpufunc.h (revision 224762) +++ i386/include/cpufunc.h (working copy) @@ -38,6 +38,8 @@ #ifndef _MACHINE_CPUFUNC_H_ #define _MACHINE_CPUFUNC_H_ +#include + #ifndef _SYS_CDEFS_H_ #error this file needs sys/cdefs.h as a prerequisite #endif Index: i386/include/proc.h =================================================================== --- i386/include/proc.h (revision 224762) +++ i386/include/proc.h (working copy) @@ -33,6 +33,7 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include #include struct proc_ldt { Index: amd64/include/pcb.h =================================================================== --- amd64/include/pcb.h (revision 224762) +++ amd64/include/pcb.h (working copy) @@ -40,6 +40,7 @@ /* * AMD64 process control block */ +#include #include #include Index: amd64/include/reg.h =================================================================== --- amd64/include/reg.h (revision 224762) +++ amd64/include/reg.h (working copy) @@ -37,6 +37,8 @@ #ifndef _MACHINE_REG_H_ #define _MACHINE_REG_H_ +#include + #if defined(_KERNEL) && !defined(_STANDALONE) #include "opt_compat.h" #endif Index: amd64/include/apicvar.h =================================================================== --- amd64/include/apicvar.h (revision 224762) +++ amd64/include/apicvar.h (working copy) @@ -32,6 +32,7 @@ #ifndef _MACHINE_APICVAR_H_ #define _MACHINE_APICVAR_H_ +#include #include /* Index: amd64/include/frame.h =================================================================== --- amd64/include/frame.h (revision 224762) +++ amd64/include/frame.h (working copy) @@ -37,6 +37,8 @@ #ifndef _MACHINE_FRAME_H_ #define _MACHINE_FRAME_H_ 1 +#include + /* * System stack frames. */ Index: amd64/include/intr_machdep.h =================================================================== --- amd64/include/intr_machdep.h (revision 224762) +++ amd64/include/intr_machdep.h (working copy) @@ -29,6 +29,8 @@ #ifndef __MACHINE_INTR_MACHDEP_H__ #define __MACHINE_INTR_MACHDEP_H__ +#include + #ifdef _KERNEL /* Index: amd64/include/profile.h =================================================================== --- amd64/include/profile.h (revision 224762) +++ amd64/include/profile.h (working copy) @@ -33,6 +33,8 @@ #ifndef _MACHINE_PROFILE_H_ #define _MACHINE_PROFILE_H_ +#include + #ifndef _SYS_CDEFS_H_ #error this file needs sys/cdefs.h as a prerequisite #endif Index: amd64/include/cpufunc.h =================================================================== --- amd64/include/cpufunc.h (revision 224762) +++ amd64/include/cpufunc.h (working copy) @@ -39,6 +39,8 @@ #ifndef _MACHINE_CPUFUNC_H_ #define _MACHINE_CPUFUNC_H_ +#include + #ifndef _SYS_CDEFS_H_ #error this file needs sys/cdefs.h as a prerequisite #endif Index: amd64/include/pcpu.h =================================================================== --- amd64/include/pcpu.h (revision 224762) +++ amd64/include/pcpu.h (working copy) @@ -29,6 +29,8 @@ #ifndef _MACHINE_PCPU_H_ #define _MACHINE_PCPU_H_ +#include + #ifndef _SYS_CDEFS_H_ #error "sys/cdefs.h is a prerequisite for this file" #endif Index: amd64/include/proc.h =================================================================== --- amd64/include/proc.h (revision 224762) +++ amd64/include/proc.h (working copy) @@ -33,6 +33,7 @@ #ifndef _MACHINE_PROC_H_ #define _MACHINE_PROC_H_ +#include #include struct proc_ldt { Index: sys/sysproto.h =================================================================== --- sys/sysproto.h (revision 224762) +++ sys/sysproto.h (working copy) @@ -14,6 +14,7 @@ #include #include #include +#include #include Index: sys/sysent.h =================================================================== --- sys/sysent.h (revision 224762) +++ sys/sysent.h (working copy) @@ -33,6 +33,7 @@ #define _SYS_SYSENT_H_ #include +#include struct rlimit; struct sysent; Index: sys/proc.h =================================================================== --- sys/proc.h (revision 224762) +++ sys/proc.h (working copy) @@ -61,6 +61,7 @@ #else #include #endif +#include #include #include #include /* Machine-dependent proc substruct. */ Index: sys/ktrace.h =================================================================== --- sys/ktrace.h (revision 224762) +++ sys/ktrace.h (working copy) @@ -33,6 +33,8 @@ #ifndef _SYS_KTRACE_H_ #define _SYS_KTRACE_H_ +#include + /* * operations to ktrace system call (KTROP(op)) */ >Release-Note: >Audit-Trail: >Unformatted: