1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 12:38:12 +00:00

Kernel: Change get_pci_address() to pci_address() in PCI::Device class

The Serenity Coding Style tends to not accept the word "get" in
methods' names if possible.
This commit is contained in:
Liav A 2020-02-22 23:56:00 +02:00 committed by Andreas Kling
parent d51c81f475
commit a7d7c0e60c
4 changed files with 18 additions and 18 deletions

View file

@ -137,17 +137,17 @@ void RTL8139NetworkAdapter::detect(const PCI::Address& address)
(void)adopt(*new RTL8139NetworkAdapter(address, irq)).leak_ref();
}
RTL8139NetworkAdapter::RTL8139NetworkAdapter(PCI::Address pci_address, u8 irq)
: PCI::Device(pci_address, irq)
RTL8139NetworkAdapter::RTL8139NetworkAdapter(PCI::Address address, u8 irq)
: PCI::Device(address, irq)
{
set_interface_name("rtl8139");
kprintf("RTL8139: Found at PCI address %b:%b:%b\n", get_pci_address().bus(), get_pci_address().slot(), get_pci_address().function());
kprintf("RTL8139: Found at PCI address %b:%b:%b\n", pci_address().bus(), pci_address().slot(), pci_address().function());
enable_bus_mastering(get_pci_address());
enable_bus_mastering(pci_address());
m_io_base = PCI::get_BAR0(get_pci_address()) & ~1;
m_interrupt_line = PCI::get_interrupt_line(get_pci_address());
m_io_base = PCI::get_BAR0(pci_address()) & ~1;
m_interrupt_line = PCI::get_interrupt_line(pci_address());
kprintf("RTL8139: IO port base: %w\n", m_io_base);
kprintf("RTL8139: Interrupt line: %u\n", m_interrupt_line);