From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a00:1450:400c:c09::242; helo=mail-wm0-x242.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-wm0-x242.google.com (mail-wm0-x242.google.com [IPv6:2a00:1450:400c:c09::242]) (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 D92B3224E690A for ; Thu, 1 Mar 2018 10:05:48 -0800 (PST) Received: by mail-wm0-x242.google.com with SMTP id t6so13935779wmt.5 for ; Thu, 01 Mar 2018 10:11:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=nsdffjQlvo/ajAOsMUpnmXlPdR8YeCfIO0kuS+5EgP4=; b=Kvxtb8mFlx0JOGa66eA6LJ0QM0U4pB/SoMz/mZDotPgIWwT5Wv2fYz7nKh75dQP4gS /JjtJXVjCs8grolDM9w0w2dGY80qGpq8xVJjLZX/dcCoYH/8fLMYuA7LVijipIiHw/Zx /RzYvepn2KVX7n/CD8pW/GxfAF5QOl3zvvEME= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=nsdffjQlvo/ajAOsMUpnmXlPdR8YeCfIO0kuS+5EgP4=; b=jvaEyDpS3x2AuERL4Sdl7J0NHCASFDE9SP7jB0zG+gUzRml40iDeDbXyo8eR3qKkLt CJQXC8rCZg0MLT/pK4OhBpSNUmHhM7gen+wnDaRrXpUAPxKUxB8zwJG8qXy9ItMAhMoy cKIAKbk6REp0hJqgPb2YCBSMtIc3uCPIPv3RmgnOIPYTBY1XUGhhJFYUgYXlLLFsIx+c 5mPlt3bcikYrEHVoATcXUiS8z15q/r7LugPw2qjCeq+fLiBlG8dDruuB620bfqaEHMqr /0FhurtIwihjb0faamiFz0B5IjXdFExEvNoMdb+ICAlB1x6jXuxs+55VZun7gyF8oWDj 2Ngw== X-Gm-Message-State: APf1xPBuyK0wmC3/FkyxD+guipmZcMbzSqeZoLPXj1Jx+ZZ4DiAl9OR+ B5Y7tGdD3sBHmjgFO8kyp174eKY6VIo= X-Google-Smtp-Source: AG47ELtvh1nZNudjrLVv8MOVN2Di63hKLZPso/t/08rpxxMbGSiY6SNb9eplmkg7IHKkFvC0Gb997g== X-Received: by 10.28.191.90 with SMTP id p87mr2308811wmf.145.1519927915579; Thu, 01 Mar 2018 10:11:55 -0800 (PST) Received: from localhost.localdomain ([196.71.216.221]) by smtp.gmail.com with ESMTPSA id w195sm78568wmw.9.2018.03.01.10.11.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 01 Mar 2018 10:11:54 -0800 (PST) From: Ard Biesheuvel To: edk2-devel@lists.01.org Cc: lersek@redhat.com, leif.lindholm@linaro.org, heyi.guo@linaro.org, star.zeng@intel.com, eric.dong@intel.com, michael.d.kinney@intel.com, liming.gao@intel.com, Ard Biesheuvel Date: Thu, 1 Mar 2018 18:11:38 +0000 Message-Id: <20180301181142.16817-1-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.11.0 Subject: [PATCH 0/4] implement runtime debug output protocl X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Mar 2018 18:05:49 -0000 As discussed on list, MMIO based UARTs cannot be used at runtime without taking special precautions to register the MMIO region and switch to the virtual address when accessing it at runtime. So extend the recently introduced DxeRuntimeDebugLibSerialPort library by invoking the proposed RuntimeDebugOutput protocol at runtime if one is available, and providing an implementation of this protocol for PL011. Ard Biesheuvel (4): MdePkg: move DxeRuntimeDebugLibSerialPort to MdeModulePkg MdeModulePkg: introduce runtime debug output protocol MdeModulePkg/DxeRuntimeDebugLibSerialPort: invoke RuntimeDebugOutputProtocol ArmPlatformPkg: add PL011 UART runtime debug driver ArmPlatformPkg/Drivers/PL011RuntimeDebugOutputDxe/PL011RuntimeDebugOutputDxe.c | 144 ++++++++++++++++++ ArmPlatformPkg/Drivers/PL011RuntimeDebugOutputDxe/PL011RuntimeDebugOutputDxe.inf | 62 ++++++++ ArmVirtPkg/ArmVirt.dsc.inc | 2 +- MdeModulePkg/Include/Protocol/RuntimeDebugOutput.h | 58 ++++++++ {MdePkg => MdeModulePkg}/Library/DxeRuntimeDebugLibSerialPort/DebugLib.c | 155 +++++++++++++++++--- {MdePkg => MdeModulePkg}/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.inf | 5 + {MdePkg => MdeModulePkg}/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni | 0 MdeModulePkg/MdeModulePkg.dec | 4 + 8 files changed, 412 insertions(+), 18 deletions(-) create mode 100644 ArmPlatformPkg/Drivers/PL011RuntimeDebugOutputDxe/PL011RuntimeDebugOutputDxe.c create mode 100644 ArmPlatformPkg/Drivers/PL011RuntimeDebugOutputDxe/PL011RuntimeDebugOutputDxe.inf create mode 100644 MdeModulePkg/Include/Protocol/RuntimeDebugOutput.h rename {MdePkg => MdeModulePkg}/Library/DxeRuntimeDebugLibSerialPort/DebugLib.c (70%) rename {MdePkg => MdeModulePkg}/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.inf (88%) rename {MdePkg => MdeModulePkg}/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni (100%) -- 2.11.0