From nobody Mon Apr 29 13:24:45 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail(p=none dis=none) header.from=intel.com Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1529638338991510.795688810305; Thu, 21 Jun 2018 20:32:18 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 1A212210D93D6; Thu, 21 Jun 2018 20:32:18 -0700 (PDT) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) (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 315C8210D93B3 for ; Thu, 21 Jun 2018 20:32:16 -0700 (PDT) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Jun 2018 20:32:16 -0700 Received: from zwei4-mobl1.ccr.corp.intel.com ([10.239.193.131]) by orsmga001.jf.intel.com with ESMTP; 21 Jun 2018 20:32:14 -0700 X-Original-To: edk2-devel@lists.01.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.43; helo=mga05.intel.com; envelope-from=david.wei@intel.com; receiver=edk2-devel@lists.01.org X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,255,1526367600"; d="scan'208";a="66690832" From: zwei4 To: edk2-devel@lists.01.org Date: Fri, 22 Jun 2018 11:32:04 +0800 Message-Id: <20180622033204.6036-1-david.wei@intel.com> X-Mailer: git-send-email 2.14.1.windows.1 Subject: [edk2] [Patch][edk2-platforms/devel-MinnowBoardMax-UDK2017] UART COM INT3511 X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Add sub-device under HS-UART 1 controller to report HS-UART as COM port. Th= e _HID of the sub-device is INT3511. The design follows below Intel white paper: https://www.intel.com/content/dam/www/public/us/en/documents/white-papers/e= nabling-multi-com-port-white-paper.pdf Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: zwei4 --- Vlv2DeviceRefCodePkg/AcpiTablesPCAT/GloblNvs.asl | 2 +- Vlv2DeviceRefCodePkg/AcpiTablesPCAT/PchLpss.asl | 81 +++++++++--------= ---- Vlv2TbltDevicePkg/AcpiPlatform/AcpiPlatform.c | 2 +- Vlv2TbltDevicePkg/Include/Guid/SetupVariable.h | 2 +- Vlv2TbltDevicePkg/Include/Protocol/GlobalNvsArea.h | 2 +- .../PlatformSetupDxe/SouthClusterConfig.vfi | 6 +- Vlv2TbltDevicePkg/PlatformSetupDxe/UqiList.uni | Bin 67184 -> 67184 by= tes Vlv2TbltDevicePkg/PlatformSetupDxe/VfrStrings.uni | Bin 216530 -> 216550 = bytes 8 files changed, 43 insertions(+), 52 deletions(-) diff --git a/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/GloblNvs.asl b/Vlv2DeviceR= efCodePkg/AcpiTablesPCAT/GloblNvs.asl index 0373e935b7..827d01acb2 100644 --- a/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/GloblNvs.asl +++ b/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/GloblNvs.asl @@ -350,6 +350,6 @@ Field(GNVS,AnyAcc,Lock,Preserve) IOT, 8, //(794) MinnowBoard Max JP1 is configured for MSFT IOT= project. BATT, 8, //(795) The Flag of RTC Battery Prensent. =20 LPAD, 8, //(796)=20 - U1CM, 8, //(797) Report UART1 as PNP0501 COM.=20 + U1CM, 8, //(797) Report UART1 as COM.=20 } =20 diff --git a/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/PchLpss.asl b/Vlv2DeviceRe= fCodePkg/AcpiTablesPCAT/PchLpss.asl index 5018b05346..14ae6f8899 100644 --- a/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/PchLpss.asl +++ b/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/PchLpss.asl @@ -225,13 +225,6 @@ Device(URT1) Return (0x0) } =20 - // - // Is UART 1 is reported as PNP0501 COM? - // - If(LEqual(U1CM, One)) { - Return (0x0) =20 - } - Return (0xF) } =20 @@ -253,48 +246,46 @@ Device(URT1) Offset (0x84), PSAT, 32 } -}// Device (URT1) - -Device(U1CO) // UART 1 as COM -{ - Name(_HID, EISAID("PNP0501")) - Name(_UID,2) // _UID must not conflict wit _UID of LPC COM. - - Name (RBUF, ResourceTemplate () - { - Memory32Fixed (ReadWrite, 0x00000000, 0x00001000, BAR0) - Interrupt (ResourceConsumer, Level, ActiveLow, Exclusive, , , ) {39} = // HS-UART #1 IRQ - - FixedDMA(0x2, 0x2, Width32Bit, ) - FixedDMA(0x3, 0x3, Width32Bit, ) - }) =20 - Method (_CRS, 0x0, NotSerialized) - { - CreateDwordField(^RBUF, ^BAR0._BAS, B0BA) - CreateDwordField(^RBUF, ^BAR0._LEN, B0LN) - Store(U10A, B0BA) - Store(U10L, B0LN) - Return (RBUF) - } + // + // Virtual COM port for HSUART1 + // + Device (VUT0) { =20 - Method(_STA,0,Serialized) - { =20 - If (LOr(LEqual(U10A, 0), LEqual(L13D, 1))) - { - Return (0x0000) - } + Name (_HID, "INT3511") =20 - // - // Is UART 1 reported as PNP0501 COM? - // - If(LEqual(U1CM, One)) { - Return(0x000F) - } Else { - Return(0x0000) + Method (_STA, 0x0, NotSerialized) + { + If(LEqual(U1CM, 1)) { + Return(0xf) + } else { + Return(0x0) + } } - } -} + + Method (_CRS, 0, NotSerialized) { + Name (BBUF, ResourceTemplate () { + UartSerialBus ( + 0x0001C200,=20 + DataBitsEight,=20 + StopBitsOne,=20 + 0xFC,=20 + LittleEndian,=20 + ParityTypeNone,=20 + FlowControlHardware, + 0x0020,=20 + 0x0020,=20 + "\\_SB.URT1", + 0x00,=20 + ResourceConsumer,=20 + , + ) + }) + Return (BBUF) + } + + } //Device (VUT0) +}// Device (URT1) =20 // // LPIO1 HS-UART #2 diff --git a/Vlv2TbltDevicePkg/AcpiPlatform/AcpiPlatform.c b/Vlv2TbltDevice= Pkg/AcpiPlatform/AcpiPlatform.c index adb79e0fd2..58c1dc1402 100644 --- a/Vlv2TbltDevicePkg/AcpiPlatform/AcpiPlatform.c +++ b/Vlv2TbltDevicePkg/AcpiPlatform/AcpiPlatform.c @@ -1146,7 +1146,7 @@ AcpiPlatformEntryPoint ( // // Report UART1 as PNP0501 COM. // - mGlobalNvsArea.Area->Uart1Pnp0501Com =3D mSystemConfiguration.Uart1Pnp05= 01Com; + mGlobalNvsArea.Area->Uart1Int3511Com =3D mSystemConfiguration.Uart1Int35= 11Com; =20 // // SIO related option. diff --git a/Vlv2TbltDevicePkg/Include/Guid/SetupVariable.h b/Vlv2TbltDevic= ePkg/Include/Guid/SetupVariable.h index fc2fc86f77..f0319b6c58 100644 --- a/Vlv2TbltDevicePkg/Include/Guid/SetupVariable.h +++ b/Vlv2TbltDevicePkg/Include/Guid/SetupVariable.h @@ -1310,7 +1310,7 @@ typedef struct { UINT8 GpioWakeCapability; UINT8 RtcBattery; UINT8 LpeAudioReportedByDSDT; - UINT8 Uart1Pnp0501Com; // Report UART1 as PNP0501 COM + UINT8 Uart1Int3511Com; // Report UART1 as COM with _HID INT3511 =20 } SYSTEM_CONFIGURATION; #pragma pack() diff --git a/Vlv2TbltDevicePkg/Include/Protocol/GlobalNvsArea.h b/Vlv2TbltD= evicePkg/Include/Protocol/GlobalNvsArea.h index 03468f9357..ca67d67d1b 100644 --- a/Vlv2TbltDevicePkg/Include/Protocol/GlobalNvsArea.h +++ b/Vlv2TbltDevicePkg/Include/Protocol/GlobalNvsArea.h @@ -473,7 +473,7 @@ typedef struct { UINT8 MicrosoftIoT; // (794)JP1 pins are for = Microsoft IoT project. UINT8 RtcBattery; // (795) The Flag of RTC = Battery Present. UINT8 LpeAudioReportedByDSDT; // (796) - UINT8 Uart1Pnp0501Com; // (797) Report UART 1 as= PNP0501 COM. + UINT8 Uart1Int3511Com; // (797) Report UART 1 as= INT3511 COM. } EFI_GLOBAL_NVS_AREA; #pragma pack () =20 diff --git a/Vlv2TbltDevicePkg/PlatformSetupDxe/SouthClusterConfig.vfi b/Vl= v2TbltDevicePkg/PlatformSetupDxe/SouthClusterConfig.vfi index 10ff008da5..a0cb102b8f 100644 --- a/Vlv2TbltDevicePkg/PlatformSetupDxe/SouthClusterConfig.vfi +++ b/Vlv2TbltDevicePkg/PlatformSetupDxe/SouthClusterConfig.vfi @@ -587,9 +587,9 @@ endif; // grayoutif NOT ideqval Setup.LpssSdcardEna= bled =3D=3D 0x1; endif; =20 grayoutif ideqval Setup.LpssHsuart0Enabled =3D=3D 0x00; - oneof varid =3D Setup.Uart1Pnp0501Com, - prompt =3D STRING_TOKEN(STR_LPSS_HSUART1_PNP0501_PROMPT), - help =3D STRING_TOKEN(STR_LPSS_HSUART1_PNP0501_HELP_ENBDT_DEV_L= IST), + oneof varid =3D Setup.Uart1Int3511Com, + prompt =3D STRING_TOKEN(STR_LPSS_HSUART1_INT3511_PROMPT), + help =3D STRING_TOKEN(STR_LPSS_HSUART1_INT3511_HELP_ENBDT_DEV_L= IST), option text =3D STRING_TOKEN(STR_DISABLE), value=3D0, flags=3D0 |DEFAU= LT | RESET_REQUIRED; option text =3D STRING_TOKEN(STR_ENABLE), value=3D1, flags=3D MANUFACT= URING | RESET_REQUIRED; endoneof; diff --git a/Vlv2TbltDevicePkg/PlatformSetupDxe/UqiList.uni b/Vlv2TbltDevic= ePkg/PlatformSetupDxe/UqiList.uni index d6e5ccd05a1ba303329e083d673342cddb4cef9c..f392fd250b13da70acd64dc64f4= 6796a9417c1fe 100644 GIT binary patch delta 49 vcmey+!}6hrrC|$W5-YbSgC9c(gE50CgW+VxAmix^SQ%501*h|~F(v{4R<;X+ delta 49 vcmey+!}6hrrC|$W5-WEAgC9cxg8_pngTZ9RAmix^SQ%501*h|~F(v{4R@n=3DI diff --git a/Vlv2TbltDevicePkg/PlatformSetupDxe/VfrStrings.uni b/Vlv2TbltDe= vicePkg/PlatformSetupDxe/VfrStrings.uni index af716784d740092f6b6f725ec43bff4ab2a84b1a..ad4cf64405e100f8f554d26badb= 01eb2d38a3128 100644 GIT binary patch delta 157 zcmcaKoA=3Dpl-i9rV5zn|i8T=3DSR7>pTA84Ra0&R{g0o^YE{Z+hQzMgeg{1_cHrX$BDA znZbW@;!nlt7oIbUZC7~CxQU+^Magu-PmKE0`Mxtw(*!DI@C9lqXUJqIVaNco;u$=3DE Y2D+ddJGn4Nwf)|A#_jjMGkpmK00+V<0ssI2 delta 137 zcmaDhoA=3DUe-i9rV5zn{-82lIl7z`Lp84RW~&R{g0p75N}PTY_|0VoQWVF2-+8T=3Dpl(Q512ARtDe6g*mFz8-6l!wEz0fxc%36 HrZ=3DGg?-(Zn --=20 2.14.1.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel