mirror of
https://git.FreeBSD.org/src.git
synced 2026-06-02 11:24:32 +00:00
Revert "nvme: Only attach to storage NVMe devices"
This reverts commit 0a19464bf7. It's
incorrect for ahci attachments. Reverting to merge to stable/15
to merge to releng/15.1 for the release.
Sponsored by: Netflix
This commit is contained in:
+1
-1
@@ -651,7 +651,7 @@ struct ccb_pathinq_settings_nvme {
|
|||||||
uint8_t bus;
|
uint8_t bus;
|
||||||
uint8_t slot;
|
uint8_t slot;
|
||||||
uint8_t function;
|
uint8_t function;
|
||||||
uint8_t progif;
|
uint8_t extra;
|
||||||
char dev_name[NVME_DEV_NAME_LEN]; /* nvme controller dev name for this device */
|
char dev_name[NVME_DEV_NAME_LEN]; /* nvme controller dev name for this device */
|
||||||
};
|
};
|
||||||
_Static_assert(sizeof(struct ccb_pathinq_settings_nvme) == 64,
|
_Static_assert(sizeof(struct ccb_pathinq_settings_nvme) == 64,
|
||||||
|
|||||||
@@ -208,7 +208,7 @@ nvme_sim_action(struct cam_sim *sim, union ccb *ccb)
|
|||||||
cpi->xport_specific.nvme.bus = pci_get_bus(dev);
|
cpi->xport_specific.nvme.bus = pci_get_bus(dev);
|
||||||
cpi->xport_specific.nvme.slot = pci_get_slot(dev);
|
cpi->xport_specific.nvme.slot = pci_get_slot(dev);
|
||||||
cpi->xport_specific.nvme.function = pci_get_function(dev);
|
cpi->xport_specific.nvme.function = pci_get_function(dev);
|
||||||
cpi->xport_specific.nvme.progif = pci_get_progif(dev);
|
cpi->xport_specific.nvme.extra = 0;
|
||||||
strlcpy(cpi->xport_specific.nvme.dev_name, device_get_nameunit(dev),
|
strlcpy(cpi->xport_specific.nvme.dev_name, device_get_nameunit(dev),
|
||||||
sizeof(cpi->xport_specific.nvme.dev_name));
|
sizeof(cpi->xport_specific.nvme.dev_name));
|
||||||
cpi->hba_vendor = pci_get_vendor(dev);
|
cpi->hba_vendor = pci_get_vendor(dev);
|
||||||
@@ -314,13 +314,6 @@ nvme_sim_probe(device_t dev)
|
|||||||
{
|
{
|
||||||
if (nvme_use_nvd)
|
if (nvme_use_nvd)
|
||||||
return (ENXIO);
|
return (ENXIO);
|
||||||
/*
|
|
||||||
* Only do storage devices with CAM. NVMHCI 1.0 interfaces are the only
|
|
||||||
* ones that have namespaces with LBA ranges on them.
|
|
||||||
*/
|
|
||||||
if (pci_get_progif(device_get_parent(dev)) !=
|
|
||||||
PCIP_STORAGE_NVM_ENTERPRISE_NVMHCI_1_0)
|
|
||||||
return (ENXIO);
|
|
||||||
|
|
||||||
device_set_desc(dev, "nvme cam");
|
device_set_desc(dev, "nvme cam");
|
||||||
return (BUS_PROBE_DEFAULT);
|
return (BUS_PROBE_DEFAULT);
|
||||||
|
|||||||
Reference in New Issue
Block a user