From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from loongson.cn (loongson.cn [114.242.206.163]) by mx.groups.io with SMTP id smtpd.web11.3298.1672801910577504466 for ; Tue, 03 Jan 2023 19:11:51 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: loongson.cn, ip: 114.242.206.163, mailfrom: lixianglai@loongson.cn) Received: from loongson.cn (unknown [10.2.5.185]) by gateway (Coremail) with SMTP id _____8Cx7+tz7rRj3EoKAA--.22410S3; Wed, 04 Jan 2023 11:11:47 +0800 (CST) Received: from localhost.localdomain (unknown [10.2.5.185]) by localhost.localdomain (Coremail) with SMTP id AQAAf8Bxc+Vz7rRjbXYTAA--.61792S2; Wed, 04 Jan 2023 11:11:47 +0800 (CST) From: "xianglai" To: devel@edk2.groups.io Cc: Bibo Mao , Ard Biesheuvel , Chao Li , Leif Lindholm , Liming Gao , Michael D Kinney Subject: [edk2-platforms][PATCH V1 1/4] Platform/Loongson: add bootmode support. Date: Wed, 4 Jan 2023 11:10:32 +0800 Message-Id: X-Mailer: git-send-email 2.31.1 In-Reply-To: References: MIME-Version: 1.0 X-CM-TRANSID: AQAAf8Bxc+Vz7rRjbXYTAA--.61792S2 X-CM-SenderInfo: 5ol0xt5qjotxo6or00hjvr0hdfq/ X-Coremail-Antispam: 1Uk129KBjvJXoW7Cw4UWFyUKry3CrW3KFyfZwb_yoW8GF43pr 1Duan7tr15Gryqvw15Aa48Gr4UZr90krykJrsxAr13uas8Xw1DXw1qvF40yr17Aa45t3W0 qryIkw15ua1DZrJanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUj1kv1TuYvTs0mT0YCTnIWj qI5I8CrVACY4xI64kE6c02F40Ex7xfYxn0WfASr-VFAUDa7-sFnT9fnUUIcSsGvfJTRUUU b0AFc2x0x2IEx4CE42xK8VAvwI8IcIk0rVWrJVCq3wA2ocxC64kIII0Yj41l84x0c7CEw4 AK67xGY2AK021l84ACjcxK6xIIjxv20xvE14v26r1j6r1xM28EF7xvwVC0I7IYx2IY6xkF 7I0E14v26r1j6r4UM28EF7xvwVC2z280aVAFwI0_Cr0_Gr1UM28EF7xvwVC2z280aVCY1x 0267AKxVW8Jr0_Cr1UM2AIxVAIcxkEcVAq07x20xvEncxIr21l57IF6xkI12xvs2x26I8E 6xACxx1l5I8CrVACY4xI64kE6c02F40Ex7xfMcIj6x8ErcxFaVAv8VWrMcvjeVCFs4IE7x kEbVWUJVW8JwACjcxG0xvY0x0EwIxGrwCF04k20xvY0x0EwIxGrwCF04k20xvE74AGY7Cv 6cx26rWl4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x 8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17CE14v26r126r1DMIIYrxkI7VAKI48JMIIF0xvE 2Ix0cI8IcVAFwI0_Jr0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r1j6r4UMIIF0xvE42 xK8VAvwI8IcIk0rVWUJVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6xkF 7I0E14v26r1j6r4UYxBIdaVFxhVjvjDU0xZFpf9x0zRVWlkUUUUU= Content-Transfer-Encoding: 8bit From: Bibo Mao add bootmode support in PEI phase. Cc: Ard Biesheuvel Cc: Bibo Mao Cc: Chao Li Cc: Leif Lindholm Cc: Liming Gao Cc: Michael D Kinney Signed-off-by: Bibo Mao Signed-off-by: xianglai li --- Platform/Loongson/LoongArchQemuPkg/PlatformPei/Platform.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Platform/Loongson/LoongArchQemuPkg/PlatformPei/Platform.c b/Platform/Loongson/LoongArchQemuPkg/PlatformPei/Platform.c index 32b6518f8f..84bb8e8a6d 100644 --- a/Platform/Loongson/LoongArchQemuPkg/PlatformPei/Platform.c +++ b/Platform/Loongson/LoongArchQemuPkg/PlatformPei/Platform.c @@ -53,6 +53,8 @@ CONST EFI_PEI_PPI_DESCRIPTOR mPpiListBootMode = { NULL }; +STATIC EFI_BOOT_MODE mBootMode = BOOT_WITH_FULL_CONFIGURATION; + /** Create Reserved type memory range hand off block. @@ -417,6 +419,9 @@ InitializePlatform ( DEBUG ((DEBUG_INFO, "Platform PEIM Loaded\n")); + Status = PeiServicesSetBootMode (mBootMode); + ASSERT_EFI_ERROR (Status); + Status = PeiServicesInstallPpi (&mPpiListBootMode); ASSERT_EFI_ERROR (Status); -- 2.31.1