summaryrefslogtreecommitdiffstats
path: root/EmbeddedPkg/Include
diff options
context:
space:
mode:
authorLeif Lindholm <leif.lindholm@linaro.org>2019-06-13 16:48:28 +0100
committerLeif Lindholm <leif.lindholm@linaro.org>2019-06-17 12:04:11 +0100
commit1d7571166fa8ef4bee3264e8a027b49ea9d98bd3 (patch)
tree66514a24ae6b5b5b316362dbab62f26294f615fe /EmbeddedPkg/Include
parent7c974d6b6e8119372d9e51b8b686d31d8665ab91 (diff)
downloadedk2-1d7571166fa8ef4bee3264e8a027b49ea9d98bd3.tar.gz
edk2-1d7571166fa8ef4bee3264e8a027b49ea9d98bd3.tar.bz2
edk2-1d7571166fa8ef4bee3264e8a027b49ea9d98bd3.zip
EmbeddedPkg: improve TimeBaseLib type safety
EfiTimeToEpoch currently returns a UINTN. Also, some internal calculations was using UINTN for fixed-width. Both of these lead to warnings/errors with VS2017. Replace with appropriate fixed-size types. BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=997 Cc: Alexei Fedorov <Alexei.Fedorov@arm.com> Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org> Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Philippe Mathieu-Daude <philmd@redhat.com>
Diffstat (limited to 'EmbeddedPkg/Include')
-rw-r--r--EmbeddedPkg/Include/Library/TimeBaseLib.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/EmbeddedPkg/Include/Library/TimeBaseLib.h b/EmbeddedPkg/Include/Library/TimeBaseLib.h
index d51059cb1f..4103c89b38 100644
--- a/EmbeddedPkg/Include/Library/TimeBaseLib.h
+++ b/EmbeddedPkg/Include/Library/TimeBaseLib.h
@@ -1,7 +1,7 @@
/** @file
*
* Copyright (c) 2016, Hisilicon Limited. All rights reserved.
-* Copyright (c) 2016, Linaro Limited. All rights reserved.
+* Copyright (c) 2016-2019, Linaro Limited. All rights reserved.
*
* SPDX-License-Identifier: BSD-2-Clause-Patent
*
@@ -53,7 +53,7 @@ EpochToEfiTime (
/**
Converts EFI_TIME to Epoch seconds (elapsed since 1970 JANUARY 01, 00:00:00 UTC)
**/
-UINTN
+UINT32
EFIAPI
EfiTimeToEpoch (
IN EFI_TIME *Time