This adds the new APIs for UEFI Shell 2.1 and makes a new structure for shell implementations that are conformant to this new spec.  It does not affect existing implementations.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15752 6f19259b-4bc3-4df7-8a09-765794883524
ShellPkg: Add Dynamic GUID registration into the current GUID<->String conversion process

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15753 6f19259b-4bc3-4df7-8a09-765794883524
This searches for handles that produce the dynamic command protocol after searching the commands compiled into the shell.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Eugene Cohen <eugene@hp.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com> 

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15754 6f19259b-4bc3-4df7-8a09-765794883524
Updates the logic to allow RM and CP to have silent/quiet mode work successfully.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Lee Rosenbaum <lee.g.rosenbaum@intel.com> 

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15755 6f19259b-4bc3-4df7-8a09-765794883524
Updates the logic to allow help to ouput help information from a dynamic shell command

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Lee Rosenbaum <lee.g.rosenbaum@intel.com> 

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15756 6f19259b-4bc3-4df7-8a09-765794883524
Updates the logic to allow DmpStore to specify a name independent of specifying a GUID.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15757 6f19259b-4bc3-4df7-8a09-765794883524
Updates the total size logic and the SFO output per UEFI Shell 2.1 changes

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15758 6f19259b-4bc3-4df7-8a09-765794883524
Fix the use of ASSERT and other fixes to memory allocation failures (like free before return for errors)

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15759 6f19259b-4bc3-4df7-8a09-765794883524
Updates the logic to allow devices to support SFO output mode

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15760 6f19259b-4bc3-4df7-8a09-765794883524
ShellPkg: Remove double typedef for same struct

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Andrew Fish <afish@apple.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15761 6f19259b-4bc3-4df7-8a09-765794883524
Eliminate duplicated file GUID.
Eliminate duplicate GUID definition.
Do explicit data cast.
Use StrnCpy instead of StrCpy.
Update GCC assembly.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed off by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed by: Eric Dong <eric.dong@intel.com>
Reviewed by: Liming Gao <liming.gao@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15762 6f19259b-4bc3-4df7-8a09-765794883524
ShellPkg: add size cast to bit operations

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15763 6f19259b-4bc3-4df7-8a09-765794883524
Updates the UEFI Shell to produce the new protocol with additional 4 functions.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>
Reviewed by: Daryl McDaniel <daryl.mcdaniel@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15764 6f19259b-4bc3-4df7-8a09-765794883524
StdLib: The formatting for double float values, within the gdtoa library, is improper.

When running Enquire.efi, several errors similar to the following are produced:
Maximum exponent = 128
Maximum number = 3.40282347e+38

*** WARNING: Possibly bad output from printf above
    expected value around 3.40282347e38, bit pattern:
    11111111 11111111 01111111 01111111
    sscanf gave           -inf, bit pattern:
    00000000 00000000 10000000 11111111
    difference= inf

Overflow doesn’t seem to generate a trap

The memory allocation tests will also fail, sometimes leaving all available memory consumed.

The correct output in the above example is:
Maximum exponent = 128
Maximum number = 3.40282347e+38
Overflow doesn't seem to generate a trap

The root cause is that all operations on values of Long or ULong type, within the gdtoa library, must be 32-bit operations.  A previous change replaced the Long and ULong definitions with INTN and UINTN, respectively.  While this is correct for a lot of Linux and NetBSD code, it was not correct for this library.

This fix reverts the definitions of ULong and Long back to 32-bit types.
A descriptive comment has also been added to the U union.
Additional white-space has been added to tidy up the definitions of the word0 and word1 macros.

Verified with Enquire.efi and the ISO/IEC C Library compliance Validation Suite.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Daryl McDaniel <daryl.mcdaniel@intel.com>
Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15765 6f19259b-4bc3-4df7-8a09-765794883524
Clean up code.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed off by: Jiewen Yao <jiewen.yao@intel.com>
Reviewed by: Eric Dong <eric.dong@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15766 6f19259b-4bc3-4df7-8a09-765794883524
Fix OpensslLib build issue for ARM. The changes are:
The changes are:
  1. Add RVCT ARM build target
  2. Add suppression of warnings to get openssl building (1295,550,1293,111,68,177,223,144,513,188)
  3. Remove architectures that RVCT cannot build for (IA32, X64, and IPF)
  4. Add the -DOPENSSL_NO_MD2 flag to prevent link errors from MD2 references; the comments in the .inf assumes that this flag exists but it wasn’t actually set

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eugene Cohen <eugene@hp.com>
Reviewed-by: Ye Ting <ting.ye@intel.com>
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Long Qin <qin.long@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15767 6f19259b-4bc3-4df7-8a09-765794883524
Clean up code.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed off by: Long Qin <qin.long@intel.com>
Reviewed by: Eric Dong <eric.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15768 6f19259b-4bc3-4df7-8a09-765794883524
Add type cast for better coding style.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qiu Shumin <shumin.qiu@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15769 6f19259b-4bc3-4df7-8a09-765794883524
1) Add type cast for better coding style.
2) replace StrCpy() usage in Variable driver with StrnCpy().

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15770 6f19259b-4bc3-4df7-8a09-765794883524
ShellPkg: Refactor string manipulation in cp command

This patch replaces StrCpy with StrnCpy or refactors out the usage of StrCpy through some other means.
This patch replaces StrCat with StrnCat or refactors out the usage of StrCat through some other means.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jaben Carsey <jaben.carsey@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15771 6f19259b-4bc3-4df7-8a09-765794883524