kstat.h revision 861bfc8941f2c557f1bcb7a6d7f62f9da98ee4db
66448911ac89c254e89afc52e114402115a497e3David Höppner/*
66448911ac89c254e89afc52e114402115a497e3David Höppner * CDDL HEADER START
66448911ac89c254e89afc52e114402115a497e3David Höppner *
66448911ac89c254e89afc52e114402115a497e3David Höppner * The contents of this file are subject to the terms of the
66448911ac89c254e89afc52e114402115a497e3David Höppner * Common Development and Distribution License (the "License").
66448911ac89c254e89afc52e114402115a497e3David Höppner * You may not use this file except in compliance with the License.
66448911ac89c254e89afc52e114402115a497e3David Höppner *
66448911ac89c254e89afc52e114402115a497e3David Höppner * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
66448911ac89c254e89afc52e114402115a497e3David Höppner * or http://www.opensolaris.org/os/licensing.
66448911ac89c254e89afc52e114402115a497e3David Höppner * See the License for the specific language governing permissions
66448911ac89c254e89afc52e114402115a497e3David Höppner * and limitations under the License.
66448911ac89c254e89afc52e114402115a497e3David Höppner *
66448911ac89c254e89afc52e114402115a497e3David Höppner * When distributing Covered Code, include this CDDL HEADER in each
66448911ac89c254e89afc52e114402115a497e3David Höppner * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
66448911ac89c254e89afc52e114402115a497e3David Höppner * If applicable, add the following below this CDDL HEADER, with the
66448911ac89c254e89afc52e114402115a497e3David Höppner * fields enclosed by brackets "[]" replaced with your own identifying
66448911ac89c254e89afc52e114402115a497e3David Höppner * information: Portions Copyright [yyyy] [name of copyright owner]
66448911ac89c254e89afc52e114402115a497e3David Höppner *
66448911ac89c254e89afc52e114402115a497e3David Höppner * CDDL HEADER END
66448911ac89c254e89afc52e114402115a497e3David Höppner */
66448911ac89c254e89afc52e114402115a497e3David Höppner/*
66448911ac89c254e89afc52e114402115a497e3David Höppner * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
66448911ac89c254e89afc52e114402115a497e3David Höppner * Copyright 2013 David Hoeppner. All rights reserved.
66448911ac89c254e89afc52e114402115a497e3David Höppner * Copyright 2013 Nexenta Systems, Inc. All rights reserved.
66448911ac89c254e89afc52e114402115a497e3David Höppner */
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#ifndef _STAT_KSTAT_H
66448911ac89c254e89afc52e114402115a497e3David Höppner#define _STAT_KSTAT_H
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner/*
66448911ac89c254e89afc52e114402115a497e3David Höppner * Structures needed by the kstat reader functions.
66448911ac89c254e89afc52e114402115a497e3David Höppner */
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/var.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/utsname.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/sysinfo.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/flock.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/dnlc.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <regex.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <nfs/nfs.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <nfs/nfs_clnt.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#ifdef __sparc
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <vm/hat_sfmmu.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/simmstat.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/sysctrl.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#include <sys/fhc.h>
66448911ac89c254e89afc52e114402115a497e3David Höppner#endif
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define KSTAT_DATA_HRTIME (KSTAT_DATA_STRING + 1)
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnertypedef union ks_value {
66448911ac89c254e89afc52e114402115a497e3David Höppner char c[16];
66448911ac89c254e89afc52e114402115a497e3David Höppner int32_t i32;
66448911ac89c254e89afc52e114402115a497e3David Höppner uint32_t ui32;
66448911ac89c254e89afc52e114402115a497e3David Höppner struct {
66448911ac89c254e89afc52e114402115a497e3David Höppner union {
66448911ac89c254e89afc52e114402115a497e3David Höppner char *ptr;
66448911ac89c254e89afc52e114402115a497e3David Höppner char __pad[8];
66448911ac89c254e89afc52e114402115a497e3David Höppner } addr;
66448911ac89c254e89afc52e114402115a497e3David Höppner uint32_t len;
66448911ac89c254e89afc52e114402115a497e3David Höppner } str;
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner int64_t i64;
66448911ac89c254e89afc52e114402115a497e3David Höppner uint64_t ui64;
66448911ac89c254e89afc52e114402115a497e3David Höppner} ks_value_t;
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_HRTIME(I, S, N) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.ui64 = S->N; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, #N, &v, KSTAT_DATA_UINT64); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_INT32(I, S, N) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.i32 = S->N; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, #N, &v, KSTAT_DATA_INT32); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_UINT32(I, S, N) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.ui32 = S->N; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, #N, &v, KSTAT_DATA_UINT32); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_INT64(I, S, N) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.i64 = S->N; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, #N, &v, KSTAT_DATA_INT64); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_UINT64(I, S, N) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.ui64 = S->N; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, #N, &v, KSTAT_DATA_UINT64); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner/*
66448911ac89c254e89afc52e114402115a497e3David Höppner * We dont want const "strings" because we free
66448911ac89c254e89afc52e114402115a497e3David Höppner * the instances later.
66448911ac89c254e89afc52e114402115a497e3David Höppner */
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_STRING(I, S, N) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.str.addr.ptr = safe_strdup(S->N); \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.str.len = strlen(S->N); \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, #N, &v, KSTAT_DATA_STRING); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_HRTIME_X(I, N, V) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.ui64 = V; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, N, &v, KSTAT_DATA_HRTIME); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_INT32_X(I, N, V) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.i32 = V; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, N, &v, KSTAT_DATA_INT32); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_UINT32_X(I, N, V) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.ui32 = V; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, N, &v, KSTAT_DATA_UINT32); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_UINT64_X(I, N, V) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.ui64 = V; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, N, &v, KSTAT_DATA_UINT64); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_STRING_X(I, N, V) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.str.addr.ptr = safe_strdup(V); \
861bfc8941f2c557f1bcb7a6d7f62f9da98ee4dbTheo Schlossnagle v.str.len = (V) ? strlen(V) : 0; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, N, &v, KSTAT_DATA_STRING); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define SAVE_CHAR_X(I, N, V) \
66448911ac89c254e89afc52e114402115a497e3David Höppner{ \
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t v; \
e633f2d79475b51f0a4d46972282225abf851733Richard Lowe (void) asprintf(&v.str.addr.ptr, "%c", V); \
66448911ac89c254e89afc52e114402115a497e3David Höppner v.str.len = 1; \
66448911ac89c254e89afc52e114402115a497e3David Höppner nvpair_insert(I, N, &v, KSTAT_DATA_STRING); \
66448911ac89c254e89afc52e114402115a497e3David Höppner}
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define DFLT_FMT \
66448911ac89c254e89afc52e114402115a497e3David Höppner "module: %-30.30s instance: %-6d\n" \
66448911ac89c254e89afc52e114402115a497e3David Höppner "name: %-30.30s class: %-.30s\n"
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define JSON_FMT \
66448911ac89c254e89afc52e114402115a497e3David Höppner "{\n\t\"module\": \"%s\",\n" \
66448911ac89c254e89afc52e114402115a497e3David Höppner "\t\"instance\": %d,\n" \
66448911ac89c254e89afc52e114402115a497e3David Höppner "\t\"name\": \"%s\",\n" \
66448911ac89c254e89afc52e114402115a497e3David Höppner "\t\"class\": \"%s\",\n" \
66448911ac89c254e89afc52e114402115a497e3David Höppner "\t\"type\": %d,\n"
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#define KS_DFMT "\t%-30s "
66448911ac89c254e89afc52e114402115a497e3David Höppner#define KS_JFMT "\t\t\"%s\": "
66448911ac89c254e89afc52e114402115a497e3David Höppner#define KS_PFMT "%s:%d:%s:%s"
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnertypedef struct ks_instance {
66448911ac89c254e89afc52e114402115a497e3David Höppner list_node_t ks_next;
66448911ac89c254e89afc52e114402115a497e3David Höppner char ks_name[KSTAT_STRLEN];
66448911ac89c254e89afc52e114402115a497e3David Höppner char ks_module[KSTAT_STRLEN];
66448911ac89c254e89afc52e114402115a497e3David Höppner char ks_class[KSTAT_STRLEN];
66448911ac89c254e89afc52e114402115a497e3David Höppner int ks_instance;
66448911ac89c254e89afc52e114402115a497e3David Höppner uchar_t ks_type;
66448911ac89c254e89afc52e114402115a497e3David Höppner hrtime_t ks_snaptime;
66448911ac89c254e89afc52e114402115a497e3David Höppner list_t ks_nvlist;
66448911ac89c254e89afc52e114402115a497e3David Höppner} ks_instance_t;
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnertypedef struct ks_nvpair {
66448911ac89c254e89afc52e114402115a497e3David Höppner list_node_t nv_next;
66448911ac89c254e89afc52e114402115a497e3David Höppner char name[KSTAT_STRLEN];
66448911ac89c254e89afc52e114402115a497e3David Höppner uchar_t data_type;
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_value_t value;
66448911ac89c254e89afc52e114402115a497e3David Höppner} ks_nvpair_t;
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnertypedef struct ks_pattern {
66448911ac89c254e89afc52e114402115a497e3David Höppner char *pstr;
66448911ac89c254e89afc52e114402115a497e3David Höppner regex_t preg;
66448911ac89c254e89afc52e114402115a497e3David Höppner} ks_pattern_t;
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnertypedef struct ks_selector {
66448911ac89c254e89afc52e114402115a497e3David Höppner list_node_t ks_next;
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_pattern_t ks_module;
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_pattern_t ks_instance;
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_pattern_t ks_name;
66448911ac89c254e89afc52e114402115a497e3David Höppner ks_pattern_t ks_statistic;
66448911ac89c254e89afc52e114402115a497e3David Höppner} ks_selector_t;
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void usage(void);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic int compare_instances(ks_instance_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void nvpair_insert(ks_instance_t *, char *, ks_value_t *, uchar_t);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic boolean_t ks_match(const char *, ks_pattern_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic ks_selector_t *new_selector(void);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void ks_instances_read(kstat_ctl_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void ks_value_print(ks_nvpair_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void ks_instance_print(ks_instance_t *, ks_nvpair_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void ks_instances_print(void);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic char *ks_safe_strdup(char *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void ks_sleep_until(hrtime_t *, hrtime_t, int, int *);
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner/* Raw kstat readers */
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_cpu_stat(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_var(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_ncstats(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_sysinfo(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_vminfo(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_nfs(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppner#ifdef __sparc
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_sfmmu_global_stat(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_sfmmu_tsbsize_stat(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_simmstat(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppner/* Helper function for save_temperature() */
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic char *short_array_to_string(short *, int);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_temperature(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_temp_over(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_ps_shadow(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_fault_list(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppner#endif
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner/* Named kstat readers */
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_named(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_intr(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_io(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic void save_timer(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner/* Typedef for raw kstat reader functions */
66448911ac89c254e89afc52e114402115a497e3David Höppnertypedef void (*kstat_raw_reader_t)(kstat_t *, ks_instance_t *);
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic struct {
66448911ac89c254e89afc52e114402115a497e3David Höppner kstat_raw_reader_t fn;
66448911ac89c254e89afc52e114402115a497e3David Höppner char *name;
66448911ac89c254e89afc52e114402115a497e3David Höppner} ks_raw_lookup[] = {
66448911ac89c254e89afc52e114402115a497e3David Höppner /* Function name kstat name */
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_cpu_stat, "cpu_stat:cpu_stat"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_var, "unix:var"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_ncstats, "unix:ncstats"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_sysinfo, "unix:sysinfo"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_vminfo, "unix:vminfo"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_nfs, "nfs:mntinfo"},
66448911ac89c254e89afc52e114402115a497e3David Höppner#ifdef __sparc
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_sfmmu_global_stat, "unix:sfmmu_global_stat"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_sfmmu_tsbsize_stat, "unix:sfmmu_tsbsize_stat"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_simmstat, "unix:simm-status"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_temperature, "unix:temperature"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_temp_over, "unix:temperature override"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_ps_shadow, "unix:ps_shadow"},
66448911ac89c254e89afc52e114402115a497e3David Höppner {save_fault_list, "unix:fault_list"},
66448911ac89c254e89afc52e114402115a497e3David Höppner#endif
66448911ac89c254e89afc52e114402115a497e3David Höppner {NULL, NULL},
66448911ac89c254e89afc52e114402115a497e3David Höppner};
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppnerstatic kstat_raw_reader_t lookup_raw_kstat_fn(char *, char *);
66448911ac89c254e89afc52e114402115a497e3David Höppner
66448911ac89c254e89afc52e114402115a497e3David Höppner#endif /* _STAT_KSTAT_H */