Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34791 )
Change subject: soc/intel/cannonlake: Speed up postcar loading using intermediate caching ......................................................................
Patch Set 10:
(1 comment)
https://review.coreboot.org/c/coreboot/+/34791/9/src/soc/intel/cannonlake/ro... File src/soc/intel/cannonlake/romstage/romstage.c:
https://review.coreboot.org/c/coreboot/+/34791/9/src/soc/intel/cannonlake/ro... PS9, Line 167: /* Cache the ROM as WP just below 4GiB. */
You ** NEED ** to make the perfomance comparison with TSEG marked WB.
can you please submit that CL to enable TSEG range marked WB and share the savings because its your idea.
Please provide the actual output of cbmem -t (or -T) somewhere. Otherwise the 4 milliseconds you advertise in your commit message is just bogus number.
Move inevitable saving would be if romstage loading ramstage as ramstage is much bigger than postcar without CL when we are running from UC vs running with cached (WP)
Without CL:
localhost ~ # cbmem -t 58 entries total:
0:1st timestamp 12,942 5:start of verified boot 39,867 (26,924) 503:starting to initialize TPM 40,503 (636) 504:finished TPM initialization 78,397 (37,893) 505:starting to verify keyblock/preamble (RSA) 79,753 (1,355) 506:finished verifying keyblock/preamble (RSA) 94,591 (14,838) 507:starting to verify body (load+SHA2+RSA) 94,593 (2) 508:finished loading body (ignore for x86) 218,853 (124,260) 509:finished calculating body hash (SHA2) 237,757 (18,903) 510:finished verifying body signature (RSA) 240,336 (2,578) 511:starting TPM PCR extend 241,700 (1,364) 512:finished TPM PCR extend 257,240 (15,540) 513:starting locking TPM 257,240 (0) 514:finished locking TPM 265,500 (8,259) 6:end of verified boot 273,796 (8,295) 13:starting to load romstage 273,814 (18) 14:finished loading romstage 273,814 (0) 1:start of romstage 273,819 (5) 950:calling FspMemoryInit 276,698 (2,878) 951:returning from FspMemoryInit 301,959 (25,260) 4:end of romstage 308,139 (6,180) 100:start of postcar 309,030 (890) 101:end of postcar 309,030 (0) 8:starting to load ramstage 309,207 (177) 15:starting LZMA decompress (ignore for x86) 309,215 (7) 16:finished LZMA decompress (ignore for x86) 334,927 (25,712) 9:finished loading ramstage 342,141 (7,213) 550:starting to load Chrome OS VPD 342,219 (78) 10:start of ramstage 342,553 (333) 30:device enumeration 393,554 (51,001) 954:calling FspSiliconInit 402,074 (8,520) 955:returning from FspSiliconInit 489,795 (87,720) 40:device configuration 505,392 (15,597) 956:calling FspNotify(AfterPciEnumeration) 539,808 (34,415) 957:returning from FspNotify(AfterPciEnumeration) 540,151 (342) 50:device enable 540,339 (188) 60:device initialization 560,092 (19,752) 70:device setup done 592,849 (32,757) 75:cbmem post 593,397 (548) 80:write tables 593,516 (119) 15:starting LZMA decompress (ignore for x86) 596,352 (2,835) 16:finished LZMA decompress (ignore for x86) 596,611 (259) 85:finalize chips 597,292 (680) 90:load payload 611,144 (13,852) 15:starting LZMA decompress (ignore for x86) 611,431 (286) 16:finished LZMA decompress (ignore for x86) 659,263 (47,831) 958:calling FspNotify(ReadyToBoot) 659,773 (509) 959:returning from FspNotify(ReadyToBoot) 662,956 (3,183) 960:calling FspNotify(EndOfFirmware) 663,051 (95) 961:returning from FspNotify(EndOfFirmware) 663,457 (406) 99:selfboot jump 663,930 (472) 1000:depthcharge start 663,948 (18) 1002:RO vboot init 664,061 (112) 1020:vboot select&load kernel 664,064 (3) 1030:finished EC verification 684,564 (20,499) 1040:finished storage device initialization 685,653 (1,089) 1050:finished reading kernel from disk 692,897 (7,243) 1100:finished vboot kernel verification 831,888 (138,990) 1101:jumping to kernel 834,390 (2,502)
Total Time: 821,421
With CL:
localhost ~ # cbmem -t 58 entries total:
0:1st timestamp 12,006 5:start of verified boot 38,361 (26,355) 503:starting to initialize TPM 38,995 (634) 504:finished TPM initialization 76,816 (37,821) 505:starting to verify keyblock/preamble (RSA) 78,224 (1,407) 506:finished verifying keyblock/preamble (RSA) 92,933 (14,709) 507:starting to verify body (load+SHA2+RSA) 92,935 (2) 508:finished loading body (ignore for x86) 217,221 (124,285) 509:finished calculating body hash (SHA2) 236,124 (18,902) 510:finished verifying body signature (RSA) 238,813 (2,688) 511:starting TPM PCR extend 240,175 (1,361) 512:finished TPM PCR extend 255,745 (15,570) 513:starting locking TPM 255,745 (0) 514:finished locking TPM 264,098 (8,352) 6:end of verified boot 272,439 (8,341) 13:starting to load romstage 272,457 (18) 14:finished loading romstage 272,457 (0) 1:start of romstage 272,463 (5) 950:calling FspMemoryInit 275,352 (2,889) 951:returning from FspMemoryInit 300,751 (25,399) 4:end of romstage 305,902 (5,150) 100:start of postcar 306,792 (889) 101:end of postcar 306,792 (0) 8:starting to load ramstage 306,986 (193) 15:starting LZMA decompress (ignore for x86) 306,988 (2) 16:finished LZMA decompress (ignore for x86) 332,705 (25,717) 9:finished loading ramstage 339,918 (7,213) 550:starting to load Chrome OS VPD 339,996 (78) 10:start of ramstage 340,347 (351) 30:device enumeration 391,132 (50,784) 954:calling FspSiliconInit 399,673 (8,541) 955:returning from FspSiliconInit 488,172 (88,498) 40:device configuration 503,753 (15,580) 956:calling FspNotify(AfterPciEnumeration) 538,170 (34,417) 957:returning from FspNotify(AfterPciEnumeration) 538,478 (307) 50:device enable 538,666 (188) 60:device initialization 558,375 (19,708) 70:device setup done 591,293 (32,918) 75:cbmem post 591,850 (556) 80:write tables 591,969 (119) 15:starting LZMA decompress (ignore for x86) 594,841 (2,871) 16:finished LZMA decompress (ignore for x86) 595,103 (262) 85:finalize chips 595,739 (635) 90:load payload 608,651 (12,911) 15:starting LZMA decompress (ignore for x86) 608,938 (287) 16:finished LZMA decompress (ignore for x86) 656,813 (47,874) 958:calling FspNotify(ReadyToBoot) 657,323 (509) 959:returning from FspNotify(ReadyToBoot) 661,169 (3,846) 960:calling FspNotify(EndOfFirmware) 661,264 (95) 961:returning from FspNotify(EndOfFirmware) 661,671 (406) 99:selfboot jump 662,138 (467) 1000:depthcharge start 662,156 (18) 1002:RO vboot init 662,268 (111) 1020:vboot select&load kernel 662,272 (3) 1030:finished EC verification 682,521 (20,249) 1040:finished storage device initialization 683,607 (1,085) 1050:finished reading kernel from disk 690,722 (7,115) 1100:finished vboot kernel verification 828,339 (137,616) 1101:jumping to kernel 830,838 (2,498)
Total Time: 818,805