Lines Matching refs:cll
134 static int ciss_filter_physical(struct ciss_softc *sc, struct ciss_lun_report *cll);
1313 struct ciss_lun_report *cll; in ciss_report_luns() local
1321 cll = NULL; in ciss_report_luns()
1328 report_size = sizeof(*cll) + nunits * sizeof(union ciss_device_address); in ciss_report_luns()
1329 if ((cll = malloc(report_size, CISS_MALLOC_CLASS, M_NOWAIT | M_ZERO)) == NULL) { in ciss_report_luns()
1339 cr->cr_data = cll; in ciss_report_luns()
1356 cll->list_size = htonl(report_size - sizeof(*cll)); /* big-endian field */ in ciss_report_luns()
1391 if (error && cll != NULL) { in ciss_report_luns()
1392 free(cll, CISS_MALLOC_CLASS); in ciss_report_luns()
1393 cll = NULL; in ciss_report_luns()
1395 return(cll); in ciss_report_luns()
1404 struct ciss_lun_report *cll; in ciss_init_logical() local
1410 cll = ciss_report_luns(sc, CISS_OPCODE_REPORT_LOGICAL_LUNS, in ciss_init_logical()
1412 if (cll == NULL) { in ciss_init_logical()
1418 ndrives = (ntohl(cll->list_size) / sizeof(union ciss_device_address)); in ciss_init_logical()
1461 bus = CISS_LUN_TO_BUS(cll->lun[i].logical.lun); in ciss_init_logical()
1462 target = CISS_LUN_TO_TARGET(cll->lun[i].logical.lun); in ciss_init_logical()
1465 ld->cl_address = cll->lun[i]; in ciss_init_logical()
1478 if (cll != NULL) in ciss_init_logical()
1479 free(cll, CISS_MALLOC_CLASS); in ciss_init_logical()
1486 struct ciss_lun_report *cll; in ciss_init_physical() local
1495 cll = ciss_report_luns(sc, CISS_OPCODE_REPORT_PHYSICAL_LUNS, in ciss_init_physical()
1497 if (cll == NULL) { in ciss_init_physical()
1502 nphys = (ntohl(cll->list_size) / sizeof(union ciss_device_address)); in ciss_init_physical()
1544 if (cll->lun[i].physical.extra_address == 0) { in ciss_init_physical()
1545 bus = cll->lun[i].physical.bus; in ciss_init_physical()
1548 bus = CISS_EXTRA_BUS2(cll->lun[i].physical.extra_address); in ciss_init_physical()
1565 if (cll->lun[i].physical.extra_address == 0) { in ciss_init_physical()
1566 sc->ciss_controllers[cll->lun[i].physical.bus] = cll->lun[i]; in ciss_init_physical()
1590 ciss_filter_physical(sc, cll); in ciss_init_physical()
1593 if (cll != NULL) in ciss_init_physical()
1594 free(cll, CISS_MALLOC_CLASS); in ciss_init_physical()
1600 ciss_filter_physical(struct ciss_softc *sc, struct ciss_lun_report *cll) in ciss_filter_physical() argument
1606 nphys = (ntohl(cll->list_size) / sizeof(union ciss_device_address)); in ciss_filter_physical()
1608 if (cll->lun[i].physical.extra_address == 0) in ciss_filter_physical()
1623 ea = cll->lun[i].physical.extra_address; in ciss_filter_physical()
1628 (cll->lun[i].physical.mode == CISS_HDR_ADDRESS_MODE_MASK_PERIPHERAL)) in ciss_filter_physical()
1638 sc->ciss_physical[bus][target].cp_address = cll->lun[i]; in ciss_filter_physical()
3916 struct ciss_lun_report *cll; in ciss_notify_rescan_logical() local
3924 cll = ciss_report_luns(sc, CISS_OPCODE_REPORT_LOGICAL_LUNS, in ciss_notify_rescan_logical()
3926 if (cll == NULL) in ciss_notify_rescan_logical()
3929 ndrives = (ntohl(cll->list_size) / sizeof(union ciss_device_address)); in ciss_notify_rescan_logical()
3962 bus = CISS_LUN_TO_BUS(cll->lun[i].logical.lun); in ciss_notify_rescan_logical()
3963 target = CISS_LUN_TO_TARGET(cll->lun[i].logical.lun); in ciss_notify_rescan_logical()
3970 ld->cl_address = cll->lun[i]; in ciss_notify_rescan_logical()
3976 free(cll, CISS_MALLOC_CLASS); in ciss_notify_rescan_logical()
4083 struct ciss_lun_report *cll = NULL; in ciss_notify_hotplug() local
4104 cll = ciss_report_luns(sc, CISS_OPCODE_REPORT_PHYSICAL_LUNS, in ciss_notify_hotplug()
4106 if (cll == NULL) { in ciss_notify_hotplug()
4110 ciss_filter_physical(sc, cll); in ciss_notify_hotplug()
4119 if (cll != NULL) in ciss_notify_hotplug()
4120 free(cll, CISS_MALLOC_CLASS); in ciss_notify_hotplug()