summaryrefslogtreecommitdiffstats
path: root/ArmPlatformPkg/Bds/BdsHelper.c
Commit message (Collapse)AuthorAgeFilesLines
* ArmPlatformPkg/Bds: Change the GetHIInput/EditHIInput to always return a ↵Ronald Cron2014-07-291-24/+35
| | | | | | | | | | | | | | | valid IP address The new functions never return a invalid IP address. The user would be asked again if the IP address is mal-formed. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ronald Cron <ronald.cron@arm.com> Reviewed-By: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15714 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Getting and editing IP addressesRonald Cron2014-07-151-23/+68
| | | | | | | | | | | | | | | | Reworked GetHIInputIP() function to use "NetLibStrToIp4()" library function to parse the IPv4 address instead of doing it by itself. Added function EditHIInputIP() in BdsHelper.c to edit an IPv4 address. To be used when updating a tftp boot option. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ronald Cron <ronald.cron@arm.com> Reviewed-By: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15660 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Introduced helper function to detect if an Ascii/Unicode ↵Olivier Martin2014-04-111-1/+77
| | | | | | | | | | | | | | | | string is printable Some limitations: - it only supports unicode string that use ASCII character (< 0x100) - single character ASCII strings are interpreted as Unicode string - string cannot be longer than 2 x BOOT_DEVICE_OPTION_MAX (600 bytes) Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15455 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Add support to handle Unicode parametersOlivier Martin2014-04-111-0/+15
| | | | | | | | | | | | Most UEFI applications expect unicode string parameter. This change is allows to support Ascii or Unicode strings. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15450 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: stop inputting more characters when string is fullRyan Harkin2014-03-121-5/+3
| | | | | | | | | | | | | | | | | | | | | | If EditHIInputStr() is called, say with a MaxCmdLine of 2, the user is currently allowed to enter 2 characters. If the second character is a carriage return/line feed, this is substituted with a NULL and the function returns. If the second character is a regular character, the loop terminated and the function returns. However, the buffer has not been NULL terminated. This patch prevents the user from entering a regular character as the final character and ensures that the only way out of the input is by pressing ESC or ENTER (or equivalent). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ryan Harkin <ryan.harkin@linaro.org> Reviewed-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15325 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/BdsLib: Let the user press enter when inputting booleansOlivier Martin2014-02-121-2/+4
| | | | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15236 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Make ".EFI" files recognizable as EFI applicationsLeif Lindholm2013-06-211-1/+2
| | | | | | | | | | | | | Currently, only ".efi" files are recognized as valid ARM UEFI applications by BDS. This patch also makes ".EFI" files recognised. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org> Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14437 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Moved the PrintLib() after forcing the last character to ↵Olivier Martin2013-06-191-3/+3
| | | | | | | | | | | | be null That should prevent the risk of buffer overflow. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14430 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Fixed potential overflow in EditHIInputStr()Ryan Harkin2013-05-291-2/+9
| | | | | | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ryan Harkin <ryan.harkin@linaro.org> Signed-off: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14393 6f19259b-4bc3-4df7-8a09-765794883524
* ARM Packages: Fixed line endingsoliviermartin2013-01-251-317/+317
| | | | | | | | | This large code change only modifies the line endings to be CRLF to be compliant with the EDK2 coding convention document. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14088 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg: Minor code changes (comments, misspellings, coding stylei, ↵oliviermartin2012-02-281-2/+1
| | | | | | | | | | | | | | | line endings) - Fixed misspellings - Updated Copyright - Remove unused sections in INF file - Fixed incorrect commentsi - Fixed coding style - Fixed line endings (CRLR) git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13052 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg: Coding style (minor changes)oliviermartin2011-11-011-1/+1
| | | | git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12625 6f19259b-4bc3-4df7-8a09-765794883524
* Arm Packages: Fixed coding style/Line endings to follow EDK2 coding conventionoliviermartin2011-09-221-2/+2
| | | | | | | | | | | Arm Packages: Fixed mispelling Arm Packages: Reduced warnings all over the code git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12407 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPkg/BdsLib: Move some functions used to create/update BDS Boot Entry from ↵oliviermartin2011-09-091-61/+3
| | | | | | | | | | ArmPlatformPkg/Bds to ArmPkg/BdsLib These functions can be reused by any EFI application to add/update a BDS Boot Entry. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12314 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Add a signature in front of the Boot Argument propoer to ↵oliviermartin2011-09-091-0/+31
| | | | | | | | | | | | | | | this Bds Each application loader has its own OptionalData format. To avoid to start a Boot Entry that has not been created by ArmPlatform/Bds a signature has been added to the OptionalData. ArmPlatformPkg/Bds: Rename some internal structure from BDS_* to ARM_BDS_* git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12311 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Get User inputs in Unicodeoliviermartin2011-09-091-26/+64
| | | | | | | | | | The user input was getting in Ascii and converted later to Unicode when required. In this change, the user inputs are caught in Unicode and converted to Ascii only when needed. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12310 6f19259b-4bc3-4df7-8a09-765794883524
* ArmPlatformPkg/Bds: Upgrade the BDS to be more conformed to the UEFI ↵oliviermartin2011-06-111-0/+307
Specification The UEFI Specification defines some requirement related to the Boot Manager. This new version of the BDS support most of the features: - TimeOut, BootNext, BootOrder, Boot### environment variable for boot device selection - ConOut. ConIn, ConErr environment variables for console intialization - Boot EFI application defined by a Device Path - Support removable devices - Support FileSystem, MemMap, PXE and TFTP boot devices git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11800 6f19259b-4bc3-4df7-8a09-765794883524