mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-18 15:30:21 +00:00
Before attaching device set PCIM_CMD_PORTEN in addition to
PCIM_CMD_MEMEN and PCIM_CMD_BUSMASTEREN, becaise some braindead BIOSes (such as one found in my vprmatrix notebook) forget to initialize it properly resulting in attachment failure.
This commit is contained in:
parent
ddc6ffdccf
commit
bb342a3713
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=113467
@ -385,11 +385,11 @@ fxp_attach(device_t dev)
|
||||
s = splimp();
|
||||
|
||||
/*
|
||||
* Enable bus mastering. Enable memory space too, in case
|
||||
* Enable bus mastering. Enable memory/port space too, in case
|
||||
* BIOS/Prom forgot about it.
|
||||
*/
|
||||
val = pci_read_config(dev, PCIR_COMMAND, 2);
|
||||
val |= (PCIM_CMD_MEMEN|PCIM_CMD_BUSMASTEREN);
|
||||
val |= (PCIM_CMD_PORTEN|PCIM_CMD_MEMEN|PCIM_CMD_BUSMASTEREN);
|
||||
pci_write_config(dev, PCIR_COMMAND, val, 2);
|
||||
val = pci_read_config(dev, PCIR_COMMAND, 2);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user