From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id BF0AA81DAD for ; Mon, 7 Nov 2016 18:26:21 -0800 (PST) Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga104.jf.intel.com with ESMTP; 07 Nov 2016 18:26:24 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,608,1473145200"; d="scan'208";a="28632259" Received: from ray-dev.ccr.corp.intel.com ([10.239.9.25]) by fmsmga005.fm.intel.com with ESMTP; 07 Nov 2016 18:26:23 -0800 From: Ruiyu Ni To: edk2-devel@lists.01.org Cc: Jeff Fan Date: Tue, 8 Nov 2016 10:26:21 +0800 Message-Id: <20161108022621.23500-1-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.9.0.windows.1 Subject: [PATCH] IntelFrameworkModulePkg/LegacyBios: Fix legacy serial redirection bug X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Nov 2016 02:26:21 -0000 Upon booting to a legacy OS, LegacyBios driver is responsible to initialize the BDA region with the correct COM port base address. But the current logic to get the COM port base address from IsaIo instance is not correct. The patch fixes this bug. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni Cc: Jeff Fan --- IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacySio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacySio.c b/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacySio.c index c853377..686a32d 100644 --- a/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacySio.c +++ b/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacySio.c @@ -354,7 +354,7 @@ LegacyBiosBuildSioDataFromIsaIo ( // for (ChildIndex = 0; ChildIndex < EntryCount; ChildIndex++) { if ((OpenInfoBuffer[ChildIndex].Attributes & EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER) != 0) { - Status = gBS->HandleProtocol (OpenInfoBuffer[ChildIndex].AgentHandle, &gEfiSerialIoProtocolGuid, (VOID **) &SerialIo); + Status = gBS->HandleProtocol (OpenInfoBuffer[ChildIndex].ControllerHandle, &gEfiSerialIoProtocolGuid, (VOID **) &SerialIo); if (!EFI_ERROR (Status)) { SioSerial = &SioPtr->Serial[ResourceList->Device.UID]; SioSerial->Address = (UINT16) IoResource->StartRange; -- 2.9.0.windows.1