User Tools

Site Tools


solaris:ddi_prop_walk_list.9f

ddi_prop_walk_list


NAME

ddi_prop_walk_list, ddi_prop_search_list - walk a property list on a device and search property list for a
property

SYNOPSIS

ddi_prop_walk_list(dev_info_t *devi, ddi_proplist_type_t list_type,
ddi_prop_walk_rval_t (*callback)(ddi_prop_t *prop, void *args),
void *args);

ddi_prop_search_list(dev_info_t *devi, ddi_proplist_type_t list_type,
dev_t dev, char *name, int prop_type,
void (*callback)(ddi_prop_t *prop, void *args), void *args);

PARAMETERS

devi

Pointer to dev_info node

list_type

The property list. The following list contains the property list:

DDI_DRV_PROPS

Driver defined properties

DDI_SYS_PROPS

System defined properties

DDI_HW_PROPS

Hardware defined properties

DDI_GLOBAL_PROPS

Global driver.conf properties

DDI_VENDOR_PROPS

Vendor defined properties

DDI_ADMIN_PROPS

Admin defined properties

DDI_VENDOR_GLOBAL_PROPS

Vendor global defined properties

DDI_ADMIN_GLOBAL_PROPS

Admin global defined properties

DDI_COMPATIBLE_PROPS

Compatible defined properties

dev

dev_t of the property to match, DDI_DEV_T_ANY is used to match any dev_t

name

The property name to match

prop_type

The property type to match. Can be one of the following values:

oDDI_PROP_TYPE_INT
oDDI_PROP_TYPE_STRING
oDDI_PROP_TYPE_BYTE
oDDI_PROP_TYPE_INT64

callback

A driver-supplied function called for each property

args

An argument provided by the driver for the callback

DESCRIPTION

The ddi_prop_walk_list() function accesses the properties on one of the property lists of a device. The driver-provided function is called for each property on the list, with the argument to this callback providing the name, dev_t, property value, length, and type. This function must return DDI_PROP_WALK_CONTINUE or DDI_PROP_WALK_TERMINATE to either continue or terminate the property list traversal respectively.

The ddi_prop_search_list() function searches the property list of a device for a property matching the name, type, and dev_t provided, in the same manner as the ddi_prop_walk_list() function. DDI_DEV_T_ANY matches any dev_t, including a property with no dev_t (DDI_DEV_T_NONE).

The driver-provided function is called for the matching property. The consistency of the information of a property is only guaranteed during the context of the driver-supplied callback.

The property and property list information returned here is read-only and must not be modified. To update a value of a property, see the ddi_prop_update(9F) man page.

CONTEXT

These functions can be called from user or kernel context.

SEE ALSO

ddi_prop_lookup(9F), ddi_prop_update(9F), ddi_prop_name(9F)


solaris/ddi_prop_walk_list.9f.txt · Last modified: 2023/07/19 08:57 by A User Not Logged in