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 6CC2DD80186 for ; Fri, 27 Oct 2023 00:59:27 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=3mkl4hpGTQri+2s+X0mvyIuOOKTOJR57/kmbm1G7p+o=; c=relaxed/simple; d=groups.io; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding; s=20140610; t=1698368366; v=1; b=mmoh6tD6itiOoPFyuSgijOHq7MiYy6H0q3k6igroDe86iMbnbG8Dux1qOhL430eqaoljIXVq JrP5azvlnTtEzLXoVlfXtn+QbAEtQgSN2EP1jsH0yBSD8Gg5DLVb2ljp0enMV84qQCvAj83S+eV 7mQBb77HTgNW2OlnY8cmTiww= X-Received: by 127.0.0.2 with SMTP id MQZaYY7687511xiMwQ78kTCA; Thu, 26 Oct 2023 17:59:26 -0700 X-Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.31]) by mx.groups.io with SMTP id smtpd.web11.87089.1698368365478454309 for ; Thu, 26 Oct 2023 17:59:25 -0700 X-IronPort-AV: E=McAfee;i="6600,9927,10875"; a="451926100" X-IronPort-AV: E=Sophos;i="6.03,255,1694761200"; d="scan'208";a="451926100" X-Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Oct 2023 17:59:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10875"; a="883027044" X-IronPort-AV: E=Sophos;i="6.03,255,1694761200"; d="scan'208";a="883027044" X-Received: from shpfwdbuild003.ccr.corp.intel.com ([10.239.56.82]) by orsmga004.jf.intel.com with ESMTP; 26 Oct 2023 17:59:23 -0700 From: "Xu, Wei6" To: devel@edk2.groups.io Cc: Wei6 Xu , Laszlo Ersek , Ard Biesheuvel , Sami Mujawar , Ray Ni Subject: [edk2-devel] [PATCH v2 0/1] StandaloneMmCore finds drivers in uncompressed inner fv. Date: Fri, 27 Oct 2023 08:59:19 +0800 Message-Id: MIME-Version: 1.0 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,wei6.xu@intel.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: ZOde0n2CE535PADmCKdrDffUx7686176AA= Content-Transfer-Encoding: 8bit X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=mmoh6tD6; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=intel.com (policy=none) V1: This patch is to fix the issue that StandaloneMmCore fails to detect uncompressed inner FV. PR: https://github.com/tianocore/edk2/pull/4943 V2: Based on V1, fix some other issues 1. Add Missing object size checks before casting pointers to header types a. InnerFvHeader = (EFI_FIRMWARE_VOLUME_HEADER *)SectionData; This is introduced in V1, add the size check on SectionDataSize against EFI_FIRMWARE_VOLUME_HEADER b. Section = (EFI_COMMON_SECTION_HEADER *)(FileHeader + 1); Use FfsFindSection instead of FfsFindSectionData to avoid pointer casting. 2. Fix potential memory leak issue that ScratchBuffer is not freed when page allocation for DstBuffer fails. PR: https://github.com/tianocore/edk2/pull/4965 Cc: Laszlo Ersek Cc: Ard Biesheuvel Cc: Sami Mujawar Cc: Ray Ni Wei6 Xu (1): StandaloneMmPkg: Fix some issues in function MmCoreFfsFindMmDriver. StandaloneMmPkg/Core/FwVol.c | 34 ++++++++++++++++++++++++++-------- 1 file changed, 26 insertions(+), 8 deletions(-) -- 2.29.2.windows.2 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#110160): https://edk2.groups.io/g/devel/message/110160 Mute This Topic: https://groups.io/mt/102212657/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-