From 5dd4a2a4b081caa1c7b2e871067a0ac1b9bff7ed Mon Sep 17 00:00:00 2001 From: Martin Roth Date: Tue, 6 Mar 2018 16:10:45 -0700 Subject: timestamps: Add timestamps around the vbios load & init Add timestamps before and after the vBIOS load and after the vBIOS run. This lets us see exactly how long it took to load it from the ROM chip, and how long it takes to run. BUG=b:64549506 TEST=Build & boot Grunt, see vBIOS load & initialization times. Change-Id: I878ba653eb086ad6c6614aa08a6d3fe216a9323e Signed-off-by: Martin Roth Reviewed-on: https://review.coreboot.org/25018 Reviewed-by: Aaron Durbin Reviewed-by: Paul Menzel Reviewed-by: Marshall Dawson Tested-by: build bot (Jenkins) --- src/device/pci_device.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/device/pci_device.c') diff --git a/src/device/pci_device.c b/src/device/pci_device.c index 02eca66e27..c18f529fbe 100644 --- a/src/device/pci_device.c +++ b/src/device/pci_device.c @@ -48,6 +48,7 @@ #include #include #include +#include u8 pci_moving_config8(struct device *dev, unsigned int reg) { @@ -719,6 +720,7 @@ void pci_dev_init(struct device *dev) if (!should_load_oprom(dev)) return; + timestamp_add_now(TS_OPROM_INITIALIZE); rom = pci_rom_probe(dev); if (rom == NULL) @@ -727,6 +729,7 @@ void pci_dev_init(struct device *dev) ram = pci_rom_load(dev, rom); if (ram == NULL) return; + timestamp_add_now(TS_OPROM_COPY_END); if (!should_run_oprom(dev)) return; @@ -734,6 +737,7 @@ void pci_dev_init(struct device *dev) run_bios(dev, (unsigned long)ram); gfx_set_init_done(1); printk(BIOS_DEBUG, "VGA Option ROM was run\n"); + timestamp_add_now(TS_OPROM_END); } /** Default device operation for PCI devices */ -- cgit v1.2.3