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 2A0A1AC0F4D for ; Fri, 22 Mar 2024 09:43:53 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=rC5jw/Yajfwfzhml8X1XxKWe8np1vWQTixM1FMdU/KM=; c=relaxed/simple; d=groups.io; h=Received-SPF:From:To:CC:Subject:Date:Message-ID:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding:Content-Type; s=20240206; t=1711100631; v=1; b=Fw6GAyXk3V0EJ5TVLItMjGwZ2QvQ2RYDve8eTzb2ooz4rBWrJiKkUIqMNAFMnuMA2AcTfrql bnMhTdMEtXx/wNGsYM1gwJCiZJ07sH/xT/bj7hQPHLhxHF5IX/CLNatMyLfP8yjuheEFbw6H53B p4Pxa2W0e7ffCNTe3LVYuCJmuS7MaH0bBza7mkawzuOfWpS3PnTdSJsj3piS+GtphXDND3zDEqY HDPsgYyndIFYg/ihFBWnIoBH5IJ1Ly5slreB0Ezl6A6Y8/yXroiiCZbsOJk0u7ii4bi4pmN7FuL Ooe+zade48h6zCv688gUvWVFA72LNgS3LF4M44sI0hPJA== X-Received: by 127.0.0.2 with SMTP id RK54YY7687511xmh9QCJ0HeH; Fri, 22 Mar 2024 02:43:51 -0700 X-Received: from NAM12-BN8-obe.outbound.protection.outlook.com (NAM12-BN8-obe.outbound.protection.outlook.com [40.107.237.76]) by mx.groups.io with SMTP id smtpd.web11.9143.1711100629255584144 for ; Fri, 22 Mar 2024 02:43:49 -0700 X-Received: from PH8PR07CA0002.namprd07.prod.outlook.com (2603:10b6:510:2cd::9) by SN7PR12MB7132.namprd12.prod.outlook.com (2603:10b6:806:2a4::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7386.36; Fri, 22 Mar 2024 09:43:47 +0000 X-Received: from CY4PEPF0000FCC1.namprd03.prod.outlook.com (2603:10b6:510:2cd:cafe::da) by PH8PR07CA0002.outlook.office365.com (2603:10b6:510:2cd::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7386.28 via Frontend Transport; Fri, 22 Mar 2024 09:43:47 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C X-Received: from SATLEXMB04.amd.com (165.204.84.17) by CY4PEPF0000FCC1.mail.protection.outlook.com (10.167.242.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.7409.10 via Frontend Transport; Fri, 22 Mar 2024 09:43:46 +0000 X-Received: from TPE-L1-ABNCHANG.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Fri, 22 Mar 2024 04:43:44 -0500 From: "Chang, Abner via groups.io" To: CC: Nickle Wang , Igor Kulchytskyy Subject: [edk2-devel] [PATCH 4/5] RedfishPkg/RedfishPlatformConfigDxe: HII string is deleted unexpectedly Date: Fri, 22 Mar 2024 17:43:12 +0800 Message-ID: <20240322094313.79-5-abner.chang@amd.com> In-Reply-To: <20240322094313.79-1-abner.chang@amd.com> References: <20240322094313.79-1-abner.chang@amd.com> MIME-Version: 1.0 X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CY4PEPF0000FCC1:EE_|SN7PR12MB7132:EE_ X-MS-Office365-Filtering-Correlation-Id: 29406ff8-6a91-4019-aeaa-08dc4a549241 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Message-Info: Ul0dy9BdX8JEnsK2GZaMWBruii+0BxtO2uMxlxzFNfQpOBSf0OZte/8DqYYrK+0Kh9DlIF4/D7yxU4w+oSAldT1KVXaABunfpGTetGphmGCY8X2sXOFHUoVrgJGinVveLD1so3Uix/C7g3IK4c770OtinTPMqkhuVi+Ks2NuDuYj5rov9y+OcOkHYKJKzmJX5uQ7zML5l8vjhGnX14V07e2AFz0IJqky1Pfh5gaFKJOsld22uf6HgUIlR6qAGDPIDTLDPUKykEM577+3vw7xpAILgtcBJTqkXxCchwZj5K4z122KV0ubHmpIq3WPLwwn6acsnC4yKkYcbcXJmf0SCQ/DU7kANKOePEPVlPQ91xHiobMq/oFxisOTNIZd/ARJPWubZzI6DjkZb/Hs6TnPnS9Eh6qy7C7luyq69ZcN7W4DbQqwVdwvwGAWWZW797TrwA9YA2i3+yeY3ZgIz3jtxM4chjDJn93Nf0PjRd9par1otR7TChveB09Ol036esq4JjxVIXcg+H5gN+pVDkr9F3mGzTc1xe2mQqvZlak8KuG8GgonbGFmntBsD64BAvQM+/UwNFenISLQyf8aYTrCLRKh2i+E0T5ZoWhFwfJ/zr9eIbWBoNmu3prr4+hVoCdxpMkUufBJiMQXkb6IhNox9/9klbyks8HXodDdP5LUlKGQl+bIynO9V+gdSaetUTumgjLkIXVjryms6Z50o1mVzMZoppkvtSLstjAw/o1InKSFrInaJ4L0+sN5FU5s4l4n X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Mar 2024 09:43:46.8285 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 29406ff8-6a91-4019-aeaa-08dc4a549241 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CY4PEPF0000FCC1.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7132 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 Resent-Date: Fri, 22 Mar 2024 02:43:49 -0700 Reply-To: devel@edk2.groups.io,abner.chang@amd.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: eiLrtJHljiq6UBKKid4eoCw5x7686176AA= Content-Transfer-Encoding: quoted-printable Content-Type: text/plain X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b=Fw6GAyXk; dmarc=pass (policy=none) header.from=groups.io; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io From: Abner Chang Add the condition check when delete HII string. Only when the HiiStatement operand equal to "EFI_IFR_STRING_OP" and the statement value type =3D EFI_IFR_TYPE_STRING. Signed-off-by: Abner Chang Co-authored-by: Nickle Wang Cc: Igor Kulchytskyy --- .../RedfishPlatformConfigDxe/RedfishPlatformConfigDxe.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/RedfishPkg/RedfishPlatformConfigDxe/RedfishPlatformConfigDxe.c= b/RedfishPkg/RedfishPlatformConfigDxe/RedfishPlatformConfigDxe.c index 8a02c839035..d165799f9a1 100644 --- a/RedfishPkg/RedfishPlatformConfigDxe/RedfishPlatformConfigDxe.c +++ b/RedfishPkg/RedfishPlatformConfigDxe/RedfishPlatformConfigDxe.c @@ -1873,8 +1873,11 @@ RedfishPlatformConfigSetStatementCommon ( DEBUG ((DEBUG_ERROR, "%a: failed to save question value: %r\n", __func= __, Status)); } =20 - if (StatementValue->Value.string !=3D 0) { - HiiDeleteString (StatementValue->Value.string, TargetStatement->Parent= Form->ParentFormset->HiiHandle); + if ((TargetStatement->HiiStatement->Operand =3D=3D EFI_IFR_STRING_OP) &&= (StatementValue->Type =3D=3D EFI_IFR_TYPE_STRING)) { + if (StatementValue->Value.string !=3D 0) { + // Delete HII string which was created for HII statement operand =3D= EFI_IFR_STRING_OP and Type =3D EFI_IFR_TYPE_STRING. + HiiDeleteString (StatementValue->Value.string, TargetStatement->Pare= ntForm->ParentFormset->HiiHandle); + } } =20 return Status; --=20 2.37.1.windows.1 -=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 (#117040): https://edk2.groups.io/g/devel/message/117040 Mute This Topic: https://groups.io/mt/105082178/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-