diff options
Diffstat (limited to 'src/soc/intel/jasperlake/fsp_params.c')
-rw-r--r-- | src/soc/intel/jasperlake/fsp_params.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/soc/intel/jasperlake/fsp_params.c b/src/soc/intel/jasperlake/fsp_params.c index d9e8261de7..45162f91f2 100644 --- a/src/soc/intel/jasperlake/fsp_params.c +++ b/src/soc/intel/jasperlake/fsp_params.c @@ -148,6 +148,26 @@ void platform_fsp_silicon_init_params_cb(FSPS_UPD *supd) } } + /* SATA */ + dev = pcidev_path_on_root(PCH_DEVFN_SATA); + if (dev) { + params->SataEnable = dev->enabled; + params->SataMode = config->SataMode; + params->SataSalpSupport = config->SataSalpSupport; + + _Static_assert(ARRAY_SIZE(params->SataPortsEnable) >= + ARRAY_SIZE(config->SataPortsEnable), "copy buffer overflow!"); + memcpy(params->SataPortsEnable, config->SataPortsEnable, + sizeof(params->SataPortsEnable)); + + _Static_assert(ARRAY_SIZE(params->SataPortsDevSlp) >= + ARRAY_SIZE(config->SataPortsDevSlp), "copy buffer overflow!"); + memcpy(params->SataPortsDevSlp, config->SataPortsDevSlp, + sizeof(params->SataPortsDevSlp)); + } else { + params->SataEnable = 0; + } + /* SDCard related configuration */ dev = pcidev_path_on_root(PCH_DEVFN_SDCARD); if (!dev) { |