soc/intel/cmn/fast_spi: Improve debug message for SPI flash windows

This commit improves the debug messages when initializing SPI flash
windows by adding the window type (Fixed Decode or Extended Decode)
to the log output.

This makes it easier to understand which window is being initialized
and can help with debugging issues related to SPI flash access.

w/o this patch:

[INFO ]  MMAP window: SPI flash base=0x1000000, Host base=0xff000000, Size=0x1000000
[INFO ]  MMAP window: SPI flash base=0x900000, Host base=0xf9900000, Size=0x700000

w/ this patch:

[INFO ]  Fixed Decode Window: SPI flash base=0x1000000, Host base=0xff000000, Size=0x1000000
[INFO ]  Extended Decode Window: SPI flash base=0x900000, Host base=0xf9900000, Size=0x700000

Change-Id: I904f70f42fa70ea06e6f49bd44631a8491463207
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84868
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Pranava Y N <pranavayn@google.com>
This commit is contained in:
Subrata Banik 2024-10-25 14:08:39 +05:30
commit 043d9ec693

View file

@ -31,7 +31,10 @@ static void initialize_window(enum window_type type, uintptr_t host_base,
mem_region_device_ro_init(&shadow_devs[type], (void *)host_base, size);
xlate_window_init(&real_dev_windows[type], &shadow_devs[type].rdev,
flash_base, size);
printk(BIOS_INFO, "MMAP window: SPI flash base=0x%lx, Host base=0x%lx, Size=0x%zx\n",
printk(BIOS_INFO, "%s: ",
(type == FIXED_DECODE_WINDOW) ?
"Fixed Decode Window" : "Extended Decode Window");
printk(BIOS_INFO, "SPI flash base=0x%lx, Host base=0x%lx, Size=0x%zx\n",
flash_base, host_base, size);
}