Copyright (c) 2006, Sun Microsystems, Inc. All Rights Reserved.
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 or http://www.opensolaris.org/os/licensing. 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]
#include <sys/types.h> #include <sys/conf.h> #include <sys/ddi.h> #include <sys/sunddi.h> int ddi_intr_set_mask(ddi_intr_handle_t h);
int ddi_intr_clr_mask(ddi_intr_handle_t h);
DDI interrupt handle
The ddi_intr_clr_mask() function unmasks the given interrupt pointed by the device's interrupt handle h if the device or host bridge supports the masking operation.
The ddi_intr_set_mask() and ddi_intr_clr_mask() functions should be called only if an interrupt is enabled. Otherwise the framework will return DDI_EINVAL to such calls.
The mask cannot be cleared directly if the OS implementation has also temporarily masked the interrupt. A call to ddi_intr_clr_mask() must be preceded by a call to ddi_intr_set_mask(). It is not necessary to call ddi_intr_clr_mask() when adding and enabling the interrupt.
On success.
On encountering invalid input parameters or when an interrupt is not enabled.
On any implementation specific failure.
On device not supporting operation.
ATTRIBUTE TYPE ATTRIBUTE VALUE |
Interface Stability Committed |
Writing Device Drivers