From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id 239187803CC for ; Mon, 4 Dec 2023 07:06:02 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=orhtQRhqaYqnXLPaRGa74++e4rg86GObb/dxOW7c3JQ=; c=relaxed/simple; d=groups.io; h=ARC-Seal:ARC-Message-Signature:ARC-Authentication-Results:From:To:CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID:References:In-Reply-To:Accept-Language:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Language:Content-Type:Content-Transfer-Encoding; s=20140610; t=1701673561; v=1; b=WdmCySA0Mh2JQiFjXd5C/OKSetTh9tPEsQq32U09A6JVcB4iu13Sw7V1EDfUV0APjqddDxIn y3c5lBqjYOLd1zn6EifE+isRuFnWMIZibzoX1ITjrNMnAXooYaQfVo2IF6lAGsWn3p+eCR0225u 1kdSnybfZ+FoXnSmHG1Lqwh0= X-Received: by 127.0.0.2 with SMTP id DLczYY7687511xmLZw5hrsHW; Sun, 03 Dec 2023 23:06:01 -0800 X-Received: from NAM10-BN7-obe.outbound.protection.outlook.com (NAM10-BN7-obe.outbound.protection.outlook.com [40.107.92.46]) by mx.groups.io with SMTP id smtpd.web11.63520.1701673561201924655 for ; Sun, 03 Dec 2023 23:06:01 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cEVuHSysx96Odv2ivHQGUt8SsghNKwiD2pLVLj884nLApJp/eWBK0u/oX0lxsM5TbODab41MFUQY8d0pFYUlfTgZQH4ZFvXN1PBo+jpOrZ5VJPc7PqhKVeepHrOLBoWt3g3wQ7rn50OX9LqvpTm5a7Q3MfnvRdqil9A5xWkfe6PQ9c2ExIMOBAFDeWTAR9OHQNZC8oFZa+PDDnGEh3Dgs5LlDV8XceB/8bUkVTM5J3MQp902PB638MoTVFSsURpsp50ryYlb14zHU1s/C8h8p9CPe0xMOr9d+5GXSoii67S2Ufs28IL6h143wdbHYq4NTD3gANmy3UtDHexNqOs3kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=+GGYfbW9ywVB+3pfuWga4VhjEV5+1vicw32HeqKXNW8=; b=HaYqlLcV5NI3UY49mzTubdMuOfjb6wBG8DdFmdYdMzzg01glsUf6vYCXox0LcH7tQf/HPVgyHgDp1zZO/vJxuE4SZoKtn/CXz9WmtNG/ml0QzyVECl4KGixybV1YY8KGOEf+WOQYVcRH1Nk4h2ih8shySFmtFsOAbwp0N7cGRYsTAzrh//ZUF/t5uolVHK4Tvd93kP3PnXEMF6dpRAJx6/fMjUtRLFBOeb3k5eVGgt2KjkwgjAEl6dmRJGdwD6YO5zYOmwR/qIVZZa+BxDnFmbtmCobhHq1k8BSG/DhHtyppk2IL3ihBQessL9CXRMNNafoVYMJTkXXmUn5KykNOng== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none X-Received: from MW4PR12MB7031.namprd12.prod.outlook.com (2603:10b6:303:1ef::6) by SA3PR12MB7877.namprd12.prod.outlook.com (2603:10b6:806:31b::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7046.33; Mon, 4 Dec 2023 07:05:57 +0000 X-Received: from MW4PR12MB7031.namprd12.prod.outlook.com ([fe80::a78e:602e:415c:4cb4]) by MW4PR12MB7031.namprd12.prod.outlook.com ([fe80::a78e:602e:415c:4cb4%3]) with mapi id 15.20.7046.033; Mon, 4 Dec 2023 07:05:57 +0000 From: "Nickle Wang via groups.io" To: Mike Maslenkin , "devel@edk2.groups.io" CC: "abner.chang@amd.com" , "igork@ami.com" Subject: Re: [edk2-devel] [PATCH 3/3] RedfishClientPkg: warn user about reboot if allowed. Thread-Topic: [PATCH 3/3] RedfishClientPkg: warn user about reboot if allowed. Thread-Index: AQHaI+OZUd3XrwHA2EiOz2n+QJCBELCYuNUQ Date: Mon, 4 Dec 2023 07:05:57 +0000 Message-ID: References: <20231130231844.22397-1-mike.maslenkin@gmail.com> <20231130231844.22397-4-mike.maslenkin@gmail.com> In-Reply-To: <20231130231844.22397-4-mike.maslenkin@gmail.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-publictraffictype: Email x-ms-traffictypediagnostic: MW4PR12MB7031:EE_|SA3PR12MB7877:EE_ x-ms-office365-filtering-correlation-id: c3e6cd67-c6f9-4fe0-9970-08dbf49776fc x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam-message-info: zgBlI1QYG6kTws8AkJdsHegI060FCMnSjfvstQLFkanA/pLm7Heo7Vq65uftCShsZnyyY9ns+1EAeZF3jZzKqKnrYHcZe7EqvEdzDDxFcO05IinohL87jFLRlNy5/tj5Hodu+Lvc0QxYeMKV49Xe8NvVEHGl2x8Y55DjMWHlOe56nViLRaGA4Isu+lWZ83KOi3pSrQLs+OrldgioM8gbK0L2kSDGFlQmh1HgyoBo+OjiJh6GYEUl4/didcRFr1AvrG5QgUy9bZlTBDCqk6lBp6SQLH4QN2nN+pU74jrDGDkU3p0EJKu/ayjQZ6pzWVXNqMLpQmsQsDNwaSWEHiYT0fDIMljYPHDsfnWPJPB0yMNfxUrGWtQUP2q5HP1ak6LCNP+m+PCus8mx/6hkj8UprgDVwYU3tWOE52iy++xr8HqkV5UtZVFVo/NlMK8T4e8c2k41jkwYp0XNr0BBvJqUZa3z39xQJfFc+slcL3HKR9OUzfbsgLMN3SKlceD8IpnIqKwyxt/3GNVRSvzRu0rzp5dRe6ATZrTfx3lyGqz+8wjky6jdWE6k101lq4MaLcGouSgey9J5rdIFz2RbBrR9tprq0L07Fmy9M28WUC+EUVwUZbbm3V65x0QC+hIiONWctWRUBNphdQe84T0Gl9Y/fx9zW9H4yWwX9BxiI5Ljqjw= x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?1J/gVvNWvCF+3sO5SporHRsyqYW4cT58+jW5J3DmIA4gmhZkB1YCoMuZXrN2?= =?us-ascii?Q?6kKLnqYOJXETgHEGbM8yImRnVzJHwomobOULJba7CTEGMHfArttUG/Wonykx?= =?us-ascii?Q?5NhDN8WMxQYO7bPdA9fGLKobrGqrjH8FhwCsLhy8wUc/szpIwpF6AusfdU4s?= =?us-ascii?Q?ih6OkCghR+Bc+65hdLiBlXpzvK0omqHszOV2AOCEV4pC4ZDEEIl1wwwkxUho?= =?us-ascii?Q?lubO0y7GRCGMc3/Np4wImloQBQ3LX9P0ATASEGZB4cdvQxc0nc16mQew5E1P?= =?us-ascii?Q?SGNLg9F5yvtSpxCpf7A84gU3qGsXkzW6Z5EyfrMSZeE8LcKsalp8BtWtz3BQ?= =?us-ascii?Q?W/SvOtR0JB2Z6ldFBzwxD3mp4SIhL9s8a8T1RURAlekTV8z3eYg62LCB2eDb?= =?us-ascii?Q?jVsvZxLHbw0lbNlD9zLFC+6hVnLPBkM4QAY8N/efgE4k4YkjFKrOcRETw1nf?= =?us-ascii?Q?kSqf1j3o4RmIFsCcQMjAQT9Fw//qPKCpZbFyBuZYoEPnqMbUsTG51JZfdPx1?= =?us-ascii?Q?ZajWrlq1ifl4LPZdzOMdxu3npQpAGOdhSu+09BMFcm5Nbcp87gQii4jsG6qg?= =?us-ascii?Q?UjdVwo4ESZQQyL7SuvT5WyI3Fq7q+tyCQz+Lmm6wNDkUq0cTBRQi7IFarraD?= =?us-ascii?Q?/x26qEndN4Y3SHSHVB08D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ii?Q?ShU9S4vPVN+eGndj+eu/uhBkpU+iBOevfBdrCFd8NDTS9ePDoiugXieBrwSv?= =?us-ascii?Q?UJYr3GArkWjnJOQkZjA2Ah9QJuSzB2hQeiLG4X1VKnFu?= MIME-Version: 1.0 X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MW4PR12MB7031.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: c3e6cd67-c6f9-4fe0-9970-08dbf49776fc X-MS-Exchange-CrossTenant-originalarrivaltime: 04 Dec 2023 07:05:57.6394 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: Syml8QcxRxXj0bisSYef+mUPLIuhRawSdl/FM2ecLa/ECMttZYBxtVoHXVx21XqtqRY1FMe4uB13Qwi5NMLhTA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA3PR12MB7877 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,nicklew@nvidia.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: 21a4FgfKEsXyeJPWYMYM5pySx7686176AA= Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=WdmCySA0; arc=reject ("signature check failed: fail, {[1] = sig:microsoft.com:reject}"); dmarc=none; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io Reviewed-by: Nickle Wang Regards, Nickle > -----Original Message----- > From: Mike Maslenkin > Sent: Friday, December 1, 2023 7:19 AM > To: devel@edk2.groups.io > Cc: abner.chang@amd.com; Nickle Wang ; > igork@ami.com > Subject: [PATCH 3/3] RedfishClientPkg: warn user about reboot if allowed. >=20 > External email: Use caution opening links or attachments >=20 >=20 > Warn user about system reboot only if it has not been rejected by callbac= ks > executed as result of EdkiiRedfishPhaseBeforeReboot notification >=20 > Signed-off-by: Mike Maslenkin > Cc: Abner Chang > Cc: Nickle Wang > Cc: Igor Kulchytskyy > --- > .../RedfishFeatureCoreDxe/RedfishFeatureCoreDxe.c | 10 ++++++---- > 1 file changed, 6 insertions(+), 4 deletions(-) >=20 > diff --git a/RedfishClientPkg/RedfishFeatureCoreDxe/RedfishFeatureCoreDxe= .c > b/RedfishClientPkg/RedfishFeatureCoreDxe/RedfishFeatureCoreDxe.c > index 51d0387ce867..f3188ddfde2c 100644 > --- a/RedfishClientPkg/RedfishFeatureCoreDxe/RedfishFeatureCoreDxe.c > +++ b/RedfishClientPkg/RedfishFeatureCoreDxe/RedfishFeatureCoreDxe.c > @@ -296,9 +296,6 @@ RedfishFeatureDriverStartup ( > // If system configuration is changed, reboot system. > // > if (PcdGetBool (PcdRedfishSystemRebootRequired)) { > - Print (L"System configuration is changed from RESTful interface. Reb= oot > system in %d seconds...\n", RebootTimeout); > - gBS->Stall (RebootTimeout * 1000000U); > - > // > // Call override protocol to notify platform that Redfish is process= ed > // and about to reboot system. > @@ -312,9 +309,14 @@ RedfishFeatureDriverStartup ( > Status =3D RedfishOverride->NotifyPhase (RedfishOverride, > EdkiiRedfishPhaseBeforeReboot); > if (EFI_ERROR (Status)) { > DEBUG ((DEBUG_ERROR, "%a: abort the reboot because NotifyPhase() > returns failure: %r\n", __func__, Status)); > - return; > + PcdSetBoolS (PcdRedfishSystemRebootRequired, FALSE); > } > } > + } > + > + if (PcdGetBool (PcdRedfishSystemRebootRequired)) { > + Print (L"System configuration is changed from RESTful interface. Reb= oot > system in %d seconds...\n", RebootTimeout); > + gBS->Stall (RebootTimeout * 1000000U); >=20 > gRT->ResetSystem (EfiResetCold, EFI_SUCCESS, 0, NULL); > CpuDeadLoop (); > -- > 2.32.0 (Apple Git-132) -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#112006): https://edk2.groups.io/g/devel/message/112006 Mute This Topic: https://groups.io/mt/102905312/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-