From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2607:f8b0:4864:20::d43; helo=mail-io1-xd43.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-io1-xd43.google.com (mail-io1-xd43.google.com [IPv6:2607:f8b0:4864:20::d43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 2A8AF211A4595 for ; Thu, 20 Dec 2018 07:30:28 -0800 (PST) Received: by mail-io1-xd43.google.com with SMTP id p7so990166iog.12 for ; Thu, 20 Dec 2018 07:30:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=OARxLA0k2t3xszD3CP/gMcASsqF1ar9wqEU/MVFyrDg=; b=Ii+sXFrkWH6t3DKK9HZwtk70mmE84IzMdIeO02ASR3NTQxjR2N/LRVmRxIarU662DK EeHF6CeXTwyN1/+XtWcWrk1z148iucCtgBztdHTo1JcVzZkqUpcUSOn6+sKGaSDDck2C LTrZZPsYdmMnZn6hjpHVsS2Wd/gCuKD23GjBw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=OARxLA0k2t3xszD3CP/gMcASsqF1ar9wqEU/MVFyrDg=; b=S7d+3QYUWC25j18tXuMthaEpqNGveUE9CEfWj/EzD31hIi1msaOBsyMXEUMp7QfOfn suROJ4l2jiXCy1c7wU2BRy/HODqfwahn8aARNthi7alqFXJLVP11kEZmgeQQKmo5gSX1 bXQtmHS22cbuUfFqhVgHs4yachdsdwBQWxk637rzjpooliKPVXshZwrix51stqj1keNX jfdL45Sc3JpEnHZT75nsgFOPkY11oBnlsQL2OcvezStvPHBBFROKjYKNiatm/Vfpdbx3 DzrokIm30OwyeNnarNkKea0CkT5LdMu1jGOmlpka2ehzggEZYwNWmJFZg9T2skh9lc/o ZocQ== X-Gm-Message-State: AJcUukdi92DitwRwouvdSXInaJTMFm2ILuSAnwa0zDX99qR7eHOjay3M Jayp0mteFPQuCrOTnnwQwTK9rmaZJxnB//6DVEbsZQ== X-Google-Smtp-Source: ALg8bN5S+QGIOXriLz3Ti34tDwrOLr1E7HFAY0fdru1wmR7tXbODRIKBJLFKcel6sE9NaIYaZExm3K90/LWBndGMrFA= X-Received: by 2002:a5d:8417:: with SMTP id i23mr958567ion.173.1545319828045; Thu, 20 Dec 2018 07:30:28 -0800 (PST) MIME-Version: 1.0 References: <20181217185353.24723-1-ard.biesheuvel@linaro.org> <20181220152035.cmgkmikiaqbuxwg4@bivouac.eciton.net> In-Reply-To: <20181220152035.cmgkmikiaqbuxwg4@bivouac.eciton.net> From: Ard Biesheuvel Date: Thu, 20 Dec 2018 16:30:15 +0100 Message-ID: To: Leif Lindholm Cc: "edk2-devel@lists.01.org" Subject: Re: [PATCH] Platform/FVP-AArch64: use different serial ports for DEBUG and console X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Dec 2018 15:30:29 -0000 Content-Type: text/plain; charset="UTF-8" On Thu, 20 Dec 2018 at 16:20, Leif Lindholm wrote: > > On Mon, Dec 17, 2018 at 07:53:53PM +0100, Ard Biesheuvel wrote: > > The FVP models expose several emulated serial ports, and always start with > > Xterm windows connected to at least two of them. So let's switch to the > > second one for DEBUG output, leaving the original one for console output > > via SerialDxe. > > Could you clarify whether this means _all_ non-DEBUG output will go to > the first UART, or whether there is a switchover point and some early > non-DEBUG messages will now appear on the second UART? > Ah yes, good point. So any explicit calls to SerialPorWrite () from modules other than SerialDxe will get directed to the second UART in this case. There is such a call in PrePi: CharCount = AsciiSPrint (Buffer,sizeof (Buffer), "UEFI firmware (version %s built at %a on %a)\n\r", (CHAR16*)PcdGetPtr(PcdFirmwareVersionString), __TIME__, __DATE__); SerialPortWrite ((UINT8 *) Buffer, CharCount) and in one or two other places. Also note that DEBUG() directives in SerialDxe itself will be sent to the non-DEBUG uart. I think it makes sense for the DefaultExceptionHandlerLib to write to the console instead of doing a SerialPortWrite () on RELEASE builds, so I'll look into that next. > With that: > Reviewed-by: Leif Lindholm > > > Contributed-under: TianoCore Contribution Agreement 1.1 > > Signed-off-by: Ard Biesheuvel > > --- > > Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc | 7 +++++-- > > 1 file changed, 5 insertions(+), 2 deletions(-) > > > > diff --git a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > > index 7094e57ee13a..7db1c675c3d9 100644 > > --- a/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > > +++ b/Platform/ARM/VExpressPkg/ArmVExpress-FVP-AArch64.dsc > > @@ -125,7 +125,7 @@ > > .inf diff format would have been slightly nicer here. > > > gArmPlatformTokenSpaceGuid.PcdSP805WatchdogClockFrequencyInHz|24000000 > > > > ## PL011 - Serial Terminal > > - gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c090000 > > + gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c0a0000 > > gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|115200 > > gEfiMdePkgTokenSpaceGuid.PcdUartDefaultReceiveFifoDepth|0 > > > > @@ -239,7 +239,10 @@ > > MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf > > MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf > > MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf > > - MdeModulePkg/Universal/SerialDxe/SerialDxe.inf > > + MdeModulePkg/Universal/SerialDxe/SerialDxe.inf { > > + > > + gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x1c090000 > > + } > > > > MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf > > > > -- > > 2.17.1 > >