From 337284066962dd48ecb86e00a07bb6f54841d2a6 Mon Sep 17 00:00:00 2001 From: jcarsey Date: Tue, 1 Nov 2011 20:05:11 +0000 Subject: ShellPkg: swap warm and cold to get the default correct for Reset command. sighed-off-by: jcarsey reviewed-by: gookboy15a git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12623 6f19259b-4bc3-4df7-8a09-765794883524 --- ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'ShellPkg') diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c index d0eea8d033..f69a79b71a 100644 --- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c +++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Reset.c @@ -72,14 +72,14 @@ ShellCommandRunReset ( ShellStatus = SHELL_INVALID_PARAMETER; } else { // - // check for cold reset flag, then shutdown reset flag, then warm (default) reset flag + // check for warm reset flag, then shutdown reset flag, then cold (default) reset flag // - if (ShellCommandLineGetFlag(Package, L"-c")) { - if (ShellCommandLineGetFlag(Package, L"-s") || ShellCommandLineGetFlag(Package, L"-w")) { + if (ShellCommandLineGetFlag(Package, L"-w")) { + if (ShellCommandLineGetFlag(Package, L"-s") || ShellCommandLineGetFlag(Package, L"-c")) { ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_TOO_MANY), gShellLevel2HiiHandle); ShellStatus = SHELL_INVALID_PARAMETER; } else { - String = ShellCommandLineGetValue(Package, L"-c"); + String = ShellCommandLineGetValue(Package, L"-w"); if (String != NULL) { gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, StrSize(String), (VOID*)String); } else { @@ -87,7 +87,7 @@ ShellCommandRunReset ( } } } else if (ShellCommandLineGetFlag(Package, L"-s")) { - if (ShellCommandLineGetFlag(Package, L"-w")) { + if (ShellCommandLineGetFlag(Package, L"-c")) { ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_TOO_MANY), gShellLevel2HiiHandle); ShellStatus = SHELL_INVALID_PARAMETER; } else { @@ -103,7 +103,7 @@ ShellCommandRunReset ( // // this is default so dont worry about flag... // - String = ShellCommandLineGetValue(Package, L"-w"); + String = ShellCommandLineGetValue(Package, L"-c"); if (String != NULL) { gRT->ResetSystem(EfiResetWarm, EFI_SUCCESS, StrSize(String), (VOID*)String); } else { -- cgit v1.2.3