xref: /freebsd/lib/libpmc/pmc_init.3 (revision aa12cea2ccc6e686d6d31cf67d6bc69cbc1ba744)
1f28834c1SJoseph Koshy.\" Copyright (c) 2007 Joseph Koshy.  All rights reserved.
2f28834c1SJoseph Koshy.\"
3f28834c1SJoseph Koshy.\" Redistribution and use in source and binary forms, with or without
4f28834c1SJoseph Koshy.\" modification, are permitted provided that the following conditions
5f28834c1SJoseph Koshy.\" are met:
6f28834c1SJoseph Koshy.\" 1. Redistributions of source code must retain the above copyright
7f28834c1SJoseph Koshy.\"    notice, this list of conditions and the following disclaimer.
8f28834c1SJoseph Koshy.\" 2. Redistributions in binary form must reproduce the above copyright
9f28834c1SJoseph Koshy.\"    notice, this list of conditions and the following disclaimer in the
10f28834c1SJoseph Koshy.\"    documentation and/or other materials provided with the distribution.
11f28834c1SJoseph Koshy.\"
12f28834c1SJoseph Koshy.\" This software is provided by Joseph Koshy ``as is'' and
13f28834c1SJoseph Koshy.\" any express or implied warranties, including, but not limited to, the
14f28834c1SJoseph Koshy.\" implied warranties of merchantability and fitness for a particular purpose
15f28834c1SJoseph Koshy.\" are disclaimed.  in no event shall Joseph Koshy be liable
16f28834c1SJoseph Koshy.\" for any direct, indirect, incidental, special, exemplary, or consequential
17f28834c1SJoseph Koshy.\" damages (including, but not limited to, procurement of substitute goods
18f28834c1SJoseph Koshy.\" or services; loss of use, data, or profits; or business interruption)
19f28834c1SJoseph Koshy.\" however caused and on any theory of liability, whether in contract, strict
20f28834c1SJoseph Koshy.\" liability, or tort (including negligence or otherwise) arising in any way
21f28834c1SJoseph Koshy.\" out of the use of this software, even if advised of the possibility of
22f28834c1SJoseph Koshy.\" such damage.
23f28834c1SJoseph Koshy.\"
24f28834c1SJoseph Koshy.\" $FreeBSD$
25f28834c1SJoseph Koshy.\"
26f28834c1SJoseph Koshy.Dd November 24, 2007
27f28834c1SJoseph Koshy.Dt PMC_INIT 3
28*aa12cea2SUlrich Spörlein.Os
29f28834c1SJoseph Koshy.Sh NAME
30f28834c1SJoseph Koshy.Nm pmc_init
31f28834c1SJoseph Koshy.Nd initialize library
32f28834c1SJoseph Koshy.Sh LIBRARY
33f28834c1SJoseph Koshy.Lb libpmc
34f28834c1SJoseph Koshy.Sh SYNOPSIS
35f28834c1SJoseph Koshy.In pmc.h
36f28834c1SJoseph Koshy.Ft int
37f28834c1SJoseph Koshy.Fn pmc_init void
38f28834c1SJoseph Koshy.Sh DESCRIPTION
39f28834c1SJoseph KoshyFunction
40f28834c1SJoseph Koshy.Fn pmc_init
41f28834c1SJoseph Koshyinitializes the PMC library.
42f28834c1SJoseph KoshyThis function must be called before any of the other functions in the
43f28834c1SJoseph Koshylibrary.
44f28834c1SJoseph Koshy.Sh RETURN VALUES
45f28834c1SJoseph Koshy.Rv -std pmc_init
46f28834c1SJoseph Koshy.Sh ERRORS
47f28834c1SJoseph KoshyA call to
48f28834c1SJoseph Koshy.Fn pmc_init
49f28834c1SJoseph Koshymay fail with the following errors:
50f28834c1SJoseph Koshy.Bl -tag -width Er
51f28834c1SJoseph Koshy.It Bq Er ENOENT
52f28834c1SJoseph KoshyThe
53f28834c1SJoseph Koshy.Xr hwpmc 4
54f28834c1SJoseph Koshymodule was not found in the kernel.
55f28834c1SJoseph Koshy.It Bq Er EPROGMISMATCH
56f28834c1SJoseph KoshyThe library's version number did not match that expected by
57f28834c1SJoseph Koshy.Xr hwpmc 4 .
58f28834c1SJoseph Koshy.It Bq Er ENXIO
59f28834c1SJoseph KoshyPMC hardware on this system is unsupported.
60f28834c1SJoseph Koshy.El
61f28834c1SJoseph Koshy.Sh SEE ALSO
62f28834c1SJoseph Koshy.Xr pmc 3 ,
63f28834c1SJoseph Koshy.Xr hwpmc 4
64