Patrick Georgi | ac95903 | 2020-05-05 22:49:26 +0200 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-or-later */ |
Jonathan Zhang | 8f89549 | 2020-01-16 11:16:45 -0800 | [diff] [blame] | 2 | |
Jonathan Zhang | 8f89549 | 2020-01-16 11:16:45 -0800 | [diff] [blame] | 3 | #include <console/console.h> |
| 4 | #include <fsp/util.h> |
| 5 | #include <lib.h> |
| 6 | |
| 7 | #define DUMP_UPD(old, new, field) \ |
| 8 | fsp_display_upd_value(#field, sizeof(old->field), old->field, new->field) |
| 9 | |
| 10 | /* Display the UPD parameters for MemoryInit */ |
| 11 | void soc_display_fspm_upd_params( |
| 12 | const FSPM_UPD *fspm_old_upd, |
| 13 | const FSPM_UPD *fspm_new_upd) |
| 14 | { |
| 15 | const FSP_M_CONFIG *new; |
| 16 | const FSP_M_CONFIG *old; |
| 17 | |
| 18 | old = &fspm_old_upd->FspmConfig; |
| 19 | new = &fspm_new_upd->FspmConfig; |
| 20 | |
| 21 | printk(BIOS_DEBUG, "UPD values for MemoryInit:\n"); |
| 22 | |
| 23 | DUMP_UPD(old, new, PcdFspMrcDebugPrintErrorLevel); |
| 24 | DUMP_UPD(old, new, PcdFspKtiDebugPrintErrorLevel); |
| 25 | DUMP_UPD(old, new, PcdHsuartDevice); |
| 26 | |
| 27 | hexdump(fspm_new_upd, sizeof(*fspm_new_upd)); |
| 28 | } |
| 29 | |
| 30 | /* Display the UPD parameters for SiliconInit */ |
| 31 | void soc_display_fsps_upd_params( |
| 32 | const FSPS_UPD *fsps_old_upd, |
| 33 | const FSPS_UPD *fsps_new_upd) |
| 34 | { |
Jonathan Zhang | fe17a7d | 2022-08-08 15:38:54 -0700 | [diff] [blame] | 35 | const FSP_S_CONFIG *new; |
| 36 | const FSP_S_CONFIG *old; |
Jonathan Zhang | 8f89549 | 2020-01-16 11:16:45 -0800 | [diff] [blame] | 37 | |
| 38 | old = &fsps_old_upd->FspsConfig; |
| 39 | new = &fsps_new_upd->FspsConfig; |
| 40 | |
| 41 | printk(BIOS_DEBUG, "UPD values for SiliconInit:\n"); |
| 42 | |
| 43 | DUMP_UPD(old, new, PcdBifurcationPcie0); |
| 44 | DUMP_UPD(old, new, PcdBifurcationPcie1); |
| 45 | DUMP_UPD(old, new, PcdActiveCoreCount); |
| 46 | DUMP_UPD(old, new, PcdCpuMicrocodePatchBase); |
| 47 | DUMP_UPD(old, new, PcdCpuMicrocodePatchSize); |
| 48 | DUMP_UPD(old, new, PcdEnablePcie0); |
| 49 | DUMP_UPD(old, new, PcdEnablePcie1); |
| 50 | DUMP_UPD(old, new, PcdEnableEmmc); |
| 51 | DUMP_UPD(old, new, PcdEnableGbE); |
| 52 | DUMP_UPD(old, new, PcdFiaMuxConfigRequestPtr); |
| 53 | DUMP_UPD(old, new, PcdPcieRootPort0DeEmphasis); |
| 54 | DUMP_UPD(old, new, PcdPcieRootPort1DeEmphasis); |
| 55 | DUMP_UPD(old, new, PcdPcieRootPort2DeEmphasis); |
| 56 | DUMP_UPD(old, new, PcdPcieRootPort3DeEmphasis); |
| 57 | DUMP_UPD(old, new, PcdPcieRootPort4DeEmphasis); |
| 58 | DUMP_UPD(old, new, PcdPcieRootPort5DeEmphasis); |
| 59 | DUMP_UPD(old, new, PcdPcieRootPort6DeEmphasis); |
| 60 | DUMP_UPD(old, new, PcdPcieRootPort7DeEmphasis); |
| 61 | DUMP_UPD(old, new, PcdEMMCDLLConfigPtr); |
| 62 | |
| 63 | hexdump(fsps_new_upd, sizeof(*fsps_new_upd)); |
| 64 | } |