From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=209.132.183.28; helo=mx1.redhat.com; envelope-from=lersek@redhat.com; receiver=edk2-devel@lists.01.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (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 CD77221B00DC4 for ; Thu, 16 Nov 2017 14:13:01 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 583796A7D2; Thu, 16 Nov 2017 22:17:11 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-80.rdu2.redhat.com [10.10.120.80]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7129B46E84; Thu, 16 Nov 2017 22:17:10 +0000 (UTC) To: Ard Biesheuvel , edk2-devel@lists.01.org, leif.lindholm@linaro.org References: <20171116174708.24964-1-ard.biesheuvel@linaro.org> <20171116174708.24964-3-ard.biesheuvel@linaro.org> From: Laszlo Ersek Message-ID: <7884b0a5-d42c-23de-2dd3-fee5bde85947@redhat.com> Date: Thu, 16 Nov 2017 23:17:09 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: <20171116174708.24964-3-ard.biesheuvel@linaro.org> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Thu, 16 Nov 2017 22:17:11 +0000 (UTC) Subject: Re: [PATCH v2 2/2] ArmVirtPkg: switch to new PL011UartLib implementation X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Nov 2017 22:13:02 -0000 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 11/16/17 18:47, Ard Biesheuvel wrote: > Switch to the new, cleaned up PL011UartLib implementation so we will > be able to remove the old one. > > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Ard Biesheuvel > --- > ArmVirtPkg/ArmVirt.dsc.inc | 2 +- > ArmVirtPkg/Library/FdtPL011SerialPortLib/EarlyFdtPL011SerialPortLib.c | 5 ++--- > ArmVirtPkg/Library/FdtPL011SerialPortLib/FdtPL011SerialPortLib.c | 5 ++--- > 3 files changed, 5 insertions(+), 7 deletions(-) > > diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc > index c92a69281ae4..50eb8675d1c0 100644 > --- a/ArmVirtPkg/ArmVirt.dsc.inc > +++ b/ArmVirtPkg/ArmVirt.dsc.inc > @@ -106,7 +106,7 @@ [LibraryClasses.common] > RealTimeClockLib|ArmPlatformPkg/Library/PL031RealTimeClockLib/PL031RealTimeClockLib.inf > TimeBaseLib|EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.inf > # ARM PL011 UART Driver > - PL011UartLib|ArmPlatformPkg/Drivers/PL011Uart/PL011Uart.inf > + PL011UartLib|ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.inf > SerialPortLib|ArmVirtPkg/Library/FdtPL011SerialPortLib/FdtPL011SerialPortLib.inf > > # > diff --git a/ArmVirtPkg/Library/FdtPL011SerialPortLib/EarlyFdtPL011SerialPortLib.c b/ArmVirtPkg/Library/FdtPL011SerialPortLib/EarlyFdtPL011SerialPortLib.c > index e28750f3b4c4..d9fd0ef98359 100644 > --- a/ArmVirtPkg/Library/FdtPL011SerialPortLib/EarlyFdtPL011SerialPortLib.c > +++ b/ArmVirtPkg/Library/FdtPL011SerialPortLib/EarlyFdtPL011SerialPortLib.c > @@ -16,14 +16,13 @@ > > **/ > > -#include > +#include > > #include > +#include > #include > #include > > -#include > - > RETURN_STATUS > EFIAPI > SerialPortInitialize ( > diff --git a/ArmVirtPkg/Library/FdtPL011SerialPortLib/FdtPL011SerialPortLib.c b/ArmVirtPkg/Library/FdtPL011SerialPortLib/FdtPL011SerialPortLib.c > index 05d3547fda91..c161dd6349d3 100644 > --- a/ArmVirtPkg/Library/FdtPL011SerialPortLib/FdtPL011SerialPortLib.c > +++ b/ArmVirtPkg/Library/FdtPL011SerialPortLib/FdtPL011SerialPortLib.c > @@ -17,9 +17,10 @@ > > **/ > > -#include > +#include > > #include > +#include > #include > #include > #include > @@ -28,8 +29,6 @@ > #include > #include > > -#include > - > STATIC UINTN mSerialBaseAddress; > > RETURN_STATUS > Awesome idea! One comment: can you please check whether, if you replace #include with #include then stuff will still build? Both SerialPortLib instances are BASE, so we should not include (in particular included by it). If it works, then: Reviewed-by: Laszlo Ersek If it doesn't work, then I think we should figure out why not; it could be a sign of some layering violation, which would be nice to document at least in the commit message. Thanks Laszlo