coreboot/src/drivers
Pranava Y N 4427a34b6b drivers/intel/fsp2_0: Fix string length handling in timestamp printing
The current implementation uses '%*s' which treats the calculated
str_len as a minimum field width. If the underlying string buffer is not
null-terminated, printk will continue reading past the buffer until it
encounters a null byte.

Switch to '%.*s' to correctly use the precision field, which specifies
the maximum number of characters to be printed from the string.

BUG=None
TEST=Able to dump FSP performance data with `DISPLAY_FSP_TIMESTAMPS`
Kconfig selected and meeting the FSP prerequisites. Verify that the
performance data table is printed correctly.

```
[INFO ]  +---------------------------------------------------+
[INFO ]  |------ FSP Performance Timestamp Table Dump -------|
[INFO ]  +---------------------------------------------------+
[INFO ]  | Perf-ID	Timestamp(us)		String/GUID |
[INFO ]  +---------------------------------------------------+
[INFO ]      0	         1242275		SEC/52c05b14-0b98-496c-bc3b04b50211d680
[INFO ]     50	         1242282		PEI/52c05b14-0b98-496c-bc3b04b50211d680
[INFO ]     40	         1242284		PreMem/52c05b14-0b98-496c-bc3b04b50211d680
```

Change-Id: Id95bd34b9c7d45d2c363339eb18adc5ac731c72b
Signed-off-by: Pranava Y N <pranavayn@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/90788
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Jérémy Compostella <jeremy.compostella@intel.com>
2026-01-20 15:50:48 +00:00
..
acpi/thermal_zone tree: Remove unused <string.h> 2024-05-29 10:34:08 +00:00
amd drivers/amd/opensil: Add hooks to populate CBMEM_ID_MEMINFO 2026-01-15 19:57:44 +00:00
ams drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
analogix/anx7625 drivers/analogix/anx7625: Add a retry mechanism to decode EDID 2025-06-07 09:50:32 +00:00
asmedia drivers/asmedia/asm1061: Align = only with tabs and not spaces 2025-02-10 15:14:32 +00:00
aspeed drivers/aspeed/common: Add AST2600 support 2024-09-26 15:09:17 +00:00
broadcom driver/acpi to /driver/gfx: Rename Makefiles from .inc to .mk 2024-01-24 10:03:39 +00:00
camera drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
crb drivers/crb/tpm: Add new method to retrieve base address 2025-07-02 16:15:09 +00:00
efi drivers/efi: Exclude verstage from EFI variable store files 2025-12-02 15:17:44 +00:00
elog elog: Handle elog in later boot phase 2025-06-05 13:36:36 +00:00
emulation/qemu drivers/emulation/qemu: Adjust fw_cfg driver for Arm and RISCV 2025-09-28 18:16:57 +00:00
generic drivers/generic/bayhub: Use boolean for power_saving 2025-07-01 15:07:44 +00:00
genesyslogic drivers/genesyslogic/gl9763e: Mask replay timer timeout of AER 2025-07-17 17:42:41 +00:00
gfx/generic drivers/gfx/generic: Add support for non-VGA devices 2025-12-17 20:24:43 +00:00
hwid_dmi drivers/hwid_dmi: Populate SMBIOS product name from CBFS hwid file 2025-11-23 20:07:54 +00:00
i2c drivers/i2c/tas2563: Add driver for generating device in SSDT 2025-11-12 14:30:33 +00:00
intel drivers/intel/fsp2_0: Fix string length handling in timestamp printing 2026-01-20 15:50:48 +00:00
ipmi drivers/ipmi: add Block Transfer (BT) interface 2025-10-16 12:16:43 +00:00
lenovo sb/intel: Convert set_gpio to gpio_set 2025-07-25 17:05:54 +00:00
maxim driver/intel to /driver/ocp: Rename Makefiles from .inc to .mk 2024-01-24 10:04:10 +00:00
mipi drivers/mipi: Add power-off commands for TM_TL121BVMS07_00C 2026-01-19 06:29:02 +00:00
mrc_cache lib/xxhash: Move to commonlib/bsd 2025-12-20 17:35:33 +00:00
net drivers/net/r8168.c: Add option to program MAC address to ERI registers 2025-04-29 22:17:48 +00:00
nxp/uwb tree: Remove unused <string.h> 2024-05-29 10:34:08 +00:00
ocp drivers/ocp/ewl: Remove space after a cast 2024-10-09 17:27:37 +00:00
option drivers/option/cfr.c: Replace memcpy() to avoid uninitialized object 2025-11-16 18:35:41 +00:00
parade driver/parade to /driver/wwan: Rename Makefiles from .inc to .mk 2024-01-24 10:04:33 +00:00
pc80 drivers/pc80/pc/keyboard.c: Add function to change a command byte bit 2025-01-22 20:45:37 +00:00
pcie drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
ricoh/rce822 drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
secunet/dmi drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
siemens/nc_fpga drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
sil/3114 drivers: Add SPDX license headers to Kconfig files 2024-02-18 01:59:32 +00:00
smbus console/i2c_smbus: Allow to send data w/o register offset 2024-07-11 00:06:22 +00:00
smmstore drivers/smmstore: Use lookup_store() for memory-mapped reads 2026-01-10 21:46:55 +00:00
sof drivers/sof: Add support for tas2563 speaker topology 2025-11-12 14:37:11 +00:00
soundwire drivers/soundwire/cs42l43: Add optional properties for controlling jack and accessory detect 2025-10-18 18:31:16 +00:00
spi drivers/spi: Allow SoC to provide the SPI flash CS index 2026-01-17 23:41:39 +00:00
ti driver/parade to /driver/wwan: Rename Makefiles from .inc to .mk 2024-01-24 10:04:33 +00:00
tpm drivers/tpm: Remove duplicated op 2025-12-08 03:03:36 +00:00
uart {drivers, soc/qualcomm/common}: Add configurable delay for UART bitbang 2025-08-04 16:26:29 +00:00
usb drivers/usb/intel_bluetooth: Correct S-state level for power resource 2025-12-26 15:18:46 +00:00
vpd drivers/vpd: Search VPD info at 0x0 first 2025-11-21 22:16:15 +00:00
wifi/generic drivers/wifi/generic: Fix typo in header guard comment 2025-09-10 21:38:51 +00:00
wwan/fm drivers/wwan/fm: Use _EVT method to enhance GPIO event handling 2026-01-07 16:25:22 +00:00