Module Name: src Committed By: matt Date: Thu Feb 17 19:28:46 UTC 2011
Modified Files: src/sys/sys: lwp.h Log Message: Move lwp_getpcb to the area with the rest of the _KERNEL function declarations. To generate a diff of this commit: cvs rdiff -u -r1.143 -r1.144 src/sys/sys/lwp.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/sys/lwp.h diff -u src/sys/sys/lwp.h:1.143 src/sys/sys/lwp.h:1.144 --- src/sys/sys/lwp.h:1.143 Thu Feb 17 18:32:29 2011 +++ src/sys/sys/lwp.h Thu Feb 17 19:28:46 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: lwp.h,v 1.143 2011/02/17 18:32:29 rmind Exp $ */ +/* $NetBSD: lwp.h,v 1.144 2011/02/17 19:28:46 matt Exp $ */ /*- * Copyright (c) 2001, 2006, 2007, 2008, 2009, 2010 @@ -45,6 +45,9 @@ #include <sys/specificdata.h> #include <sys/syncobj.h> #include <sys/resource.h> +#if defined(_KERNEL) || defined(_KMEMUSER) +#include <sys/pcu.h> +#endif #if defined(_KERNEL) #include <machine/cpu.h> /* curcpu() and cpu_info */ @@ -67,6 +70,7 @@ * Fields are clustered together by usage (to increase the likelyhood * of cache hits) and by size (to reduce dead space in the structure). */ +#if defined(_KERNEL) || defined(_KMEMUSER) struct lockdebug; struct sadata_vp; struct sysent; @@ -193,6 +197,7 @@ struct kdtrace_thread *l_dtrace; /* (: DTrace-specific data. */ }; +#endif /* _KERNEL || _KMEMUSER */ /* * UAREA_PCB_OFFSET: an offset of PCB structure in the uarea. MD code may @@ -202,13 +207,6 @@ #define UAREA_PCB_OFFSET 0 #endif -static __inline void * -lwp_getpcb(struct lwp *l) -{ - - return l->l_addr; -} - LIST_HEAD(lwplist, lwp); /* A list of LWPs. */ #ifdef _KERNEL @@ -290,6 +288,13 @@ lwp_update_creds(l); \ } while (/* CONSTCOND */ 0) +static __inline void * +lwp_getpcb(struct lwp *l) +{ + + return l->l_addr; +} + void lwpinit(void); void lwp0_init(void); void lwp_sys_init(void);