summaryrefslogtreecommitdiff
path: root/usr/src/uts
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/uts')
-rw-r--r--usr/src/uts/common/fs/smbclnt/smbfs/smbfs.h5
-rw-r--r--usr/src/uts/common/io/pcmcia/pcmem.c4
-rw-r--r--usr/src/uts/common/io/ppm/ppm.c7
-rw-r--r--usr/src/uts/common/io/sfe/sfe.c8
-rw-r--r--usr/src/uts/common/nfs/nfs.h2
-rw-r--r--usr/src/uts/common/os/kmem.c3
-rw-r--r--usr/src/uts/common/os/sunpm.c41
-rw-r--r--usr/src/uts/common/rpc/rpcmod.c2
-rw-r--r--usr/src/uts/common/sys/exec.h9
-rw-r--r--usr/src/uts/common/sys/fs/autofs.h8
-rw-r--r--usr/src/uts/common/sys/fs/dv_node.h9
-rw-r--r--usr/src/uts/common/sys/fs/fifonode.h6
-rw-r--r--usr/src/uts/common/sys/fs/hsfs_impl.h4
-rw-r--r--usr/src/uts/common/sys/fs/lofs_info.h6
-rw-r--r--usr/src/uts/common/sys/fs/namenode.h10
-rw-r--r--usr/src/uts/common/sys/fs/pc_node.h12
-rw-r--r--usr/src/uts/common/sys/fs/tmpnode.h10
-rw-r--r--usr/src/uts/common/sys/fs/ufs_inode.h6
-rw-r--r--usr/src/uts/common/sys/mode.h17
-rw-r--r--usr/src/uts/common/sys/socketvar.h4
-rw-r--r--usr/src/uts/common/syscall/lwp_sobj.c2
21 files changed, 100 insertions, 75 deletions
diff --git a/usr/src/uts/common/fs/smbclnt/smbfs/smbfs.h b/usr/src/uts/common/fs/smbclnt/smbfs/smbfs.h
index 0a2e78c103..4770ee6e84 100644
--- a/usr/src/uts/common/fs/smbclnt/smbfs/smbfs.h
+++ b/usr/src/uts/common/fs/smbclnt/smbfs/smbfs.h
@@ -33,15 +33,13 @@
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SMBFS_SMBFS_H
#define _SMBFS_SMBFS_H
-#pragma ident "%Z%%M% %I% %E% SMI"
-
/*
* FS-specific VFS structures for smbfs.
* (per-mount stuff, etc.)
@@ -52,6 +50,7 @@
#include <sys/list.h>
#include <sys/vfs.h>
+#include <sys/vfs_opreg.h>
#include <sys/fs/smbfs_mount.h>
diff --git a/usr/src/uts/common/io/pcmcia/pcmem.c b/usr/src/uts/common/io/pcmcia/pcmem.c
index 3777c3b675..7b74ceafb9 100644
--- a/usr/src/uts/common/io/pcmcia/pcmem.c
+++ b/usr/src/uts/common/io/pcmcia/pcmem.c
@@ -19,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -160,6 +160,7 @@ _fini(void)
}
+static void pcmem_create_pcram_node(dev_info_t *);
/*
* pcmem_attach()
@@ -169,7 +170,6 @@ static int
pcmem_attach(dev_info_t *dip, ddi_attach_cmd_t cmd)
{
char adapter [MODMAXNAMELEN+1];
- static void pcmem_create_pcram_node(dev_info_t *);
/* resume from a checkpoint */
if (cmd == DDI_RESUME) {
diff --git a/usr/src/uts/common/io/ppm/ppm.c b/usr/src/uts/common/io/ppm/ppm.c
index 3bc65bd05d..323ff493d8 100644
--- a/usr/src/uts/common/io/ppm/ppm.c
+++ b/usr/src/uts/common/io/ppm/ppm.c
@@ -19,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -746,6 +746,9 @@ err_bydom:
}
+static int ppm_manage_sx(s3a_t *, int);
+static int ppm_search_list(pm_searchargs_t *);
+
/*
* interface between pm framework and ppm driver
*/
@@ -762,8 +765,6 @@ ppm_ctlops(dev_info_t *dip, dev_info_t *rdip,
ppm_owned_t *owned;
int mode;
int ret = DDI_SUCCESS;
- static int ppm_manage_sx(s3a_t *, int);
- static int ppm_search_list(pm_searchargs_t *);
int *res = (int *)result;
s3a_t s3args;
diff --git a/usr/src/uts/common/io/sfe/sfe.c b/usr/src/uts/common/io/sfe/sfe.c
index 2e0bf4ccc1..5ed5295bb3 100644
--- a/usr/src/uts/common/io/sfe/sfe.c
+++ b/usr/src/uts/common/io/sfe/sfe.c
@@ -31,6 +31,10 @@
* DAMAGE.
*/
+/* Avoid undefined symbol for non IA architectures */
+#pragma weak inb
+#pragma weak outb
+
/*
* Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
@@ -414,10 +418,6 @@ sfe_search_pci_dev(int vendor_id, int device_id)
return (sfe_search_pci_dev_subr(ddi_root_node(), vendor_id, device_id));
}
-/* Avoid undefined symbol for non IA architectures */
-#pragma weak inb
-#pragma weak outb
-
static boolean_t
sfe_get_mac_addr_sis630e(struct gem_dev *dp)
{
diff --git a/usr/src/uts/common/nfs/nfs.h b/usr/src/uts/common/nfs/nfs.h
index 79aae060f9..49e81901c1 100644
--- a/usr/src/uts/common/nfs/nfs.h
+++ b/usr/src/uts/common/nfs/nfs.h
@@ -46,11 +46,11 @@
#include <sys/tsol/label.h>
#include <sys/nvpair.h>
#include <nfs/mount.h>
+#include <sys/vfs_opreg.h>
#endif
#include <vm/page.h>
#include <rpc/rpc_sztypes.h>
#include <sys/sysmacros.h>
-
#ifdef __cplusplus
extern "C" {
#endif
diff --git a/usr/src/uts/common/os/kmem.c b/usr/src/uts/common/os/kmem.c
index 53a2eee37d..291477f6e1 100644
--- a/usr/src/uts/common/os/kmem.c
+++ b/usr/src/uts/common/os/kmem.c
@@ -2953,10 +2953,11 @@ kmem_cache_update(kmem_cache_t *cp)
(task_func_t *)kmem_cache_scan, cp, TQ_NOSLEEP);
}
+static void kmem_update(void *);
+
static void
kmem_update_timeout(void *dummy)
{
- static void kmem_update(void *);
(void) timeout(kmem_update, dummy, kmem_reap_interval);
}
diff --git a/usr/src/uts/common/os/sunpm.c b/usr/src/uts/common/os/sunpm.c
index 84c0b9fbb6..7570cd29e6 100644
--- a/usr/src/uts/common/os/sunpm.c
+++ b/usr/src/uts/common/os/sunpm.c
@@ -591,13 +591,14 @@ pm_init_locks(void)
cv_init(&pm_dep_thread_cv, NULL, CV_DEFAULT, NULL);
}
+static int pm_reset_timestamps(dev_info_t *, void *);
+
static boolean_t
pm_cpr_callb(void *arg, int code)
{
_NOTE(ARGUNUSED(arg))
static int auto_save;
static pm_cpupm_t cpupm_save;
- static int pm_reset_timestamps(dev_info_t *, void *);
switch (code) {
case CB_CODE_CPR_CHKPT:
@@ -664,6 +665,8 @@ pm_halt_callb(void *arg, int code)
return (B_TRUE);
}
+static void pm_dep_thread(void);
+
/*
* This needs to be called after the root and platform drivers are loaded
* and be single-threaded with respect to driver attach/detach
@@ -674,7 +677,6 @@ pm_init(void)
PMD_FUNC(pmf, "pm_init")
char **mod;
extern pri_t minclsyspri;
- static void pm_dep_thread(void);
pm_comps_notlowest = 0;
pm_system_idle_threshold = pm_default_idle_threshold;
@@ -847,6 +849,7 @@ e_pm_valid_power(dev_info_t *dip, int cmpt, int level)
return (0);
}
+static int pm_start(dev_info_t *dip);
/*
* Returns true if device is pm'd (after calling pm_start if need be)
*/
@@ -854,7 +857,6 @@ int
e_pm_valid_info(dev_info_t *dip, pm_info_t **infop)
{
pm_info_t *info;
- static int pm_start(dev_info_t *dip);
/*
* Check if the device is power managed if not.
@@ -1171,6 +1173,9 @@ pm_noinvol(dev_info_t *dip)
return (DEVI(dip)->devi_pm_noinvolpm != DEVI(dip)->devi_pm_volpmd);
}
+static int cur_threshold(dev_info_t *, int);
+static int pm_next_lower_power(pm_component_t *, int);
+
/*
* This function performs the actual scanning of the device.
* It attempts to power off the indicated device's components if they have
@@ -1193,8 +1198,6 @@ pm_scan_dev(dev_info_t *dip)
pm_component_t *cp;
dev_info_t *pdip = ddi_get_parent(dip);
int circ;
- static int cur_threshold(dev_info_t *, int);
- static int pm_next_lower_power(pm_component_t *, int);
clock_t min_scan = pm_default_min_scan;
/*
@@ -2454,6 +2457,8 @@ e_pm_set_cur_pwr(dev_info_t *dip, pm_component_t *cp, int level)
cp->pmc_cur_pwr = pm_level_to_index(dip, cp, level);
}
+static int pm_phc_impl(dev_info_t *, int, int, int);
+
/*
* This is the default method of setting the power of a device if no ppm
* driver has claimed it.
@@ -2467,7 +2472,6 @@ pm_power(dev_info_t *dip, int comp, int level)
struct pm_component *cp = PM_CP(dip, comp);
int retval;
pm_info_t *info = PM_GET_PM_INFO(dip);
- static int pm_phc_impl(dev_info_t *, int, int, int);
PMD(PMD_KIDSUP, ("%s: %s@%s(%s#%d), comp=%d, level=%d\n", pmf,
PM_DEVICE(dip), comp, level))
@@ -2922,6 +2926,8 @@ pm_watchers()
return (pm_pscc_direct || pm_pscc_interest);
}
+static int pm_phc_impl(dev_info_t *, int, int, int);
+
/*
* A driver is reporting that the power of one of its device's components
* has changed. Update the power state accordingly.
@@ -2934,7 +2940,6 @@ pm_power_has_changed(dev_info_t *dip, int comp, int level)
dev_info_t *pdip = ddi_get_parent(dip);
struct pm_component *cp;
int blocked, circ, pcirc, old_level;
- static int pm_phc_impl(dev_info_t *, int, int, int);
if (level < 0) {
PMD(PMD_FAIL, ("%s: %s@%s(%s#%d): bad level=%d\n", pmf,
@@ -3755,6 +3760,8 @@ pm_all_at_normal(dev_info_t *dip)
return (1);
}
+static void bring_pmdep_up(dev_info_t *, int);
+
static void
bring_wekeeps_up(char *keeper)
{
@@ -3764,7 +3771,6 @@ bring_wekeeps_up(char *keeper)
pm_info_t *wku_info;
char *kept_path;
dev_info_t *kept;
- static void bring_pmdep_up(dev_info_t *, int);
if (panicstr) {
return;
@@ -5559,6 +5565,8 @@ pm_interest_registered(int clone)
return (pm_interest[clone]);
}
+static void pm_enqueue_pscc(pscc_t *, pscc_t **);
+
/*
* Process with clone has just done PM_DIRECT_PM on dip, or has asked to
* watch all state transitions (dip == NULL). Set up data
@@ -5569,7 +5577,6 @@ pm_register_watcher(int clone, dev_info_t *dip)
{
pscc_t *p;
psce_t *psce;
- static void pm_enqueue_pscc(pscc_t *, pscc_t **);
/*
* We definitely need a control struct, then we have to search to see
@@ -5781,13 +5788,13 @@ pm_psc_find_clone(int clone, pscc_t **list, krwlock_t *lock)
return (NULL);
}
+static psce_t *pm_psc_find_clone(int, pscc_t **, krwlock_t *);
/*
* Find an entry for a particular clone in the direct list.
*/
psce_t *
pm_psc_clone_to_direct(int clone)
{
- static psce_t *pm_psc_find_clone(int, pscc_t **, krwlock_t *);
return (pm_psc_find_clone(clone, &pm_pscc_direct,
&pm_pscc_direct_rwlock));
}
@@ -5798,7 +5805,6 @@ pm_psc_clone_to_direct(int clone)
psce_t *
pm_psc_clone_to_interest(int clone)
{
- static psce_t *pm_psc_find_clone(int, pscc_t **, krwlock_t *);
return (pm_psc_find_clone(clone, &pm_pscc_interest,
&pm_pscc_interest_rwlock));
}
@@ -7860,6 +7866,8 @@ pm_cfb_trigger(void)
ddi_trigger_softintr(pm_soft_id);
}
+static major_t i_path_to_major(char *, char *);
+
major_t
pm_path_to_major(char *path)
{
@@ -7867,7 +7875,6 @@ pm_path_to_major(char *path)
char *np, *ap, *bp;
major_t ret;
size_t len;
- static major_t i_path_to_major(char *, char *);
PMD(PMD_NOINVOL, ("%s: %s\n", pmf, path))
@@ -8088,6 +8095,8 @@ i_path_to_major(char *path, char *leaf_name)
return (maj);
}
+static void i_pm_driver_removed(major_t major);
+
/*
* When user calls rem_drv, we need to forget no-involuntary-power-cycles state
* An entry in the list means that the device is detached, so we need to
@@ -8097,7 +8106,6 @@ i_path_to_major(char *path, char *leaf_name)
void
pm_driver_removed(major_t major)
{
- static void i_pm_driver_removed(major_t major);
/*
* Serialize removal of drivers. This is to keep ancestors of
@@ -8109,6 +8117,10 @@ pm_driver_removed(major_t major)
mutex_exit(&pm_remdrv_lock);
}
+static void adjust_ancestors(char *, int);
+static int pm_is_noinvol_ancestor(pm_noinvol_t *);
+static void pm_noinvol_process_ancestors(char *);
+
/*
* This routine is called recursively by pm_noinvol_process_ancestors()
*/
@@ -8116,9 +8128,6 @@ static void
i_pm_driver_removed(major_t major)
{
PMD_FUNC(pmf, "driver_removed")
- static void adjust_ancestors(char *, int);
- static int pm_is_noinvol_ancestor(pm_noinvol_t *);
- static void pm_noinvol_process_ancestors(char *);
pm_noinvol_t *ip, *pp = NULL;
int wasvolpmd;
ASSERT(major != DDI_MAJOR_T_NONE);
diff --git a/usr/src/uts/common/rpc/rpcmod.c b/usr/src/uts/common/rpc/rpcmod.c
index e3576c99d4..97b9c2a805 100644
--- a/usr/src/uts/common/rpc/rpcmod.c
+++ b/usr/src/uts/common/rpc/rpcmod.c
@@ -562,6 +562,7 @@ rmm_close(queue_t *q, int flag, cred_t *crp)
return ((*((struct temp_slot *)q->q_ptr)->ops->xo_close)(q, flag, crp));
}
+static void rpcmod_release(queue_t *, mblk_t *);
/*
* rpcmodopen - open routine gets called when the module gets pushed
* onto the stream.
@@ -573,7 +574,6 @@ rpcmodopen(queue_t *q, dev_t *devp, int flag, int sflag, cred_t *crp)
struct rpcm *rmp;
extern void (*rpc_rele)(queue_t *, mblk_t *);
- static void rpcmod_release(queue_t *, mblk_t *);
TRACE_0(TR_FAC_KRPC, TR_RPCMODOPEN_START, "rpcmodopen_start:");
diff --git a/usr/src/uts/common/sys/exec.h b/usr/src/uts/common/sys/exec.h
index 119f1f2b47..d9bcf11e55 100644
--- a/usr/src/uts/common/sys/exec.h
+++ b/usr/src/uts/common/sys/exec.h
@@ -20,7 +20,7 @@
*/
/*
- * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -68,9 +68,6 @@ typedef struct execenv {
#define LOADABLE_EXEC(e) ((e)->exec_lock)
#define LOADED_EXEC(e) ((e)->exec_func)
-extern int nexectype; /* number of elements in execsw */
-extern struct execsw execsw[];
-extern kmutex_t execsw_lock;
/*
* User argument structure for passing exec information around between the
@@ -183,6 +180,10 @@ struct execsw {
krwlock_t *exec_lock;
};
+extern int nexectype; /* number of elements in execsw */
+extern struct execsw execsw[];
+extern kmutex_t execsw_lock;
+
extern short elfmagic;
extern short intpmagic;
extern short javamagic;
diff --git a/usr/src/uts/common/sys/fs/autofs.h b/usr/src/uts/common/sys/fs/autofs.h
index dc18e9fd40..9418d3fd51 100644
--- a/usr/src/uts/common/sys/fs/autofs.h
+++ b/usr/src/uts/common/sys/fs/autofs.h
@@ -19,15 +19,13 @@
* CDDL HEADER END
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_FS_AUTOFS_H
#define _SYS_FS_AUTOFS_H
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include <rpc/clnt.h>
#include <gssapi/gssapi.h>
#include <sys/vfs.h>
@@ -43,6 +41,10 @@
#include <sys/door.h>
#include <rpcsvc/autofs_prot.h>
+#ifdef _KERNEL
+#include <sys/vfs_opreg.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
diff --git a/usr/src/uts/common/sys/fs/dv_node.h b/usr/src/uts/common/sys/fs/dv_node.h
index c3c1daa4d5..da6d18f368 100644
--- a/usr/src/uts/common/sys/fs/dv_node.h
+++ b/usr/src/uts/common/sys/fs/dv_node.h
@@ -19,15 +19,13 @@
* CDDL HEADER END
*/
/*
- * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_DV_NODE_H
#define _SYS_DV_NODE_H
-#pragma ident "%Z%%M% %I% %E% SMI"
-
/*
* dv_nodes are the file-system specific part of the
* vnodes for the device filesystem.
@@ -46,12 +44,17 @@
#include <sys/devpolicy.h>
#include <sys/avl.h>
+#ifdef _KERNEL
+#include <sys/vfs_opreg.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
#ifdef _KERNEL
+
/*
* Here's the focal point of this filesystem
*/
diff --git a/usr/src/uts/common/sys/fs/fifonode.h b/usr/src/uts/common/sys/fs/fifonode.h
index 5ef83b4778..a85408b5d4 100644
--- a/usr/src/uts/common/sys/fs/fifonode.h
+++ b/usr/src/uts/common/sys/fs/fifonode.h
@@ -19,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -30,7 +30,9 @@
#ifndef _SYS_FS_FIFONODE_H
#define _SYS_FS_FIFONODE_H
-#pragma ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.15 */
+#if defined(_KERNEL)
+#include <sys/vfs_opreg.h>
+#endif
#ifdef __cplusplus
extern "C" {
diff --git a/usr/src/uts/common/sys/fs/hsfs_impl.h b/usr/src/uts/common/sys/fs/hsfs_impl.h
index 19258a78ce..82fd044db2 100644
--- a/usr/src/uts/common/sys/fs/hsfs_impl.h
+++ b/usr/src/uts/common/sys/fs/hsfs_impl.h
@@ -22,14 +22,14 @@
* High Sierra filesystem internal routine definitions.
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_FS_HSFS_IMPL_H
#define _SYS_FS_HSFS_IMPL_H
-#pragma ident "%Z%%M% %I% %E% SMI"
+#include <sys/vfs_opreg.h>
#ifdef __cplusplus
extern "C" {
diff --git a/usr/src/uts/common/sys/fs/lofs_info.h b/usr/src/uts/common/sys/fs/lofs_info.h
index 33a1c2c9eb..f06e13774e 100644
--- a/usr/src/uts/common/sys/fs/lofs_info.h
+++ b/usr/src/uts/common/sys/fs/lofs_info.h
@@ -19,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -30,7 +30,9 @@
#ifndef _SYS_FS_LOFS_INFO_H
#define _SYS_FS_LOFS_INFO_H
-#pragma ident "%Z%%M% %I% %E% SMI"
+#ifdef _KERNEL
+#include <sys/vfs_opreg.h>
+#endif
#ifdef __cplusplus
extern "C" {
diff --git a/usr/src/uts/common/sys/fs/namenode.h b/usr/src/uts/common/sys/fs/namenode.h
index d3dfddc4fe..3ee6a3226c 100644
--- a/usr/src/uts/common/sys/fs/namenode.h
+++ b/usr/src/uts/common/sys/fs/namenode.h
@@ -2,9 +2,8 @@
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (the "License"). You may not use this file except in compliance
- * with the License.
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolaris.org/os/licensing.
@@ -23,17 +22,16 @@
/* All Rights Reserved */
/*
- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_FS_NAMENODE_H
#define _SYS_FS_NAMENODE_H
-#pragma ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.4 */
-
#if defined(_KERNEL)
#include <sys/vnode.h>
+#include <sys/vfs_opreg.h>
#endif
#ifdef __cplusplus
diff --git a/usr/src/uts/common/sys/fs/pc_node.h b/usr/src/uts/common/sys/fs/pc_node.h
index 1e8921c6c1..5dd8439c18 100644
--- a/usr/src/uts/common/sys/fs/pc_node.h
+++ b/usr/src/uts/common/sys/fs/pc_node.h
@@ -19,15 +19,13 @@
* CDDL HEADER END
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_FS_PC_NODE_H
#define _SYS_FS_PC_NODE_H
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#ifdef __cplusplus
extern "C" {
#endif
@@ -36,6 +34,10 @@ extern "C" {
#include <sys/buf.h>
#include <sys/vnode.h>
+#ifdef _KERNEL
+#include <sys/vfs_opreg.h>
+#endif
+
/*
* This overlays the fid structure (see vfs.h)
*
@@ -103,8 +105,12 @@ struct pchead {
*/
extern struct vnodeops *pcfs_fvnodeops;
extern struct vnodeops *pcfs_dvnodeops;
+
+#ifdef _KERNEL
extern const struct fs_operation_def pcfs_fvnodeops_template[];
extern const struct fs_operation_def pcfs_dvnodeops_template[];
+#endif
+
extern struct pchead pcfhead[];
extern struct pchead pcdhead[];
diff --git a/usr/src/uts/common/sys/fs/tmpnode.h b/usr/src/uts/common/sys/fs/tmpnode.h
index 084b8e181b..42e67f8501 100644
--- a/usr/src/uts/common/sys/fs/tmpnode.h
+++ b/usr/src/uts/common/sys/fs/tmpnode.h
@@ -2,9 +2,8 @@
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (the "License"). You may not use this file except in compliance
- * with the License.
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolaris.org/os/licensing.
@@ -20,18 +19,17 @@
* CDDL HEADER END
*/
/*
- * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_FS_TMPNODE_H
#define _SYS_FS_TMPNODE_H
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include <sys/t_lock.h>
#include <vm/seg.h>
#include <vm/seg_vn.h>
+#include <sys/vfs_opreg.h>
#ifdef __cplusplus
extern "C" {
diff --git a/usr/src/uts/common/sys/fs/ufs_inode.h b/usr/src/uts/common/sys/fs/ufs_inode.h
index 05c2d4e508..ae92f3c53d 100644
--- a/usr/src/uts/common/sys/fs/ufs_inode.h
+++ b/usr/src/uts/common/sys/fs/ufs_inode.h
@@ -19,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -57,6 +57,10 @@
#include <sys/fs/ufs_panic.h>
#include <sys/dnlc.h>
+#ifdef _KERNEL
+#include <sys/vfs_opreg.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
diff --git a/usr/src/uts/common/sys/mode.h b/usr/src/uts/common/sys/mode.h
index 1913b2a573..41e822f623 100644
--- a/usr/src/uts/common/sys/mode.h
+++ b/usr/src/uts/common/sys/mode.h
@@ -2,9 +2,8 @@
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (the "License"). You may not use this file except in compliance
- * with the License.
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolaris.org/os/licensing.
@@ -20,8 +19,8 @@
* CDDL HEADER END
*/
/*
- * Copyright (c) 1997-1998 by Sun Microsystems, Inc.
- * All rights reserved.
+ * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
@@ -31,18 +30,14 @@
#ifndef _SYS_MODE_H
#define _SYS_MODE_H
-#pragma ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.2 */
+#include <sys/stat.h>
+#include <sys/vnode.h>
#ifdef __cplusplus
extern "C" {
#endif
/*
- * REQUIRES sys/stat.h
- * REQUIRES sys/vnode.h
- */
-
-/*
* Conversion between vnode types/modes and encoded type/mode as
* seen by stat(2) and mknod(2).
*/
diff --git a/usr/src/uts/common/sys/socketvar.h b/usr/src/uts/common/sys/socketvar.h
index bb5fca2732..a43fae95aa 100644
--- a/usr/src/uts/common/sys/socketvar.h
+++ b/usr/src/uts/common/sys/socketvar.h
@@ -55,6 +55,10 @@
#include <sys/ksocket.h>
#include <sys/kstat.h>
+#ifdef _KERNEL
+#include <sys/vfs_opreg.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
diff --git a/usr/src/uts/common/syscall/lwp_sobj.c b/usr/src/uts/common/syscall/lwp_sobj.c
index 8b8137d935..459b757aef 100644
--- a/usr/src/uts/common/syscall/lwp_sobj.c
+++ b/usr/src/uts/common/syscall/lwp_sobj.c
@@ -1122,6 +1122,7 @@ upimutex_cleanup()
}
}
+static int iswanted();
int
lwp_mutex_timedlock(lwp_mutex_t *lp, timespec_t *tsp)
{
@@ -1140,7 +1141,6 @@ lwp_mutex_timedlock(lwp_mutex_t *lp, timespec_t *tsp)
volatile uint8_t type = 0;
lwpchan_t lwpchan;
sleepq_head_t *sqh;
- static int iswanted();
uint16_t flag;
int imm_timeout = 0;