soc/amd/sabrina/fsp_m_params: don't hard-code USB PHY config table size
Use sizeof instead of having a hard-coded struct length. Signed-off-by: Felix Held <felix-coreboot@felixheld.de> Change-Id: I3c39d770a7719e30572e71b6a6c24fa2ad4a9426 Reviewed-on: https://review.coreboot.org/c/coreboot/+/64127 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Raul Rangel <rrangel@chromium.org>
This commit is contained in:
parent
3dc89c5bd7
commit
68aaa8cc26
|
@ -13,6 +13,7 @@
|
|||
#include <soc/pci_devs.h>
|
||||
#include <string.h>
|
||||
#include <types.h>
|
||||
#include <vendorcode/amd/fsp/sabrina/FspUsb.h>
|
||||
#include "chip.h"
|
||||
|
||||
__weak void mb_pre_fspm(void)
|
||||
|
@ -145,7 +146,7 @@ void platform_fsp_memory_init_params_cb(FSPM_UPD *mupd, uint32_t version)
|
|||
mcfg->usb_phy = (struct usb_phy_config *)&config->usb_phy;
|
||||
mcfg->usb_phy->Version_Major = 0xd;
|
||||
mcfg->usb_phy->Version_Minor = 0x6;
|
||||
mcfg->usb_phy->TableLength = 100;
|
||||
mcfg->usb_phy->TableLength = sizeof(struct usb_phy_config);
|
||||
} else {
|
||||
mcfg->usb_phy = NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue