xref: /illumos-gate/usr/src/man/man3devinfo/di_lnode_name.3devinfo (revision bbf215553c7233fbab8a0afdf1fac74c44781867)
te
Copyright (c) 2004, 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]
DI_LNODE_NAME 3DEVINFO "Mar 22, 2004"
NAME
di_lnode_name, di_lnode_devinfo, di_lnode_devt - return libdevinfo lnode information
SYNOPSIS

cc [ flag.\|.\|. ] file.\|.\|. -ldevinfo [ library.\|.\|. ]
#include <libdevinfo.h>

char *di_lnode_name(di_lnode_t lnode);

di_node_t di_lnode_devinfo(di_lnode_t lnode);

int di_lnode_devt(di_lnode_t lnode, dev_t *devt);
PARAMETERS
lnode

A handle to an lnode.

devt

A pointer to a dev_t that can be returned.

DESCRIPTION

These functions return libdevinfo lnode information.

The di_lnode_name() function returns a pointer to the name associated with lnode.

The di_lnode_devinfo() function returns a handle to the device node associated with lnode.

The di_lnode_devt() function sets the dev_t pointed to by the devt parameter to the dev_t associated with lnode.

RETURN VALUES

The di_lnode_name() function returns a pointer to the name associated with lnode.

The di_lnode_devinfo() function returns a handle to the device node associated with lnode.

The di_lnode_devt() function returns 0 if the requested attribute exists in lnode and was returned. It returns -1 if the requested attribute does not exist and sets errno to indicate the error.

ERRORS

The di_lnode_devt() function will fail if: EINVAL

An argument was invalid.

ATTRIBUTES

See attributes(7) for descriptions of the following attributes:

ATTRIBUTE TYPE ATTRIBUTE VALUE
Interface Stability Evolving
MT-Level Safe
SEE ALSO

di_init (3DEVINFO), libdevinfo (3LIB), attributes (7)