diff options
author | Qiu Shumin <shumin.qiu@intel.com> | 2016-04-18 15:59:58 +0800 |
---|---|---|
committer | Hao Wu <hao.a.wu@intel.com> | 2016-07-13 20:42:59 +0800 |
commit | 421d056d9177f75ca84aa9da46d2d12c90cea550 (patch) | |
tree | fec6c3646072e36441064ea40985120007f48833 /ShellPkg/Library/UefiShellDriver1CommandsLib | |
parent | f3d8406ffd531954df2abde595a1cab6ff955675 (diff) | |
download | edk2-platforms-421d056d9177f75ca84aa9da46d2d12c90cea550.tar.xz |
ShellPkg: Support connect a device handle recursively with '-r'.
This patch make Shell 'connect' a device handle recursively with
'-r' option.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qiu Shumin <shumin.qiu@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
(cherry picked from commit b5e44fbc15085270adfc777c0f2c1890c1e9790f)
Diffstat (limited to 'ShellPkg/Library/UefiShellDriver1CommandsLib')
-rw-r--r-- | ShellPkg/Library/UefiShellDriver1CommandsLib/Connect.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/Connect.c b/ShellPkg/Library/UefiShellDriver1CommandsLib/Connect.c index 5d61c2f601..dd3d4a6a27 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/Connect.c +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/Connect.c @@ -2,7 +2,7 @@ Main file for connect shell Driver1 function.
(C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>
- Copyright (c) 2010 - 2014, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2016, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -452,9 +452,10 @@ ShellCommandRunConnect ( //
Count = (gInReconnect?0x4:0x3);
if ((ShellCommandLineGetCount(Package) > Count)
- ||((ShellCommandLineGetFlag(Package, L"-r") || ShellCommandLineGetFlag(Package, L"-c")) && ShellCommandLineGetCount(Package)>1)
+ ||(ShellCommandLineGetFlag(Package, L"-c") && ShellCommandLineGetCount(Package)>1)
+ ||(ShellCommandLineGetFlag(Package, L"-r") && ShellCommandLineGetCount(Package)>2)
||(ShellCommandLineGetFlag(Package, L"-r") && ShellCommandLineGetFlag(Package, L"-c") )
- ){
+ ){
//
// error for too many parameters
//
|