summaryrefslogtreecommitdiffstats
path: root/ShellPkg
Commit message (Collapse)AuthorAgeFilesLines
* ShellPkg/UefiDpLib: Support execution breakCinnamon Shia2016-03-084-25/+110
| | | | | | | | | | Support UEFI shell execution break. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Cinnamon Shia <cinnamon.shia@hpe.com> Reviewed-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Samer EL-Haj-Mahmoud <elhaj@hpe.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Merge Ping6 and Ifconfig6 tools to Shell command.Zhang, Lubo2016-03-089-4/+3478
| | | | | | | | | | | | | | According to the new Shell spec, we add Network2 profile and merge Ping6 and Ifconfig6 tools to Shell command. Cc: Carsey Jaben <jaben.carsey@intel.com> Cc: Wu Jiaxin <jiaxin.wu@intel.com> Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Zhang Lubo <lubo.zhang@intel.com> Reviewed-By: Jaben Carsey <Jaben.carsey@intel.com> Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>
* ShellPkg: Fix smbiosview decode of PCIe Extended CapabilitiesSamer El-Haj-Mahmoud2016-03-042-4/+12
| | | | | | | | | | Fix SMBIOSVIEW decode of the HeaderLog fields of the PCIe AER structure . The PCIe 2.1 Base Specification, section 7.10, lists this as 16 bytes, or 4 DWORDs. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Samer El-Haj-Mahmoud <elhaj@hpe.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Update 'ifconfig -r' implementationJiaxin Wu2016-03-031-5/+26
| | | | | | | | | | | | | | | | | | | | | | | | This patch is used to update ifconfig -r implementation to sync with UEFI Shell 2.2. option -r means to reconfigure all or specified interface, and set DHCP policy. If specified interface is already set to DHCP, then refresh the IPv4 configuration. If the interface name is specified with '-r', DHCP DORA process will be triggered by the policy transition (static -> dhcp). Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Cc: Carsey Jaben <jaben.carsey@intel.com> Cc: El-Haj-Mahmoud Samer <samer.el-haj-mahmoud@hpe.com> Cc: Subramanian Sriram <sriram-s@hpe.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com> Reviewed-by: Sriram Subramanian <sriram-s@hpe.com> Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com> Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
* ShellPkg: Increase reallocation size for temp memory filesJim_Dailey@Dell.com2016-03-031-4/+6
| | | | | | | | | | | | | | If data of any real size were to be piped from one command to another, an inordinate amount of time could be taken up by reallocating memory that is only 10 bytes bigger than what is currently needed. Also, this could cause unwelcome memory fragmentation. Added a define to control how much memory is reallocated beyond that which is currently needed. Set it to 1K vs. the original 10 bytes. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <jim_dailey@dell.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Do not write the UNICODE BOM on ConOut.Jim_Dailey@Dell.com2016-03-031-2/+4
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <jim_dailey@dell.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Add FileSize member to shell memory file structure.Jim_Dailey@Dell.com2016-03-031-3/+6
| | | | | | | | | | | | | | | The shell uses the memory file structure to manage temporary files in memory that support piping of output from one command into the the input of another command. The BufferSize member is the size of the internal buffer, not the size of the data that was written to the file. So, it was possible to read beyond the EOF of these files as reads used BufferSize. Now FileSize tracks the actual size of these files (the number of bytes written, not the number of bytes available in the buffer), and the reads use this member. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <jim_dailey@dell.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Revert git 'd6cf1af9' fixJiaxin Wu2016-03-021-103/+14
| | | | | | | | | | | | | | | 'd6cf1af9' is associated with '3d0a49ad' commit. So, this patch is used to respond the revert for '3d0a49ad' to adapt the Ipv4 config policy update. Cc: Subramanian Sriram <sriram-s@hpe.com> Cc: El-Haj-Mahmoud Samer <samer.el-haj-mahmoud@hpe.com> Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com> Reviewed-by: Fu Siyuan <siyuan.fu@intel.com> Reviewed-by: Ye Ting <ting.ye@intel.com>
* ShellPkg: Don't strip BOM when piping UCS2 data to a UEFI appJim_Dailey@Dell.com2016-03-011-11/+6
| | | | | | | | | | If the BOM is stripped from StdIn, then an app that duplicates StdIn will not be able to duplicate, say, a UCS2 file that was piped into it (the output file it creates would not start with a BOM). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <jim_dailey@dell.com> Reviewed-by: Jaben Carsey <Jaben.Carsey@intel.com>
* ShellPkg: Fix unexpected behavior of mouse cursor in Editor.Qiu Shumin2016-02-271-3/+4
| | | | | | | | | | | USB mouse cursor cannot move unless the left button is down. The patch refresh the FileBuffer of Editor every time when the 'MainEditorRefresh' is called to fix this bug. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com>
* ShellPkg: Support finding help message embedded in resource section.Qiu Shumin2016-02-243-17/+259
| | | | | | | | | | | | | | | | | | | | | | | | UEFI Shell scandalizes the help message in spec level so that a standalone UEFI shell application can never get "-?" switch, instead the Shell core (interpreter) detects the "-?" and finds .MAN file for that shell application in certain spec defined paths, then show the help extracted from that .MAN file. But it means distributing a UEFI shell application not only means distributing a .EFI file but also distributing a .MAN file. If the text formatted .MAN file is corrupted (edited by user by mistake), or is missing (deleted by user by mistake), no help will be shown to user. So this patch enhance the Shell to make it support finding help message imbedded in resource section of application image. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
* ShellPkg: Do NULL pointer check before the pointer is used.Qiu Shumin2016-02-231-1/+1
| | | | | | | | Do NULL pointer check before the pointer is used to avoid dereferenced. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Fix the last command doesn't work in a script.Qiu Shumin2016-02-191-1/+4
| | | | | | | | | | When the last line in a script file is not an empty line the Shell will not execute the command in the last line. The patch refine the logic in function 'ShellFileHandleReturnLine' and fix the issue. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com>
* ShellPkg: Do NULL pointer check before the pointer is used.Qiu Shumin2016-02-181-1/+5
| | | | | | | | | The pointer 'FileInterface->Buffer' returned from 'AllocateZeroPool' in function 'CreateFileInterfaceMem' may be NULL and will be dereferenced at the following code. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg/UefiDpLib: Refine the code of locating all handles in DpTrace.c.Cinnamon Shia2016-02-181-31/+9
| | | | | | | | | | Replace gBS->LocateHandle with gBS->LocateHandleBuffer Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Cinnamon Shia <cinnamon.shia@hpe.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Samer El-Haj-Mahmoud <elhaj@hpe.com>
* ShellPkg: complete previous incomplete patchJim Dailey2016-02-101-29/+13
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <Jim_Dailey@Dell.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* Merge branch 'master' of https://github.com/tianocore/edk2Jaben Carsey2016-02-101-13/+29
|\
| * ShellPkg: Fix ASCII and UNICODE file pipes.jaben carsey2016-02-084-35/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix various errors when piping a UNICODE or ASCII file to a simple shell application that reads standard input and writes it to standard output. 1) When the memory file is created by CreateFileInferfaceMem() to capture the pipe output, no UNICODE BOM is written to the memory file. Later, when the memory file is read by the application using ShellFileHandleReadLine(), the function indicates that the file is ASCII because there is no BOM. 2) If the file is piped as ASCII, the ASCII memory image is not correctly created by FileInterfaceMemWrite() as each ASCII character is followed by '\0' in the image (when the ASCII data is written to the memory image, the file position should only be incremented by half the buffer size). 3) ShellFileHandleReadLine() does not read ASCII files correctly (writes to Buffer need to be cast as CHAR8*). 4) FileInterfaceMemRead() and FileInterfaceMemWrite() as somewhat hard to read and difficult to debug with certain tools due to the typecasting of This. Added a local variable (MemFile) of the correct type to these functions and used it instead of This. Enhancement: ShellFileHandleReadLine() now returns EFI_END_OF_FILE when appropriate. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <jim_dailey@dell.com> reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* | ShellPkg: ShellFileHandleReadLine must return UCS2 lines.Jim Dailey2016-02-101-31/+26
| | | | | | | | | | | | | | | | | | | | | | | | An earlier change had this function returning the type of lines that were in the file being read (ASCII or UCS2). The way it is used, UCS2 output is expected, even when the file being read is ASCII. This change restores that behavior and documents it. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <Jim_Dailey@Dell.com> Tested-by: Ryan Harkin <ryan.harkin@linaro.org> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* | ShellPkg: Fix ASCII and UNICODE file pipes.jaben carsey2016-02-094-35/+71
|/ | | | | | | | | | | | | | | | | | Fix various errors when piping a UNICODE or ASCII file to a simple shell application that reads standard input and writes it to standard output. 1) When the memory file is created by CreateFileInferfaceMem() to capture the pipe output, no UNICODE BOM is written to the memory file. Later, when the memory file is read by the application using ShellFileHandleReadLine(), the function indicates that the file is ASCII because there is no BOM. 2) If the file is piped as ASCII, the ASCII memory image is not correctly created by FileInterfaceMemWrite() as each ASCII character is followed by '\0' in the image (when the ASCII data is written to the memory image, the file position should only be incremented by half the buffer size). 3) ShellFileHandleReadLine() does not read ASCII files correctly (writes to Buffer need to be cast as CHAR8*). 4) FileInterfaceMemRead() and FileInterfaceMemWrite() as somewhat hard to read and difficult to debug with certain tools due to the typecasting of This. Added a local variable (MemFile) of the correct type to these functions and used it instead of This. Enhancement: ShellFileHandleReadLine() now returns EFI_END_OF_FILE when appropriate. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jim Dailey <jim_dailey@dell.com> reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
* ShellPkg: Refine the code to avoid use a constant number as offset.Qiu Shumin2016-01-261-1/+1
| | | | | | | | | | | Refine the code to use 'sizeof(EFI_LOAD_OPTION)' as offset in buffer to get 'description' instead of using a constant number. This change makes the code more readable. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19746 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: UefiShellBcfgCommandLib: bump VERSION_STRINGLaszlo Ersek2016-01-211-1/+1
| | | | | | | | | | | | | | The changes due to the previous patches should be reflected in a higher minor version number. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Suggested-by: Jaben Carsey <jaben.carsey@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19719 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): print optional data with DumpHex()Laszlo Ersek2016-01-211-14/+7
| | | | | | | | | | | | | The DumpHex() function produces very friendly output (known from DMPSTORE, for example); let's use it with "BCFG -v" as well. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19718 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: elevate DumpHex() from Debug1-internal to generic-internalLaszlo Ersek2016-01-216-88/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The UEFI Shell specification classifies shell commands into various shell levels / profiles. Currently the DumpHex() internal function is only used by commands that belong to the Debug1 profile exclusively (i.e., they are not required to be present in other than Debug1 profiles): - SMBIOSVIEW - PCI - DMPSTORE - DMEM - DBLK In the next patch, we'd like to call DumpHex() from BCFG as well. However, BCFG is not only required to be present in the Debug1 profile; the Install1 profile contains BCFG as well. For this reason, move DumpHex() from UefiShellDebug1CommandsLib to the more generic UefiShellCommandLib, which "Provides interface to shell internal functions for shell commands". The matching header file is "ShellPkg/Include/Library/ShellCommandLib.h". Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19717 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): fix ShellPrintEx() call siteLaszlo Ersek2016-01-211-1/+0
| | | | | | | | | | | | | | | | | This is likely a copy & paste error from the preceding ShellPrintHiiEx() function call. ShellPrintEx() takes no Language parameter, so remove the NULL argument, which is currently misinterpreted as a format string. This bug prevents the hexdump of optional data even when -v is passed to BCFG, and optional data exist. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19716 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): fix reporting of OptionalDataLaszlo Ersek2016-01-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | In this cleaned up form of BcfgDisplayDump(), it is easier to see that the OptionalDataOffset <= BufferSize expression, used to report whether optional data are *absent*, is incorrect. For any well-formed EFI_LOAD_OPTION, this inequality always holds. Optional data are present exactly if OptionalDataOffset < BufferSize therefore the absence condition is the negation of the above, OptionalDataOffset >= BufferSize This patch fixes the bug where BCFG always reports "Optional- N", even if optional data exist. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19715 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): calculate OptionalDataOffset explicitlyLaszlo Ersek2016-01-211-2/+8
| | | | | | | | | | | | | | Eliminate some more repeated pointer arithmetic. This patch too is only refactoring. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19714 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): eliminate FilePathList duplicationLaszlo Ersek2016-01-211-10/+3
| | | | | | | | | | | | | | | | Copying and releasing each EFI_LOAD_OPTION.FilePathList under the name DevPath is wasteful -- we only need FilePathList for a single conversion to text. Do it directly from the EFI_LOAD_OPTION object. This patch is not supposed to change observable behavior. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19713 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): call Description[Size] by nameLaszlo Ersek2016-01-211-5/+10
| | | | | | | | | | | | | | Introduce two more helper variables to avoid repeated pointer arithmetic. This patch is not supposed to change behavior. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19712 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): address FilePathListLength by nameLaszlo Ersek2016-01-211-5/+6
| | | | | | | | | | | | | | | | The Buffer variable points at the beginning of an EFI_LOAD_OPTION structure. We might as well address the "FilePathListLength" member by name, rather than with *(UINT16*)(Buffer+4). This patch is not supposed to change behavior. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19711 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): enforce minimum size for Boot#### and co.Laszlo Ersek2016-01-212-0/+20
| | | | | | | | | | | | | | | | | | "3.1.1 Boot Manager Programming" in the UEFI 2.5 spec mandates that Boot#### and similar options contain EFI_LOAD_OPTION structures. The EFI_LOAD_OPTION structure encodes the fixed initial part of the payload, and we can (and should) use it to enforce a minimum size for variable contents. This patch is meant as a safety improvement. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19710 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): accumulate errorsLaszlo Ersek2016-01-211-2/+7
| | | | | | | | | | | | | | | | Don't exit the command immediately when a variable access fails; continue processing after printing the error message. Let the final return status reflect any encountered errors. This patch is intended as a functional improvement. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19709 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): hoist NULL-init of DevPath[String]Laszlo Ersek2016-01-211-6/+4
| | | | | | | | | | | | | | | It will help with error handling if we move these initializations near the top of the loop body. This patch is not supposed to change behavior. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19708 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: UefiShellBcfgCommandLib: drop unused string tokensLaszlo Ersek2016-01-211-3/+0
| | | | | | | | | | | | | STR_GEN_PROBLEM_VAL, STR_GEN_TOO_MANY, and STR_BCFG_LOCATION_RANGE are not used in the C source code. Remove them to decrease clutter. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19707 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: BcfgDisplayDump(): update whitespace & layoutLaszlo Ersek2016-01-211-10/+10
| | | | | | | | | | | | | | This patch incurs no functional changes, it just modifies some whitespace, so we can separate these non-functional changes from the functional changes in the next patches. Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Ryan Harkin <ryan.harkin@linaro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19706 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg UefiDpLib: Use Image->FilePath to get name for SMM driversStar Zeng2016-01-191-3/+11
| | | | | | | | | | | | | | | | | | This enhancement is to use the FilePath field in the loaded image protocol to find the name of an image as a fallback for when the loaded image device path protocol is not installed on the image handle. This is necessary because the SMM core does not install the loaded image device path protocol, so DP was displaying "Unknown Driver Name" for every SMM driver. Cc: Liming Gao <liming.gao@intel.com> Cc: Jaben Carsey <jaben.carsey@intel.com> Cc: Shumin Qiu <shumin.qiu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19683 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Add NOOPT target in ShellPkg.dscHao Wu2016-01-191-2/+2
| | | | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19679 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Update 'dh' command to reflect correct driver handle informationTapan Shah2016-01-151-2/+2
| | | | | | | | | | | 'dh' command shows Supported EFI Specification Version value as DriverVersion. Changing it to 'SupportedEfiSpecVersion' to provide more accurate information. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Tapan Shah <tapandshah@hpe.com> Reviewed-by: Samer El-Haj-Mahmoud <elhaj@hpe.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19648 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Clean-up 'map' command error message handlingTapan Shah2016-01-071-41/+40
| | | | | | | | | | Refactor 'map' command error handling code and add standard error message Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Tapan Shah <tapandshah@hpe.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19616 6f19259b-4bc3-4df7-8a09-765794883524
* Revert "ShellPkg : Add UEFI_APPLICATION module type to ↵Laszlo Ersek2016-01-061-2/+1
| | | | | | | | | | | | | | | | | | | | | | UefiShellInstall1CommandsLib.inf" SVN r19585 broke the OVMF build: > ShellPkg/Library/UefiShellInstall1CommandsLib/UefiShellInstall1CommandsLib.inf(20): > error 3001: MODULE_TYPE UEFI_DRIVER UEFI_APPLICATION is not supported > for EDK II, valid values are: > BASE SEC PEI_CORE PEIM DXE_CORE DXE_DRIVER DXE_RUNTIME_DRIVER > DXE_SAL_DRIVER DXE_SMM_DRIVER UEFI_DRIVER UEFI_APPLICATION USER_DEFINED > SMM_CORE Revert the patch. Reported-by: Laszlo Ersek <lersek@redhat.com> Suggested-by: "El-Haj-Mahmoud, Samer" <samer.el-haj-mahmoud@hpe.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19610 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Make 'alias' can display a single alias name.Qiu Shumin2016-01-061-3/+16
| | | | | | | | | | When we run command "alias cat" Shell print out "alias: Too few arguments". This patch makes value of single alias name can be displayed. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19608 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix Shell assert when mv a file to a NULL target.Qiu Shumin2016-01-061-2/+2
| | | | | | | | | | When run command 'mv file ' the Shell assert. The patch refined the length of the buffer to fix this bug. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19607 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg : Add UEFI_APPLICATION module type to UefiShellInstall1CommandsLib.infSamer El-Haj-Mahmoud2016-01-051-1/+2
| | | | | | | | | | | | Using UEFI_APPLICATION for all Shell app and libraries allows the use of different compiler flags for the Shell application itself and for other applications that are built separately that use Shell libraries. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Samer El-Haj-Mahmoud <elhaj@hpe.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19585 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix memory leak in function 'EfiShellSetCurDir' and 'EfiShellSetMap'.Yao Jiewen2015-12-251-0/+9
| | | | | | | | | | Cc: Ruiyu Ni <ruiyu.ni@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19529 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix memory leak in function'ShellCommandConsistMappingInitialize'.Yao Jiewen2015-12-251-0/+1
| | | | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19528 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix memory leak in function ↵Yao Jiewen2015-12-251-0/+3
| | | | | | | | | | | 'ShellCommandCreateInitialMappingsAndPaths'. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19527 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix memory leak in function'ShellCommandRunHelp'.Yao Jiewen2015-12-251-0/+2
| | | | | | | | | | When run help command Shell may have memory leak. This patch fix this bug. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19526 6f19259b-4bc3-4df7-8a09-765794883524
* Subject: [PATCH 5/9] ShellPkg: Fix memory leak in ↵Qiu Shumin2015-12-251-0/+2
| | | | | | | | | | function'ManBufferFindSections'. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Yao Jiewen <Jiewen.Yao@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19525 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix memory leak in 'ShellOpenFileByName'.Yao Jiewen2015-12-251-1/+6
| | | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19524 6f19259b-4bc3-4df7-8a09-765794883524
* ShellPkg: Fix memory leak in 'InternalShellExecuteDevicePath'.Yao Jiewen2015-12-241-0/+1
| | | | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com> Reviewed-by: Qiu Shumin <shumin.qiu@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19523 6f19259b-4bc3-4df7-8a09-765794883524