summaryrefslogtreecommitdiffstats
path: root/MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2018-02-20 10:53:10 +0000
committerArd Biesheuvel <ard.biesheuvel@linaro.org>2018-02-24 13:58:53 +0000
commit7f029e1b31ee854f7963124080372d8355d745b8 (patch)
tree48e842f94a871b38065ebe99dd49bcb8eaea6a4c /MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni
parent8bdb0221152c762b9209cadaf238a1498dc04695 (diff)
downloadedk2-7f029e1b31ee854f7963124080372d8355d745b8.tar.gz
edk2-7f029e1b31ee854f7963124080372d8355d745b8.tar.bz2
edk2-7f029e1b31ee854f7963124080372d8355d745b8.zip
MdePkg: introduce DxeRuntimeDebugLibSerialPort
Introduce a variant of BaseDebugLibSerialPort that behaves correctly with regards to the use of the serial port after ExitBootServices(). At boot time, all DEBUG() prints and ASSERT() invocations are executed normally. At runtime, DEBUG() prints are dropped entirely, and ASSERT()s omit the serial output as well, and only perform the configured post-ASSERT() action, i.e., issue a CPU breakpoint or enter a deadloop. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
Diffstat (limited to 'MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni')
-rw-r--r--MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni21
1 files changed, 21 insertions, 0 deletions
diff --git a/MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni b/MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni
new file mode 100644
index 0000000000..cc7f9fcf4f
--- /dev/null
+++ b/MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.uni
@@ -0,0 +1,21 @@
+// /** @file
+// DXE runtime Debug library instance based on Serial Port library.
+// It takes care not to call into SerialPortLib after ExitBootServices() has
+// been called, to prevent touching hardware that is no longer owned by the
+// firmware.
+//
+// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
+//
+// This program and the accompanying materials
+// are licensed and made available under the terms and conditions of the BSD License
+// which accompanies this distribution. The full text of the license may be found at
+// http://opensource.org/licenses/bsd-license.php.
+// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+//
+// **/
+
+
+#string STR_MODULE_ABSTRACT #language en-US "DXE runtime Debug library instance based on Serial Port library"
+
+#string STR_MODULE_DESCRIPTION #language en-US "It takes care not to call into SerialPortLib after ExitBootServices() has been called."