You've already forked slimbootloader
mirror of
https://github.com/Dasharo/slimbootloader.git
synced 2026-03-06 15:26:20 -08:00
fix: [RPL-P] Build error when ENABLE_SOURCE_DEBUG=1.
On platforms where only serial console input is enabled, enabling source debug will lead to an infinite loop in ConsoleRead(). Newer compilers detect this and generate a build error. Signed-off-by: Bejean Mosher <bejean.mosher@intel.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Implementation for console input library
|
||||
|
||||
Copyright (c) 2018, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2023, Intel Corporation. All rights reserved.<BR>
|
||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||
|
||||
**/
|
||||
@@ -79,6 +79,11 @@ ConsoleRead (
|
||||
Count += ReadCount;
|
||||
}
|
||||
}
|
||||
// If only serial enabled, and Source Debug enabled, return
|
||||
// error here to prevent infinite loop and build error.
|
||||
else if (PcdGet32 (PcdConsoleInDeviceMask) == ConsoleInSerialPort) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
if ((PcdGet32 (PcdConsoleInDeviceMask) & ConsoleInUsbKeyboard) != 0) {
|
||||
|
||||
Reference in New Issue
Block a user