nightly: remove unused BINARCHIVE
[unleashed.git] / share / man / man9f / ddi_intr_get_pending.9f
blob6fca6effae23bd18484fc8670c2beb6563fd65f1
1 '\" te
2 .\" Copyright (c) 2005, Sun Microsystems, Inc. All Rights Reserved.
3 .\" 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.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
5 .\" 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]
6 .TH DDI_INTR_GET_PENDING 9F "Apr 7, 2005"
7 .SH NAME
8 ddi_intr_get_pending \- get pending bit for a given interrupt
9 .SH SYNOPSIS
10 .LP
11 .nf
12 #include <sys/types.h>
13 #include <sys/conf.h>
14 #include <sys/ddi.h>
15 #include <sys/sunddi.h>
17 \fBint\fR \fBddi_intr_get_pending\fR(\fBddi_intr_handle_t\fR \fIh\fR, \fBint *\fR\fIpendingp\fR);
18 .fi
20 .SH INTERFACE LEVEL
21 .sp
22 .LP
23 Solaris DDI specific (Solaris DDI).
24 .SH PARAMETERS
25 .sp
26 .ne 2
27 .na
28 \fB\fIh\fR\fR
29 .ad
30 .RS 12n
31 DDI interrupt handle
32 .RE
34 .sp
35 .ne 2
36 .na
37 \fB\fIpendingp\fR\fR
38 .ad
39 .RS 12n
40 Pointer to the pending capability returned for this handle
41 .RE
43 .SH DESCRIPTION
44 .sp
45 .LP
46 The \fBddi_intr_get_pending()\fR function returns non-zero as the integer
47 pointed to by the \fIpendingp\fR argument if a corresponding interrupt is
48 pending. The corresponding interrupt handle \fIh\fR must already be allocated.
49 The call succeeds if the device or host bridge supports the ability to read the
50 interrupt pending bits of its interrupts. The driver should use
51 \fBddi_intr_get_cap()\fR function to see if the \fBDDI_INTR_FLAG_PENDING\fR
52 flag is returned to indicate that interrupts support interrupt pending bits.
53 .sp
54 .LP
55 If the \fBDDI_INTR_FLAG_PENDING\fR capability is not supported,
56 \fBddi_intr_get_pending()\fR returns \fBDDI_ENOTSUP\fR and zero in
57 \fIpendingp\fR.
58 .SH RETURN VALUES
59 .sp
60 .LP
61 The \fBddi_intr_get_pending()\fR function returns:
62 .sp
63 .ne 2
64 .na
65 \fB\fBDDI_SUCCESS\fR\fR
66 .ad
67 .RS 15n
68 On success.
69 .RE
71 .sp
72 .ne 2
73 .na
74 \fB\fBDDI_EINVAL\fR\fR
75 .ad
76 .RS 15n
77 On encountering invalid input parameters.
78 .RE
80 .sp
81 .ne 2
82 .na
83 \fB\fBDDI_FAILURE\fR\fR
84 .ad
85 .RS 15n
86 On any implementation specific failure.
87 .RE
89 .sp
90 .ne 2
91 .na
92 \fB\fBDDI_ENOTSUP\fR\fR
93 .ad
94 .RS 15n
95 On device not supporting operation.
96 .RE
98 .SH CONTEXT
99 .sp
101 The \fBddi_intr_get_pending()\fR function can be called from either user or
102 kernel non-interrupt context.
103 .SH ATTRIBUTES
106 See \fBattributes\fR(5) for descriptions of the following attributes:
111 box;
112 c | c
113 l | l .
114 ATTRIBUTE TYPE  ATTRIBUTE VALUE
116 Interface Stability     Evolving
119 .SH SEE ALSO
122 \fBattributes\fR(5), \fBddi_intr_block_enable\fR(9F),
123 \fBddi_intr_block_disable\fR(9F), \fBddi_intr_clr_mask\fR(9F),
124 \fBddi_intr_disable\fR(9F), \fBddi_intr_enable\fR(9F),
125 \fBddi_intr_set_mask\fR(9F)
128 \fIWriting Device Drivers\fR
129 .SH NOTES
132 Any consumer of this interface should verify that the return value is not equal
133 to \fBDDI_SUCCESS\fR. Incomplete checking for failure codes could result in
134 inconsistent behavior among platforms.