mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-11 02:13:56 +09:00
Everywhere: Replace a bundle of dbg with dbgln.
These changes are arbitrarily divided into multiple commits to make it easier to find potentially introduced bugs with git bisect.
This commit is contained in:
parent
019c9eb749
commit
4e8fd0216b
Notes:
sideshowbarker
2024-07-18 23:59:10 +09:00
Author: https://github.com/asynts
Commit: 4e8fd0216b
Pull-request: https://github.com/SerenityOS/serenity/pull/4870
7 changed files with 51 additions and 13 deletions
|
@ -57,7 +57,7 @@ void MultiProcessorParser::parse_floating_pointer_data()
|
|||
{
|
||||
auto floating_pointer = map_typed<MultiProcessor::FloatingPointer>(m_floating_pointer);
|
||||
m_configuration_table = PhysicalAddress(floating_pointer->physical_address_ptr);
|
||||
dbg() << "Features " << floating_pointer->feature_info[0] << ", IMCR? " << (floating_pointer->feature_info[0] & (1 << 7));
|
||||
dbgln("Features {}, IMCR? {}", floating_pointer->feature_info[0], (floating_pointer->feature_info[0] & (1 << 7)));
|
||||
}
|
||||
|
||||
void MultiProcessorParser::parse_configuration_table()
|
||||
|
@ -126,7 +126,7 @@ Vector<u8> MultiProcessorParser::get_pci_bus_ids() const
|
|||
|
||||
Vector<PCIInterruptOverrideMetadata> MultiProcessorParser::get_pci_interrupt_redirections()
|
||||
{
|
||||
dbg() << "MultiProcessor: Get PCI IOAPIC redirections";
|
||||
dbgln("MultiProcessor: Get PCI IOAPIC redirections");
|
||||
Vector<PCIInterruptOverrideMetadata> overrides;
|
||||
auto pci_bus_ids = get_pci_bus_ids();
|
||||
for (auto& entry : m_io_interrupt_assignment_entries) {
|
||||
|
|
|
@ -150,15 +150,15 @@ void Parser::access_generic_address(const Structures::GenericAddressStructure& s
|
|||
switch ((GenericAddressStructure::AddressSpace)structure.address_space) {
|
||||
case GenericAddressStructure::AddressSpace::SystemIO: {
|
||||
IOAddress address(structure.address);
|
||||
dbg() << "ACPI: Sending value 0x" << String::format("%x", value) << " to " << address;
|
||||
dbgln("ACPI: Sending value {:x} to {:p}", value, address);
|
||||
switch (structure.access_size) {
|
||||
case (u8)GenericAddressStructure::AccessSize::QWord: {
|
||||
dbg() << "Trying to send QWord to IO port";
|
||||
dbgln("Trying to send QWord to IO port");
|
||||
ASSERT_NOT_REACHED();
|
||||
break;
|
||||
}
|
||||
case (u8)GenericAddressStructure::AccessSize::Undefined: {
|
||||
dbg() << "ACPI Warning: Unknown access size " << structure.access_size;
|
||||
dbgln("ACPI Warning: Unknown access size {}", structure.access_size);
|
||||
ASSERT(structure.bit_width != (u8)GenericAddressStructure::BitWidth::QWord);
|
||||
ASSERT(structure.bit_width != (u8)GenericAddressStructure::BitWidth::Undefined);
|
||||
dbg() << "ACPI: Bit Width - " << structure.bit_width << " bits";
|
||||
|
@ -172,7 +172,7 @@ void Parser::access_generic_address(const Structures::GenericAddressStructure& s
|
|||
return;
|
||||
}
|
||||
case GenericAddressStructure::AddressSpace::SystemMemory: {
|
||||
dbg() << "ACPI: Sending value 0x" << String::format("%x", value) << " to " << PhysicalAddress(structure.address);
|
||||
dbgln("ACPI: Sending value {:x} to {}", value, PhysicalAddress(structure.address));
|
||||
switch ((GenericAddressStructure::AccessSize)structure.access_size) {
|
||||
case GenericAddressStructure::AccessSize::Byte:
|
||||
*map_typed<u8>(PhysicalAddress(structure.address)) = value;
|
||||
|
@ -195,10 +195,10 @@ void Parser::access_generic_address(const Structures::GenericAddressStructure& s
|
|||
case GenericAddressStructure::AddressSpace::PCIConfigurationSpace: {
|
||||
// According to the ACPI specification 6.2, page 168, PCI addresses must be confined to devices on Segment group 0, bus 0.
|
||||
auto pci_address = PCI::Address(0, 0, ((structure.address >> 24) & 0xFF), ((structure.address >> 16) & 0xFF));
|
||||
dbg() << "ACPI: Sending value 0x" << String::format("%x", value) << " to " << pci_address;
|
||||
dbgln("ACPI: Sending value {:x} to {}", value, pci_address);
|
||||
u32 offset_in_pci_address = structure.address & 0xFFFF;
|
||||
if (structure.access_size == (u8)GenericAddressStructure::AccessSize::QWord) {
|
||||
dbg() << "Trying to send QWord to PCI configuration space";
|
||||
dbgln("Trying to send QWord to PCI configuration space");
|
||||
ASSERT_NOT_REACHED();
|
||||
}
|
||||
ASSERT(structure.access_size != (u8)GenericAddressStructure::AccessSize::Undefined);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue