MCPcopy Create free account
hub / github.com/coreboot/coreboot / dump_fd

Function dump_fd

util/ifdtool/ifdtool.c:1019–1083  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1017}
1018
1019static void dump_fd(char *image, int size)
1020{
1021 const struct fdbar *fdb = find_fd(image, size);
1022 if (!fdb)
1023 exit(EXIT_FAILURE);
1024
1025 printf("%s", is_platform_with_pch() ? "PCH" : "ICH");
1026 printf(" Revision: %s\n", ich_chipset_names[chipset]);
1027 printf("FLMAP0: 0x%08x\n", fdb->flmap0);
1028 if (!is_platform_with_100x_series_pch())
1029 printf(" NR: %d\n", (fdb->flmap0 >> 24) & 7);
1030 printf(" FRBA: 0x%x\n", ((fdb->flmap0 >> 16) & 0xff) << 4);
1031 printf(" NC: %d\n", ((fdb->flmap0 >> 8) & 3) + 1);
1032 printf(" FCBA: 0x%x\n", ((fdb->flmap0) & 0xff) << 4);
1033
1034 printf("FLMAP1: 0x%08x\n", fdb->flmap1);
1035 printf(" %s: ", is_platform_with_100x_series_pch() ? "PSL" : "ISL");
1036 printf("0x%02x\n", (fdb->flmap1 >> 24) & 0xff);
1037 printf(" FPSBA: 0x%x\n", ((fdb->flmap1 >> 16) & 0xff) << 4);
1038 printf(" NM: %d\n", (fdb->flmap1 >> 8) & 3);
1039 printf(" FMBA: 0x%x\n", ((fdb->flmap1) & 0xff) << 4);
1040
1041 if (!is_platform_with_100x_series_pch()) {
1042 printf("FLMAP2: 0x%08x\n", fdb->flmap2);
1043 printf(" MSL: 0x%04x\n", (fdb->flmap2 >> 8) & 0xffff);
1044 printf(" FMSBA: 0x%x\n", ((fdb->flmap2) & 0xff) << 4);
1045 }
1046
1047 if (chipset == CHIPSET_500_600_SERIES_TIGER_ALDER_POINT ||
1048 chipset == CHIPSET_800_SERIES_METEOR_LAKE ||
1049 chipset == CHIPSET_900_SERIES_PANTHER_LAKE ||
1050 chipset == CHIPSET_900_SERIES_NOVA_LAKE) {
1051 printf("FLMAP3: 0x%08x\n", fdb->flmap3);
1052 printf(" Minor Revision ID: 0x%04x\n", (fdb->flmap3 >> 14) & 0x7f);
1053 printf(" Major Revision ID: 0x%04x\n", (fdb->flmap3 >> 21) & 0x7ff);
1054 }
1055
1056 char *flumap = find_flumap(image, size);
1057 uint32_t flumap1 = *(uint32_t *)flumap;
1058 printf("FLUMAP1: 0x%08x\n", flumap1);
1059 printf(" Intel ME VSCC Table Length (VTL): %d\n",
1060 (flumap1 >> 8) & 0xff);
1061 printf(" Intel ME VSCC Table Base Address (VTBA): 0x%06x\n\n",
1062 (flumap1 & 0xff) << 4);
1063 dump_vtba((struct vtba *)
1064 (image + ((flumap1 & 0xff) << 4)),
1065 (flumap1 >> 8) & 0xff);
1066 dump_oem((const uint8_t *)image + 0xf00);
1067
1068 const struct frba *frba = find_frba(image, size);
1069 const struct fcba *fcba = find_fcba(image, size);
1070 const struct fpsba *fpsba = find_fpsba(image, size);
1071 const struct fmba *fmba = find_fmba(image, size);
1072 const struct fmsba *fmsba = find_fmsba(image, size);
1073
1074 if (frba && fcba && fpsba && fmba && fmsba) {
1075 dump_frba(frba);
1076 dump_fcba(fcba, fpsba);

Callers 1

mainFunction · 0.85

Calls 15

find_fdFunction · 0.85
exitFunction · 0.85
printfFunction · 0.85
is_platform_with_pchFunction · 0.85
find_flumapFunction · 0.85
dump_vtbaFunction · 0.85
dump_oemFunction · 0.85
find_frbaFunction · 0.85
find_fcbaFunction · 0.85
find_fpsbaFunction · 0.85
find_fmbaFunction · 0.85

Tested by

no test coverage detected