Skip to content

Commit 044acee

Browse files
Michael ChanJames Bottomley
authored andcommitted
[SCSI] edd: Treat "XPRS" host bus type the same as "PCI"
PCI Express devices will return "XPRS" host bus type during BIOS EDD call. "XPRS" should be treated just like "PCI" so that the proper pci_dev symlink will be created. Scripts such as fcoe_edd.sh will then work correctly. Signed-off-by: Michael Chan <mchan@broadcom.com> Reviewed-by: Matt Domsch <Matt_Domsch@dell.com> Signed-off-by: Yi Zou <yi.zou@intel.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
1 parent 7000f7c commit 044acee

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎drivers/firmware/edd.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,15 +151,15 @@ edd_show_host_bus(struct edd_device *edev, char *buf)
151151
p += scnprintf(p, left, "\tbase_address: %x\n",
152152
info->params.interface_path.isa.base_address);
153153
} else if (!strncmp(info->params.host_bus_type, "PCIX", 4) ||
154-
!strncmp(info->params.host_bus_type, "PCI", 3)) {
154+
!strncmp(info->params.host_bus_type, "PCI", 3) ||
155+
!strncmp(info->params.host_bus_type, "XPRS", 4)) {
155156
p += scnprintf(p, left,
156157
"\t%02x:%02x.%d channel: %u\n",
157158
info->params.interface_path.pci.bus,
158159
info->params.interface_path.pci.slot,
159160
info->params.interface_path.pci.function,
160161
info->params.interface_path.pci.channel);
161162
} else if (!strncmp(info->params.host_bus_type, "IBND", 4) ||
162-
!strncmp(info->params.host_bus_type, "XPRS", 4) ||
163163
!strncmp(info->params.host_bus_type, "HTPT", 4)) {
164164
p += scnprintf(p, left,
165165
"\tTBD: %llx\n",
@@ -668,7 +668,7 @@ edd_get_pci_dev(struct edd_device *edev)
668668
{
669669
struct edd_info *info = edd_dev_get_info(edev);
670670

671-
if (edd_dev_is_type(edev, "PCI")) {
671+
if (edd_dev_is_type(edev, "PCI") || edd_dev_is_type(edev, "XPRS")) {
672672
return pci_get_bus_and_slot(info->params.interface_path.pci.bus,
673673
PCI_DEVFN(info->params.interface_path.pci.slot,
674674
info->params.interface_path.pci.

0 commit comments

Comments
 (0)