2 Detection code for QEMU debug port.
3 Non-SEC instance, caches the result of detection.
5 Copyright (c) 2017, Red Hat, Inc.<BR>
6 This program and the accompanying materials
7 are licensed and made available under the terms and conditions of the BSD License
8 which accompanies this distribution. The full text of the license may be found at
9 http://opensource.org/licenses/bsd-license.php.
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
17 #include "DebugLibDetect.h"
20 // Set to TRUE if the debug I/O port is enabled
22 STATIC BOOLEAN mDebugIoPortFound
= FALSE
;
25 This constructor function checks if the debug I/O port device is present,
26 caching the result for later use.
28 @retval RETURN_SUCCESS The constructor always returns RETURN_SUCCESS.
33 PlatformDebugLibIoPortConstructor (
37 mDebugIoPortFound
= PlatformDebugLibIoPortDetect();
38 return RETURN_SUCCESS
;
42 Return the cached result of detecting the debug I/O port device.
44 @retval TRUE if the debug I/O port device was detected.
45 @retval FALSE otherwise
50 PlatformDebugLibIoPortFound (
54 return mDebugIoPortFound
;