From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (NAM12-DM6-obe.outbound.protection.outlook.com [40.92.22.97]) by mx.groups.io with SMTP id smtpd.web12.382.1596663629753167272 for ; Wed, 05 Aug 2020 14:40:29 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@outlook.com header.s=selector1 header.b=S7EwKR1k; spf=pass (domain: outlook.com, ip: 40.92.22.97, mailfrom: michael.kubacki@outlook.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Pey8+BmEPIiYybenlBHQRD3VxqqTGR1LdgcSxYtA8oFz1hoH122CiHkDh1KTf7ZHoDFdY8FoovlftLf6//TsCnPHRdv8FzbeTWWTc0bkJ7vFymK2tWdrSxYsJ1nf2n67gXgOfkLT8v+iHpTBCxenLOgrz5o4fjN8wBDFL7u4FwLFvgT16/CzJU+V7kIPnwz45tKnVNVjnUUIWgj6ew5bsKuBpA4tb3itoLUGB7EGVLv6OTajhzYcsKsbCbz5WYvk5E0YNDqZVoAWBJsBnaaAXRgziWLUuDGsBF4WwmXHeeYfbp5OLHatdYI/wQWr89LD4H/7HWyVXqUdijxD4aX7BA== 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-SenderADCheck; bh=Rj68pXFl2ULDa08VB7RrYf+V1/IvMOAg9kcd9mytO+0=; b=T2aWSQY95WudPWvPBIDifQH8/orVAXhN8/52zcRte8xZs+eoGxpUygA/8Yueuj7l3c1fTHq5gzDbBQVWb4v1kcRt6O6n12jwPk869SPCcWAeRorYvv9X0nwrBQHPsLZxmN1IUFoT91IIZ5xPfnj6KPL+Pmf/HVx4lw7+lne8SFuIxPONWMVaGUmYJhOTWiBgbf/ONCRvcnKi8pliM/41fvhZjO/YgCTfp/FKZqjADVQrERJXUcaYJiiOogXirscYBD7840FQ3kZG0FINzrQcznz2G41BD1SVlwDhZ12WtYFQTHSbXmqJ/8PJ+3Rlyb5FQcJTddOHMPQdMGgZ1uD5hQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Rj68pXFl2ULDa08VB7RrYf+V1/IvMOAg9kcd9mytO+0=; b=S7EwKR1k/C8uOThTyVsWExuq58nBdPJ3sHC62XkT/H3oT/gzwkhN1ND7qBVYkghDBzhaZnBebjuPL0YkI+xDXHUyG5QwGtLBo3DdAjX044GB2DjR2dXiL99S6Z11pAZikrKOz97sL57mEmgd0P+J67B534/kf5Mx5rnRseJSETGiePZ8xVdfnjsL3RCvHhga2KqDI9CjsXaCnJcduoMD6ZJ7s038LBR8Qr7z1vHG5eo0Pu35B7fLLtzZT3xHoXfwYfuu9bIkZFTJLpFxuF9oZxg4bzf4YchVdhjHvogW2C1fJBoL5ODrZNfbzNF6/LVMVFfgfj5o7glE5+5keM40jQ== Received: from MW2NAM12FT045.eop-nam12.prod.protection.outlook.com (2a01:111:e400:fc65::43) by MW2NAM12HT081.eop-nam12.prod.protection.outlook.com (2a01:111:e400:fc65::373) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3261.10; Wed, 5 Aug 2020 21:40:28 +0000 Received: from MWHPR07MB3440.namprd07.prod.outlook.com (2a01:111:e400:fc65::42) by MW2NAM12FT045.mail.protection.outlook.com (2a01:111:e400:fc65::268) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3261.10 via Frontend Transport; Wed, 5 Aug 2020 21:40:28 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:B7FBE58CF0C1BE9A19928B59C683167ADFDFB3EE565E44A63513CEF059E0238E;UpperCasedChecksum:C4A708535B9119E280228248B1ECD83EDDB64C1EFBC95C62DE90CF55C3340D9C;SizeAsReceived:7816;Count:49 Received: from MWHPR07MB3440.namprd07.prod.outlook.com ([fe80::9856:570e:1735:974e]) by MWHPR07MB3440.namprd07.prod.outlook.com ([fe80::9856:570e:1735:974e%7]) with mapi id 15.20.3239.022; Wed, 5 Aug 2020 21:40:28 +0000 From: "Michael Kubacki" To: devel@edk2.groups.io CC: Liming Gao , Michael D Kinney , Guomin Jiang , Wei6 Xu Subject: [PATCH v2 4/7] FmpDevicePkg/FmpDependencyCheckLib: Return unsatisfied on handle failure Date: Wed, 5 Aug 2020 14:39:41 -0700 Message-ID: X-Mailer: git-send-email 2.27.0.windows.1 In-Reply-To: <20200805213944.1811-1-michael.kubacki@outlook.com> References: <20200805213944.1811-1-michael.kubacki@outlook.com> X-ClientProxiedBy: MWHPR2001CA0014.namprd20.prod.outlook.com (2603:10b6:301:15::24) To MWHPR07MB3440.namprd07.prod.outlook.com (2603:10b6:301:69::28) Return-Path: michael.kubacki@outlook.com X-Microsoft-Original-Message-ID: <20200805213944.1811-5-michael.kubacki@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (2001:4898:80e8:a:f5bb:f844:3092:4e93) by MWHPR2001CA0014.namprd20.prod.outlook.com (2603:10b6:301:15::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3239.17 via Frontend Transport; Wed, 5 Aug 2020 21:40:27 +0000 X-Mailer: git-send-email 2.27.0.windows.1 X-Microsoft-Original-Message-ID: <20200805213944.1811-5-michael.kubacki@outlook.com> X-TMN: [3sPEN+4S8om9vAUqT2Rly2MkRwlBrlVcT96oGvljn2GRqM4fIDVZJ15rVLcG/Thn] X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 49 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: e891587c-d478-4a8d-c7ba-08d839882b59 X-MS-TrafficTypeDiagnostic: MW2NAM12HT081: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: +jiOuMfNvewIMfishcBTbuBQXJcOJyf28zG7Q7SwqKe+J7de2mzR/7C3dWa2R1syN2pATle8JgpZyAXuVhwTPy3Kgk8en69juzI2bsJxqcuxwZVqRHEKR6sPSAyakeY3CI0JG0ys3QPes9QNH+BOzn7x2hZXiNaf3HKzJp408Te2ReBUrwsUPW9Ie//KEqL5kRqk2bfXl19bTFv/87gcww== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:0;SRV:;IPV:NLI;SFV:NSPM;H:MWHPR07MB3440.namprd07.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:;DIR:OUT;SFP:1901; X-MS-Exchange-AntiSpam-MessageData: gz543nxZHJNYJy3E68hLM6AOMSNEyOadjTDLWb/Is36Kmkhcq/lNeHh7jXbxNY/4NUTmbzvRSdUFPEyRAIC9RMYznC3Z0os6UPPsarZ1im2aLSW7JauoO5LvnWKGRPSIqDx272uyjUwKMf7GEmnnSCaUzoc8ewg2xqapS2qeyv5DUe4NQNHut02TwuaPvZxxdo5DlCblydQXbxkPnH9SzQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: e891587c-d478-4a8d-c7ba-08d839882b59 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Aug 2020 21:40:28.0413 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: MW2NAM12FT045.eop-nam12.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW2NAM12HT081 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain From: Michael Kubacki CheckFmpDependency () will currently return that dependencies are satisfied if the initial call in the function to locate handles that have gEfiFirmwareManagementProtocolGuid installed fails. This change updates the error handling to return FALSE (dependencies are not satisfied) if this handle search fails. Cc: Liming Gao Cc: Michael D Kinney Cc: Guomin Jiang Cc: Wei6 Xu Signed-off-by: Michael Kubacki Reviewed-by: Michael D Kinney Reviewed-by: Guomin Jiang Reviewed-by: Wei6 Xu --- FmpDevicePkg/Library/FmpDependencyCheckLib/FmpDependencyCheckLib.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/FmpDevicePkg/Library/FmpDependencyCheckLib/FmpDependencyCheckL= ib.c b/FmpDevicePkg/Library/FmpDependencyCheckLib/FmpDependencyCheckLib.c index 5e0241b25957..02ed600e0e95 100644 --- a/FmpDevicePkg/Library/FmpDependencyCheckLib/FmpDependencyCheckLib.c +++ b/FmpDevicePkg/Library/FmpDependencyCheckLib/FmpDependencyCheckLib.c @@ -2,6 +2,7 @@ Provides FMP capsule dependency check services when updating the firmwar= e image of a FMP device. =20 + Copyright (c) Microsoft Corporation.
Copyright (c) 2020, Intel Corporation. All rights reserved.
=20 SPDX-License-Identifier: BSD-2-Clause-Patent @@ -75,6 +76,7 @@ CheckFmpDependency ( ); if (EFI_ERROR (Status)) { DEBUG ((DEBUG_ERROR, "CheckFmpDependency: Get Firmware Management Prot= ocol failed. (%r)", Status)); + IsSatisfied =3D FALSE; goto cleanup; } =20 --=20 2.27.0.windows.1