From owner-svn-src-all@FreeBSD.ORG Thu Apr 25 06:29:23 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EA2F62D5; Thu, 25 Apr 2013 06:29:23 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DC01A115A; Thu, 25 Apr 2013 06:29:23 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.6/8.14.6) with ESMTP id r3P6TNMv027001; Thu, 25 Apr 2013 06:29:23 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.6/8.14.5/Submit) id r3P6TNuI027000; Thu, 25 Apr 2013 06:29:23 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201304250629.r3P6TNuI027000@svn.freebsd.org> From: Warner Losh Date: Thu, 25 Apr 2013 06:29:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r249882 - head/sys/mips/include X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Apr 2013 06:29:24 -0000 Author: imp Date: Thu Apr 25 06:29:23 2013 New Revision: 249882 URL: http://svnweb.freebsd.org/changeset/base/249882 Log: Make it possible to include this file in assembler .S sources. Modified: head/sys/mips/include/pcb.h Modified: head/sys/mips/include/pcb.h ============================================================================== --- head/sys/mips/include/pcb.h Thu Apr 25 06:28:19 2013 (r249881) +++ head/sys/mips/include/pcb.h Thu Apr 25 06:29:23 2013 (r249882) @@ -42,20 +42,7 @@ #ifndef _MACHINE_PCB_H_ #define _MACHINE_PCB_H_ -#include - /* - * MIPS process control block - */ -struct pcb -{ - struct trapframe pcb_regs; /* saved CPU and registers */ - __register_t pcb_context[14]; /* kernel context for resume */ - void *pcb_onfault; /* for copyin/copyout faults */ - register_t pcb_tpc; -}; - -/* these match the regnum's in regnum.h * used by switch.S */ #define PCB_REG_S0 0 @@ -73,6 +60,19 @@ struct pcb #define PCB_REG_GP 12 #define PCB_REG_PC 13 +#ifndef LOCORE +#include + +/* + * MIPS process control block + */ +struct pcb +{ + struct trapframe pcb_regs; /* saved CPU and registers */ + __register_t pcb_context[14]; /* kernel context for resume */ + void *pcb_onfault; /* for copyin/copyout faults */ + register_t pcb_tpc; +}; #ifdef _KERNEL extern struct pcb *curpcb; /* the current running pcb */ @@ -80,5 +80,6 @@ extern struct pcb *curpcb; /* the curre void makectx(struct trapframe *, struct pcb *); int savectx(struct pcb *) __returns_twice; #endif +#endif #endif /* !_MACHINE_PCB_H_ */