8322 nl: misleading-indentation
[unleashed/tickless.git] / usr / src / cmd / prstat / prfile.h
blobbedbc7a72f41ee8e0c7b33ac8368fb29ae132c0a
1 /*
2 * CDDL HEADER START
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
7 * with the License.
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
20 * CDDL HEADER END
23 * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
27 #ifndef _PRFILE_H
28 #define _PRFILE_H
30 #pragma ident "%Z%%M% %I% %E% SMI"
32 #include <sys/types.h>
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
38 #define MAX_PROCFS_PATH 40
39 #define NUM_RESERVED_FD 10
41 typedef struct fd {
42 int fd_fd;
43 int fd_flags;
44 char fd_name[MAX_PROCFS_PATH];
45 } fd_t;
47 typedef struct fds {
48 pid_t fds_pid;
49 fd_t *fds_psinfo;
50 fd_t *fds_usage;
51 fd_t *fds_lpsinfo;
52 fd_t *fds_lusage;
53 struct fds *fds_next;
54 } fds_t;
56 extern void fd_init(int);
57 extern void fd_exit();
58 extern fd_t *fd_open(char *, int, fd_t *);
59 extern int fd_getfd(fd_t *);
60 extern void fd_close(fd_t *);
61 extern void fd_closeall();
62 extern void fd_update();
63 extern fds_t *fds_get(pid_t);
64 extern void fds_rm(pid_t);
66 #ifdef __cplusplus
68 #endif
70 #endif /* _PRFILE_H */