mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 12:19:54 +00:00
Kernel/PCI: Add helper to determine if device can access IO space
This commit is contained in:
parent
2cd1f928e1
commit
0669dd82e2
Notes:
sideshowbarker
2024-07-18 22:57:59 +09:00
Author: https://github.com/supercomputer7
Commit: 0669dd82e2
Pull-request: https://github.com/SerenityOS/serenity/pull/6277
Reviewed-by: https://github.com/ElectrodeYT
Reviewed-by: https://github.com/awesomekling
2 changed files with 5 additions and 0 deletions
|
@ -204,6 +204,10 @@ void disable_memory_space(Address address)
|
|||
{
|
||||
write16(address, PCI_COMMAND, read16(address, PCI_COMMAND) & ~(1 << 1));
|
||||
}
|
||||
bool is_io_space_enabled(Address address)
|
||||
{
|
||||
return (read16(address, PCI_COMMAND) & 1) != 0;
|
||||
}
|
||||
|
||||
void enable_interrupt_line(Address address)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue