Lines Matching refs:DCP
58 #define DCP(x) ((struct devctl_hdl *)(x))
83 if (DCP(hdl)->fd != -1)
84 (void) close(DCP(hdl)->fd);
86 if (DCP(hdl)->opath != NULL)
87 free(DCP(hdl)->opath);
89 if (DCP(hdl)->nodename != NULL)
90 free(DCP(hdl)->nodename);
92 if (DCP(hdl)->unitaddr != NULL)
93 free(DCP(hdl)->unitaddr);
456 dcp->fd = dup(DCP(pc)->fd);
484 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
485 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
490 rv = dc_cmd(DEVCTL_PM_RAISE_PWR, 0, DCP(dcp), NULL, NULL);
506 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
507 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
512 rv = dc_cmd(DEVCTL_PM_CHANGE_PWR_HIGH, 0, DCP(dcp), NULL, NULL);
528 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
529 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
534 rv = dc_cmd(DEVCTL_PM_CHANGE_PWR_LOW, 0, DCP(dcp), NULL, NULL);
550 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
551 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
556 rv = dc_cmd(DEVCTL_PM_IDLE_COMP, 0, DCP(dcp), NULL, NULL);
572 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
573 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
578 rv = dc_cmd(DEVCTL_PM_BUSY_COMP, 0, DCP(dcp), NULL, NULL);
600 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
601 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
606 rv = dc_cmd(DEVCTL_PM_BUSY_COMP_TEST, 0, DCP(dcp), NULL,
629 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
630 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
635 rv = dc_cmd(DEVCTL_PM_FAIL_SUSPEND, 0, DCP(dcp), NULL, NULL);
653 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
658 rv = dc_cmd(DEVCTL_PM_BUS_STRICT_TEST, 0, DCP(dcp), NULL,
681 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
682 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
687 rv = dc_cmd(DEVCTL_PM_PROM_PRINTF, 0, DCP(dcp), NULL, NULL);
704 if (dcp == NULL || (DCP(dcp)->hdltype != DEVCTL_PM_DEV &&
705 DCP(dcp)->hdltype != DEVCTL_PM_BUS)) {
711 DCP(dcp), NULL, NULL);
727 if (dcp == NULL || DCP(dcp)->hdltype != DEVCTL_PM_DEV) {
732 rv = dc_cmd(DEVCTL_PM_NO_LOWER_POWER, 0, DCP(dcp), NULL, NULL);
749 if (dcp == NULL || DCP(dcp)->hdltype != DEVCTL_PM_BUS) {
754 rv = dc_cmd(DEVCTL_PM_BUS_NO_INVOL, 0, DCP(dcp), NULL, NULL);
769 if (dcp == NULL || DCP(dcp)->hdltype != DEVCTL_DEVICE) {
774 rv = dc_cmd(DEVCTL_DEVICE_ONLINE, 0, DCP(dcp), NULL, NULL);
790 if (dcp == NULL || DCP(dcp)->hdltype != DEVCTL_DEVICE) {
795 rv = dc_cmd(DEVCTL_DEVICE_OFFLINE, 0, DCP(dcp), NULL, NULL);
811 if (dcp == NULL || DCP(dcp)->hdltype != DEVCTL_DEVICE) {
816 rv = dc_cmd(DEVCTL_DEVICE_REMOVE, 0, DCP(dcp), NULL, NULL);
833 rv = dc_cmd(DEVCTL_BUS_QUIESCE, 0, DCP(dcp), NULL, NULL);
846 rv = dc_cmd(DEVCTL_BUS_UNQUIESCE, 0, DCP(dcp), NULL, NULL);
859 rv = dc_cmd(DEVCTL_BUS_RESET, 0, DCP(dcp), NULL, NULL);
872 rv = dc_cmd(DEVCTL_BUS_RESETALL, 0, DCP(dcp), NULL, NULL);
885 rv = dc_cmd(DEVCTL_DEVICE_RESET, 0, DCP(dcp), NULL, NULL);
904 rv = dc_cmd(DEVCTL_DEVICE_GETSTATE, 0, DCP(dcp), NULL,
930 rv = dc_cmd(DEVCTL_BUS_GETSTATE, 0, DCP(dcp), NULL,
950 rv = dc_cmd(DEVCTL_BUS_CONFIGURE, 0, DCP(dcp), NULL, NULL);
963 rv = dc_cmd(DEVCTL_BUS_UNCONFIGURE, 0, DCP(dcp), NULL, NULL);
992 rv = dc_cmd(DEVCTL_BUS_DEV_CREATE, flags, DCP(dcp),
1002 (void) strcat(devpath, DCP(dcp)->opath);
1034 rv = dc_cmd(DEVCTL_AP_CONNECT, 0, DCP(dcp), ap_data, NULL);
1047 rv = dc_cmd(DEVCTL_AP_DISCONNECT, 0, DCP(dcp), ap_data, NULL);
1060 rv = dc_cmd(DEVCTL_AP_INSERT, 0, DCP(dcp), ap_data, NULL);
1073 rv = dc_cmd(DEVCTL_AP_REMOVE, 0, DCP(dcp), ap_data, NULL);
1086 rv = dc_cmd(DEVCTL_AP_CONFIGURE, 0, DCP(dcp), ap_data, NULL);
1099 rv = dc_cmd(DEVCTL_AP_UNCONFIGURE, 0, DCP(dcp), ap_data, NULL);
1114 rv = dc_cmd(DEVCTL_AP_GETSTATE, 0, DCP(dcp), ap_data,
1314 (void) snprintf(pathbuf, bufsz, "%s", DCP(dcp)->opath);
1333 if ((dcp == NULL) || (DCP(dcp)->fd == -1)) {