Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c
Show First 20 Lines • Show All 260 Lines • ▼ Show 20 Lines | |||||
/* {32412632-86cb-44a2-9b5c-50d1417354f5} */ | /* {32412632-86cb-44a2-9b5c-50d1417354f5} */ | ||||
static const struct hyperv_guid gBlkVscDeviceType={ | static const struct hyperv_guid gBlkVscDeviceType={ | ||||
.hv_guid = {0x32, 0x26, 0x41, 0x32, 0xcb, 0x86, 0xa2, 0x44, | .hv_guid = {0x32, 0x26, 0x41, 0x32, 0xcb, 0x86, 0xa2, 0x44, | ||||
0x9b, 0x5c, 0x50, 0xd1, 0x41, 0x73, 0x54, 0xf5} | 0x9b, 0x5c, 0x50, 0xd1, 0x41, 0x73, 0x54, 0xf5} | ||||
}; | }; | ||||
static struct storvsc_driver_props g_drv_props_table[] = { | static struct storvsc_driver_props g_drv_props_table[] = { | ||||
{"blkvsc", "Hyper-V IDE Storage Interface", | {"blkvsc", "Hyper-V IDE", | ||||
BLKVSC_MAX_IDE_DISKS_PER_TARGET, BLKVSC_MAX_IO_REQUESTS, | BLKVSC_MAX_IDE_DISKS_PER_TARGET, BLKVSC_MAX_IO_REQUESTS, | ||||
20*PAGE_SIZE}, | 20*PAGE_SIZE}, | ||||
{"storvsc", "Hyper-V SCSI Storage Interface", | {"storvsc", "Hyper-V SCSI", | ||||
STORVSC_MAX_LUNS_PER_TARGET, STORVSC_MAX_IO_REQUESTS, | STORVSC_MAX_LUNS_PER_TARGET, STORVSC_MAX_IO_REQUESTS, | ||||
20*PAGE_SIZE} | 20*PAGE_SIZE} | ||||
}; | }; | ||||
/* | /* | ||||
* Sense buffer size changed in win8; have a run-time | * Sense buffer size changed in win8; have a run-time | ||||
* variable to track the size we should use. | * variable to track the size we should use. | ||||
*/ | */ | ||||
▲ Show 20 Lines • Show All 1,165 Lines • ▼ Show 20 Lines | case XPT_PATH_INQ: { | ||||
cpi->max_lun = sc->hs_drv_props->drv_max_luns_per_target; | cpi->max_lun = sc->hs_drv_props->drv_max_luns_per_target; | ||||
cpi->initiator_id = cpi->max_target; | cpi->initiator_id = cpi->max_target; | ||||
cpi->bus_id = cam_sim_bus(sim); | cpi->bus_id = cam_sim_bus(sim); | ||||
cpi->base_transfer_speed = 300000; | cpi->base_transfer_speed = 300000; | ||||
cpi->transport = XPORT_SAS; | cpi->transport = XPORT_SAS; | ||||
cpi->transport_version = 0; | cpi->transport_version = 0; | ||||
cpi->protocol = PROTO_SCSI; | cpi->protocol = PROTO_SCSI; | ||||
cpi->protocol_version = SCSI_REV_SPC2; | cpi->protocol_version = SCSI_REV_SPC2; | ||||
strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); | strlcpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); | ||||
strncpy(cpi->hba_vid, sc->hs_drv_props->drv_name, HBA_IDLEN); | strlcpy(cpi->hba_vid, sc->hs_drv_props->drv_name, HBA_IDLEN); | ||||
strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); | strlcpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); | ||||
cpi->unit_number = cam_sim_unit(sim); | cpi->unit_number = cam_sim_unit(sim); | ||||
ccb->ccb_h.status = CAM_REQ_CMP; | ccb->ccb_h.status = CAM_REQ_CMP; | ||||
xpt_done(ccb); | xpt_done(ccb); | ||||
return; | return; | ||||
} | } | ||||
case XPT_GET_TRAN_SETTINGS: { | case XPT_GET_TRAN_SETTINGS: { | ||||
struct ccb_trans_settings *cts = &ccb->cts; | struct ccb_trans_settings *cts = &ccb->cts; | ||||
▲ Show 20 Lines • Show All 909 Lines • Show Last 20 Lines |