/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* 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
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2007 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _RCAPD_H
#define _RCAPD_H
#pragma ident "%Z%%M% %I% %E% SMI"
#ifdef __cplusplus
extern "C" {
#endif
#include <procfs.h>
#include "rcapd_conf.h"
/* flushes of the ignored set */
/*
* set the buffer length for /proc-based path names based on the actual
* length of the largest pid
*/
#define RCAPD__STR(a) #a
"/pagedata"))
/*
* lcollection_insert_update() result flags
*/
typedef enum {
} rcid_type_t;
typedef struct {
/*
* The following field could just be a rcid_type_t but it gets
* written out to a file as binary data for communication between
* 64-bit rcapd & 32-bit rcapstat, so we need to force a standard size
* and alignment here.
*/
} rcid_t;
typedef enum {
struct lmapping;
struct lprocess;
struct lcollection;
struct prxmap;
struct psinfo;
/*
* Per-process data.
*/
typedef struct lprocess {
/* other unscannable process */
/* current pagedata */
} lprocess_t;
/*
* Collection statistics.
*/
typedef struct {
/* enforced, but wasn't (due to low */
/* global memory pressure, or global */
/* scanner being activated) */
/* at last completion */
/* revolutions of clock hand after */
/* which the excess was not */
/* completely reduced */
/*
* Collection.
*/
typedef struct lcollection {
/* "unknown" */
/*
* Collection report.
*/
typedef struct lcollection_report {
/* "unknown" */
lprocess_t *);
extern void lcollection_freq_move(lprocess_t *);
int *changes);
extern void lcollection_free(lcollection_t *);
extern void lcollection_update(lcollection_update_type_t);
extern void list_walk_collection(int (*)(lcollection_t *, void *), void *);
extern int lprocess_update_psinfo_fd_cb(void *, int);
extern void lprocess_free(lprocess_t *);
extern void scan_abort(void);
extern void check_update_statistics(void);
/*
* Global (in rcapd only) variables.
*/
extern uint64_t phys_total;
extern int should_run;
#ifdef __cplusplus
}
#endif
#endif /* _RCAPD_H */