Copyright (c) 2008 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/ddi.h> #include <sys/sunddi.h> int prefixquiesce(dev_info_t *dip);
int ddi_quiesce_not_needed(dev_info_t *dip);
A pointer to the device's dev_info structure.
quiesce() is only called for an attached device instance as one of the final operations of a reboot sequence, and no other thread can be active for this device. The system guarantees that no other driver entry point is active or invoked while quiesce() is invoked. The system also guarantees that no timeout or taskq is invoked. The system is single-threaded and can not be interrupted. Therefore, the driver's quiesce() implementation must not use locks or timeouts, or rely on them being called. The driver must discard all outstanding I/O instead of waiting for completion. At the conclusion of the quiesce() operation, the driver must guarantee that the device no longer has access to memory or interrupts.
The only DDI interfaces that can be called by the quiesce() implementation are non-blocking functions, such as the ddi_get*() and ddi_put*() functions.
If quiesce() determines a particular instance of the device cannot be quiesced when requested because of some exceptional condition, quiesce() returns DDI_FAILURE. This rarely happens.
If a driver has previously implemented the obsolete reset() interface, its functionality must be merged into quiesce(). The driver's reset() routine is no longer called if an implementation of quiesce() is present.
ddi_quiesce_not_needed() always returns DDI_SUCCESS. A driver can set its devo_quiesce device function to ddi_quiesce_not_needed() to indicate that the device it manages does not need to be quiesced.
The device has been successfully quiesced.
The operation failed.