2 .\" Copyright (c) 2006, Sun Microsystems, Inc.
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_DEV_IS_SID 9F "Jan 16, 2006"
8 ddi_dev_is_sid \- tell whether a device is self-identifying
14 #include <sys/sunddi.h>
18 \fBint\fR \fBddi_dev_is_sid\fR(\fBdev_info_t *\fR\fIdip\fR);
24 Solaris DDI specific (Solaris DDI).
32 A pointer to the device's \fBdev_info\fR structure.
38 The \fBddi_dev_is_sid()\fR function tells the caller whether the device
39 described by \fIdip\fR is self-identifying, that is, a device that can
40 unequivocally tell the system that it exists. This is useful for drivers that
41 support both a self-identifying as well as a non-self-identifying variants of a
42 device (and therefore must be probed).
47 \fB\fBDDI_SUCCESS\fR\fR
50 Device is self-identifying.
56 \fB\fBDDI_FAILURE\fR\fR
59 Device is not self-identifying.
65 The \fBddi_dev_is_sid()\fR function can be called from user, interrupt, or
73 3 bz_probe(dev_info_t *dip)
76 6 if (ddi_dev_is_sid(dip) == DDI_SUCCESS) {
78 8 * This is the self-identifying version (OpenBoot).
79 9 * No need to probe for it because we know it is there.
80 10 * The existence of dip && ddi_dev_is_sid() proves this.
82 12 return (DDI_PROBE_DONTCARE);
85 15 * Not a self-identifying variant of the device. Now we have to
86 16 * do some work to see whether it is really attached to the
96 \fBprobe\fR(9E) \fIWriting Device Drivers\fR