mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-21 14:37:50 +00:00
pci_decode: enable all bridges
set I/O port, MMIO, and bus master to enabled for bridges where disabled. issue #4578
This commit is contained in:
parent
e7ba0b7371
commit
7f0c89f378
@ -82,6 +82,18 @@ void Main::parse_pci_function(Bdf bdf,
|
||||
new (heap) Bridge(parent.sub_bridges, bdf,
|
||||
bcfg.secondary_bus_number(),
|
||||
bcfg.subordinate_bus_number());
|
||||
|
||||
/* enable I/O spaces and DMA in bridges if not done already */
|
||||
using Command = Pci::Config::Command;
|
||||
Command::access_t command = bcfg.read<Command>();
|
||||
if (Command::Io_space_enable::get(command) == 0 ||
|
||||
Command::Memory_space_enable::get(command) == 0 ||
|
||||
Command::Bus_master_enable::get(command) == 0) {
|
||||
Command::Io_space_enable::set(command, 1);
|
||||
Command::Memory_space_enable::set(command, 1);
|
||||
Command::Bus_master_enable::set(command, 1);
|
||||
bcfg.write<Command>(command);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user