Refine code to follow coding style.

Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com>

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13595 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
ydong10 2012-08-07 00:44:28 +00:00
parent 33026ccf33
commit cd0842dc82
1 changed files with 14 additions and 6 deletions

View File

@ -19,6 +19,14 @@
#define INIT_DATA_BUFFER_SIZE 1024
#define INIT_ATTS_BUFFER_SIZE 64
/**
Base on the input attribute value to return the attribute string.
@param[in] Atts The input attribute value
@param[in,out] RetString The buffer to save the attribute string.
@retval The attribute string info.
**/
CONST CHAR16 *
EFIAPI
GetAttrType (
@ -28,21 +36,21 @@ GetAttrType (
{
StrCpy(RetString, L"");
if (Atts & EFI_VARIABLE_NON_VOLATILE) {
if ((Atts & EFI_VARIABLE_NON_VOLATILE) != 0) {
StrCat(RetString, L"+NV");
}
if (Atts & EFI_VARIABLE_RUNTIME_ACCESS) {
if ((Atts & EFI_VARIABLE_RUNTIME_ACCESS) != 0) {
StrCat(RetString, L"+RS+BS");
} else if (Atts & EFI_VARIABLE_BOOTSERVICE_ACCESS) {
} else if ((Atts & EFI_VARIABLE_BOOTSERVICE_ACCESS) != 0) {
StrCat(RetString, L"+BS");
}
if (Atts & EFI_VARIABLE_HARDWARE_ERROR_RECORD) {
if ((Atts & EFI_VARIABLE_HARDWARE_ERROR_RECORD) != 0) {
StrCat(RetString, L"+HR");
}
if (Atts & EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS) {
if ((Atts & EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS) != 0) {
StrCat(RetString, L"+AW");
}
if (Atts & EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS) {
if ((Atts & EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS) != 0) {
StrCat(RetString, L"+AT");
}