summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Kozhukhov <ikozhukhov@gmail.com>2014-08-27 12:34:19 -0700
committerRobert Mustacchi <rm@joyent.com>2014-08-27 12:53:14 -0700
commit6481fd49a4385db15285ddf89f9c80b45eaaa407 (patch)
tree4a647bf257b08f64350adb7fcc20ab635684d07f
parent4e762ae71a675489e308ef67b9c4f35fa31042da (diff)
downloadillumos-joyent-6481fd49a4385db15285ddf89f9c80b45eaaa407.tar.gz
5100 sparc build failed after 5004
Reviewed by: Garrett D'Amore <garrett@damore.org> Reviewed by: Gary Mills <gary_mills@fastmail.fm> Approved by: Robert Mustacchi <rm@joyent.com>
-rw-r--r--usr/src/uts/common/sys/cpuvar.h11
-rw-r--r--usr/src/uts/common/sys/loadavg.h13
-rw-r--r--usr/src/uts/common/sys/zone.h3
3 files changed, 15 insertions, 12 deletions
diff --git a/usr/src/uts/common/sys/cpuvar.h b/usr/src/uts/common/sys/cpuvar.h
index bdefd08e3a..166c7180a5 100644
--- a/usr/src/uts/common/sys/cpuvar.h
+++ b/usr/src/uts/common/sys/cpuvar.h
@@ -22,6 +22,7 @@
/*
* Copyright (c) 1989, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012 by Delphix. All rights reserved.
+ * Copyright 2014 Igor Kozhukhov <ikozhukhov@gmail.com>.
*/
#ifndef _SYS_CPUVAR_H
@@ -32,6 +33,7 @@
#include <sys/disp.h>
#include <sys/processor.h>
+#include <sys/loadavg.h>
#if (defined(_KERNEL) || defined(_KMEMUSER)) && defined(_MACHDEP)
#include <sys/machcpuvar.h>
#endif
@@ -53,15 +55,6 @@ extern "C" {
struct squeue_set_s;
#define CPU_CACHE_COHERENCE_SIZE 64
-#define S_LOADAVG_SZ 11
-#define S_MOVAVG_SZ 10
-
-struct loadavg_s {
- int lg_cur; /* current loadavg entry */
- unsigned int lg_len; /* number entries recorded */
- hrtime_t lg_total; /* used to temporarily hold load totals */
- hrtime_t lg_loads[S_LOADAVG_SZ]; /* table of recorded entries */
-};
/*
* For fast event tracing.
diff --git a/usr/src/uts/common/sys/loadavg.h b/usr/src/uts/common/sys/loadavg.h
index 79de0eb887..b7ffc11b7c 100644
--- a/usr/src/uts/common/sys/loadavg.h
+++ b/usr/src/uts/common/sys/loadavg.h
@@ -21,14 +21,13 @@
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2014 Igor Kozhukhov <ikozhukhov@gmail.com>.
* Use is subject to license terms.
*/
#ifndef _SYS_LOADAVG_H
#define _SYS_LOADAVG_H
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#ifdef __cplusplus
extern "C" {
#endif
@@ -39,6 +38,16 @@ extern "C" {
#define LOADAVG_NSTATS 3
+#define S_LOADAVG_SZ 11
+#define S_MOVAVG_SZ 10
+
+struct loadavg_s {
+ int lg_cur; /* current loadavg entry */
+ unsigned int lg_len; /* number entries recorded */
+ hrtime_t lg_total; /* used to temporarily hold load totals */
+ hrtime_t lg_loads[S_LOADAVG_SZ]; /* table of recorded entries */
+};
+
#ifdef _KERNEL
extern int getloadavg(int *, int);
diff --git a/usr/src/uts/common/sys/zone.h b/usr/src/uts/common/sys/zone.h
index 6d6d324843..5a6dee1c73 100644
--- a/usr/src/uts/common/sys/zone.h
+++ b/usr/src/uts/common/sys/zone.h
@@ -21,6 +21,7 @@
/*
* Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright 2014 Nexenta Systems, Inc. All rights reserved.
+ * Copyright 2014 Igor Kozhukhov <ikozhukhov@gmail.com>.
*/
#ifndef _SYS_ZONE_H
@@ -321,7 +322,7 @@ typedef struct zone_net_data {
* libraries which may be defining ther own versions.
*/
#include <sys/list.h>
-#include <sys/cpuvar.h>
+#include <sys/loadavg.h>
#define GLOBAL_ZONEUNIQID 0 /* uniqid of the global zone */