From: "Nate DeSimone" <nathaniel.l.desimone@intel.com>
To: "Kubacki, Michael A" <michael.a.kubacki@intel.com>,
"devel@edk2.groups.io" <devel@edk2.groups.io>
Cc: "Chaganty, Rangasai V" <rangasai.v.chaganty@intel.com>,
"Chiu, Chasel" <chasel.chiu@intel.com>,
"Gao, Zhichao" <zhichao.gao@intel.com>
Subject: Re: [edk2-platforms][PATCH V1 2/2] KabylakeSiliconPkg: Remove redundant ResetSystem() implementation
Date: Wed, 27 Nov 2019 04:49:44 +0000 [thread overview]
Message-ID: <02A34F284D1DA44BB705E61F7180EF0AB5C03201@ORSMSX114.amr.corp.intel.com> (raw)
In-Reply-To: <20191127025643.32056-3-michael.a.kubacki@intel.com>
Reviewed-by: Nate DeSimone <nathaniel.l.desimone@intel.com>
-----Original Message-----
From: Kubacki, Michael A <michael.a.kubacki@intel.com>
Sent: Tuesday, November 26, 2019 6:57 PM
To: devel@edk2.groups.io
Cc: Chaganty, Rangasai V <rangasai.v.chaganty@intel.com>; Chiu, Chasel <chasel.chiu@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>; Gao, Zhichao <zhichao.gao@intel.com>
Subject: [edk2-platforms][PATCH V1 2/2] KabylakeSiliconPkg: Remove redundant ResetSystem() implementation
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2375
The following commits introduced a new implementation of ResetSystem () in ResetLib instances in KabylakeSiliconPkg:
* 2393cff0d4
* 07fd95c9ca
* 0ad2f057d8
* a6e61d43c9
The PchResetLib instance PeiPchResetLib links against ResetLib and already contained a definition of ResetSystem (). This resulted in a build failure in VS2017 due to multiple definitions of a symbol being provided to the linker. The failure did not reproduce in
VS2015 so it persisted until now.
This change removes the pre-existing implementation of ResetSystem () in PchReset.c as it is now linked by the implementation in the ResetLib instance.
Cc: Sai Chaganty <rangasai.v.chaganty@intel.com>
Cc: Chasel Chiu <chasel.chiu@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Zhichao Gao <zhichao.gao@intel.com>
Signed-off-by: Michael Kubacki <michael.a.kubacki@intel.com>
---
Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiPchResetLib/PchReset.c | 55 --------------------
Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiResetSystemLib/PeiResetSystemLib.c | 5 ++
2 files changed, 5 insertions(+), 55 deletions(-)
diff --git a/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiPchResetLib/PchReset.c b/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiPchResetLib/PchReset.c
index 20e5d36892..c3963164c1 100644
--- a/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiPchResetLib/PchReset.c
+++ b/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiPchResetLib/PchRes
+++ et.c
@@ -18,61 +18,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include <Library/ResetSystemLib.h> #include <PchResetPlatformSpecific.h>
-VOID
-EFIAPI
-ResetPlatformSpecific (
- IN UINTN DataSize,
- IN VOID *ResetData OPTIONAL
- );
-
-
-/**
- Resets the entire platform.
-
- @param[in] ResetType UEFI defined reset type.
- @param[in] ResetStatus The status code for the reset.
- @param[in] DataSize The size of ResetData in bytes.
- @param[in] ResetData Optional element used to introduce a platform specific reset.
- The exact type of the reset is defined by the EFI_GUID that follows
- the Null-terminated Unicode string.
-
-**/
-VOID
-EFIAPI
-ResetSystem (
- IN EFI_RESET_TYPE ResetType,
- IN EFI_STATUS ResetStatus,
- IN UINTN DataSize,
- IN VOID *ResetData OPTIONAL
- )
-{
- switch (ResetType) {
- case EfiResetWarm:
- ResetWarm ();
- break;
-
- case EfiResetCold:
- ResetCold ();
- break;
-
- case EfiResetShutdown:
- ResetShutdown ();
- return;
-
- case EfiResetPlatformSpecific:
- ResetPlatformSpecific (DataSize, ResetData);
- return;
-
- default:
- return;
- }
-
- //
- // Given we should have reset getting here would be bad
- //
- ASSERT (FALSE);
-}
-
/**
Execute Pch Reset from the host controller.
diff --git a/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiResetSystemLib/PeiResetSystemLib.c b/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiResetSystemLib/PeiResetSystemLib.c
index 6f12abf111..a3db100619 100644
--- a/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiResetSystemLib/PeiResetSystemLib.c
+++ b/Silicon/Intel/KabylakeSiliconPkg/Pch/Library/PeiResetSystemLib/Pei
+++ ResetSystemLib.c
@@ -317,5 +317,10 @@ ResetSystem (
default:
return;
}
+
+ //
+ // Given we should have reset getting here would be bad // ASSERT
+ (FALSE);
}
--
2.16.2.windows.1
prev parent reply other threads:[~2019-11-27 4:49 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-27 2:56 [edk2-platforms][PATCH V1 0/2] KabylakeSiliconPkg: Remove redundant ResetSystem() implementation Kubacki, Michael A
2019-11-27 2:56 ` [edk2-platforms][PATCH V1 1/2] KabylakeSiliconPkg: Remove ResetSystemLib.h override Kubacki, Michael A
2019-11-27 3:26 ` Chiu, Chasel
2019-11-27 4:49 ` Nate DeSimone
2019-11-27 6:42 ` Chaganty, Rangasai V
2019-11-27 18:41 ` Kubacki, Michael A
2019-11-28 0:31 ` Kubacki, Michael A
2019-12-02 8:36 ` Chaganty, Rangasai V
2019-11-27 2:56 ` [edk2-platforms][PATCH V1 2/2] KabylakeSiliconPkg: Remove redundant ResetSystem() implementation Kubacki, Michael A
2019-11-27 3:26 ` Chiu, Chasel
2019-11-27 4:49 ` Nate DeSimone [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=02A34F284D1DA44BB705E61F7180EF0AB5C03201@ORSMSX114.amr.corp.intel.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox