xref: /freebsd/lib/libgeom/libgeom.h (revision ba798fb226e81ad916c9728aad527862f277dc31)
1e13db587SPoul-Henning Kamp /*-
2e13db587SPoul-Henning Kamp  * Copyright (c) 2003 Poul-Henning Kamp
3e13db587SPoul-Henning Kamp  * All rights reserved.
4e13db587SPoul-Henning Kamp  *
5e13db587SPoul-Henning Kamp  * Redistribution and use in source and binary forms, with or without
6e13db587SPoul-Henning Kamp  * modification, are permitted provided that the following conditions
7e13db587SPoul-Henning Kamp  * are met:
8e13db587SPoul-Henning Kamp  * 1. Redistributions of source code must retain the above copyright
9e13db587SPoul-Henning Kamp  *    notice, this list of conditions and the following disclaimer.
10e13db587SPoul-Henning Kamp  * 2. Redistributions in binary form must reproduce the above copyright
11e13db587SPoul-Henning Kamp  *    notice, this list of conditions and the following disclaimer in the
12e13db587SPoul-Henning Kamp  *    documentation and/or other materials provided with the distribution.
13e13db587SPoul-Henning Kamp  * 3. The names of the authors may not be used to endorse or promote
14e13db587SPoul-Henning Kamp  *    products derived from this software without specific prior written
15e13db587SPoul-Henning Kamp  *    permission.
16e13db587SPoul-Henning Kamp  *
17e13db587SPoul-Henning Kamp  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18e13db587SPoul-Henning Kamp  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19e13db587SPoul-Henning Kamp  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20e13db587SPoul-Henning Kamp  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
21e13db587SPoul-Henning Kamp  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22e13db587SPoul-Henning Kamp  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23e13db587SPoul-Henning Kamp  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24e13db587SPoul-Henning Kamp  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25e13db587SPoul-Henning Kamp  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26e13db587SPoul-Henning Kamp  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27e13db587SPoul-Henning Kamp  * SUCH DAMAGE.
28e13db587SPoul-Henning Kamp  *
29e13db587SPoul-Henning Kamp  * $FreeBSD$
30e13db587SPoul-Henning Kamp  */
31e13db587SPoul-Henning Kamp #ifndef _LIBGEOM_H_
32e13db587SPoul-Henning Kamp #define _LIBGEOM_H_
33e13db587SPoul-Henning Kamp 
34ba798fb2SPoul-Henning Kamp #include <sys/time.h>
35e13db587SPoul-Henning Kamp #include <geom/geom_stats.h>
36e13db587SPoul-Henning Kamp 
37e13db587SPoul-Henning Kamp void geom_stats_close(void);
38e13db587SPoul-Henning Kamp void geom_stats_resync(void);
39e13db587SPoul-Henning Kamp int geom_stats_open(void);
40e13db587SPoul-Henning Kamp void *geom_stats_snapshot_get(void);
41e13db587SPoul-Henning Kamp void geom_stats_snapshot_free(void *arg);
42e13db587SPoul-Henning Kamp void geom_stats_snapshot_timestamp(void *arg, struct timespec *tp);
43e13db587SPoul-Henning Kamp void geom_stats_snapshot_reset(void *arg);
44e13db587SPoul-Henning Kamp struct g_stat *geom_stats_snapshot_next(void *arg);
45e13db587SPoul-Henning Kamp 
46e13db587SPoul-Henning Kamp #endif /* _LIBGEOM_H_ */
47