When parsing the CIS, if a BAR tuple is encountered, enable the corresponding

bit in the PCI command register for the device.  Otherwise, device drivers
that look at this register to see which types of BARs are usable will think
that none of them are.
This allows my Adaptec 1480A cardbus card to finally work.

Reviewed by:	imp
This commit is contained in:
Scott Long 2002-11-13 22:53:48 +00:00
parent fcfc20c88a
commit 9fb92b64ad
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=106881

View file

@ -307,6 +307,11 @@ DECODE_PROTOTYPE(bar)
resource_list_add(&dinfo->pci.resources, type, bar, 0UL, ~0UL, len);
/*
* Mark the appropriate bit in the PCI command register so that
* device drivers will know which BARs can be used.
*/
pci_enable_io(child, type);
return (0);
}