Lines Matching refs:cgd
325 struct ccb_getdev *cgd; in chasync() local
328 cgd = (struct ccb_getdev *)arg; in chasync()
329 if (cgd == NULL) in chasync()
332 if (cgd->protocol != PROTO_SCSI) in chasync()
334 if (SID_QUAL(&cgd->inq_data) != SID_QUAL_LU_CONNECTED) in chasync()
336 if (SID_TYPE(&cgd->inq_data)!= T_CHANGER) in chasync()
347 chasync, AC_FOUND_DEVICE, cgd); in chasync()
366 struct ccb_getdev *cgd; in chregister() local
371 cgd = (struct ccb_getdev *)arg; in chregister()
372 if (cgd == NULL) { in chregister()
395 if (cgd->inq_data.version <= SCSI_REV_2) in chregister()
408 SID_TYPE(&cgd->inq_data) | in chregister()
1699 struct ccb_getdev *cgd; in chscsiversion() local
1703 if ((cgd = (struct ccb_getdev *)xpt_alloc_ccb_nowait()) == NULL) in chscsiversion()
1708 xpt_gdev_type(cgd, periph->path); in chscsiversion()
1710 if (cgd->ccb_h.status != CAM_REQ_CMP) { in chscsiversion()
1711 xpt_free_ccb((union ccb *)cgd); in chscsiversion()
1715 inq_data = &cgd->inq_data; in chscsiversion()
1717 xpt_free_ccb((union ccb *)cgd); in chscsiversion()