util/ifdtool: add generic `PLATFORM_IFD2` for early SoC development
`PLATFORM_IFD2` macro is more generic tag that can be associated with early next SoC platform development which using IFDv2. The current assumption is that newer SoC platform still uses the same SPI/eSPI frequency definition being used for latest platform(TGL, ADL) and if the frequency definition is updated later, `PLATFORM_IFD2' will use latest frequency definition for early next SoC development. And once upstream is allowed for new platform, platform name will be added in tool later. Signed-off-by: Wonkyu Kim <wonkyu.kim@intel.com> Change-Id: I14a71a58c7d51b9c8b92e013b5637c6b35005f22 Reviewed-on: https://review.coreboot.org/c/coreboot/+/61576 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Subrata Banik <subratabanik@google.com>
This commit is contained in:
parent
80c9289712
commit
3922aa5c2c
|
@ -231,6 +231,7 @@ static enum ich_chipset ifd2_platform_to_chipset(const int pindex)
|
||||||
return CHIPSET_300_SERIES_CANNON_POINT;
|
return CHIPSET_300_SERIES_CANNON_POINT;
|
||||||
case PLATFORM_TGL:
|
case PLATFORM_TGL:
|
||||||
case PLATFORM_ADL:
|
case PLATFORM_ADL:
|
||||||
|
case PLATFORM_IFD2:
|
||||||
return CHIPSET_500_600_SERIES_TIGER_ALDER_POINT;
|
return CHIPSET_500_600_SERIES_TIGER_ALDER_POINT;
|
||||||
case PLATFORM_ICL:
|
case PLATFORM_ICL:
|
||||||
return CHIPSET_400_SERIES_ICE_POINT;
|
return CHIPSET_400_SERIES_ICE_POINT;
|
||||||
|
@ -260,6 +261,7 @@ static int is_platform_ifd_2(void)
|
||||||
PLATFORM_EHL,
|
PLATFORM_EHL,
|
||||||
PLATFORM_ADL,
|
PLATFORM_ADL,
|
||||||
PLATFORM_SKLKBL,
|
PLATFORM_SKLKBL,
|
||||||
|
PLATFORM_IFD2,
|
||||||
};
|
};
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
|
@ -1185,6 +1187,7 @@ static void lock_descriptor(const char *filename, char *image, int size)
|
||||||
case PLATFORM_JSL:
|
case PLATFORM_JSL:
|
||||||
case PLATFORM_EHL:
|
case PLATFORM_EHL:
|
||||||
case PLATFORM_ADL:
|
case PLATFORM_ADL:
|
||||||
|
case PLATFORM_IFD2:
|
||||||
/* CPU/BIOS can read descriptor and BIOS. */
|
/* CPU/BIOS can read descriptor and BIOS. */
|
||||||
fmba->flmstr1 |= (1 << REGION_DESC) << rd_shift;
|
fmba->flmstr1 |= (1 << REGION_DESC) << rd_shift;
|
||||||
fmba->flmstr1 |= (1 << REGION_BIOS) << rd_shift;
|
fmba->flmstr1 |= (1 << REGION_BIOS) << rd_shift;
|
||||||
|
@ -1642,6 +1645,7 @@ static void print_usage(const char *name)
|
||||||
" ehl - Elkhart Lake\n"
|
" ehl - Elkhart Lake\n"
|
||||||
" glk - Gemini Lake\n"
|
" glk - Gemini Lake\n"
|
||||||
" icl - Ice Lake\n"
|
" icl - Ice Lake\n"
|
||||||
|
" ifd2 - IFDv2 Platform\n"
|
||||||
" jsl - Jasper Lake\n"
|
" jsl - Jasper Lake\n"
|
||||||
" sklkbl - Sky Lake/Kaby Lake\n"
|
" sklkbl - Sky Lake/Kaby Lake\n"
|
||||||
" tgl - Tiger Lake\n"
|
" tgl - Tiger Lake\n"
|
||||||
|
@ -1909,6 +1913,8 @@ int main(int argc, char *argv[])
|
||||||
platform = PLATFORM_TGL;
|
platform = PLATFORM_TGL;
|
||||||
} else if (!strcmp(optarg, "adl")) {
|
} else if (!strcmp(optarg, "adl")) {
|
||||||
platform = PLATFORM_ADL;
|
platform = PLATFORM_ADL;
|
||||||
|
} else if (!strcmp(optarg, "ifd2")) {
|
||||||
|
platform = PLATFORM_IFD2;
|
||||||
} else {
|
} else {
|
||||||
fprintf(stderr, "Unknown platform: %s\n", optarg);
|
fprintf(stderr, "Unknown platform: %s\n", optarg);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
|
|
|
@ -58,6 +58,7 @@ enum platform {
|
||||||
PLATFORM_SKLKBL,
|
PLATFORM_SKLKBL,
|
||||||
PLATFORM_TGL,
|
PLATFORM_TGL,
|
||||||
PLATFORM_ADL,
|
PLATFORM_ADL,
|
||||||
|
PLATFORM_IFD2,
|
||||||
};
|
};
|
||||||
|
|
||||||
#define LAYOUT_LINELEN 80
|
#define LAYOUT_LINELEN 80
|
||||||
|
|
Loading…
Reference in New Issue