diff options
author | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-05-14 06:07:07 +0000 |
---|---|---|
committer | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-05-14 06:07:07 +0000 |
commit | ea7cb08c0afc7ad5dd9ed7176cd062385df8fa8b (patch) | |
tree | febbcc3c37da1e44b5405f5c5085e93be96f8b48 /MdeModulePkg/Universal/Disk/PartitionDxe | |
parent | d29270810c282aa3b7938b42a3e6efbc08014a91 (diff) | |
download | edk2-ea7cb08c0afc7ad5dd9ed7176cd062385df8fa8b.zip edk2-ea7cb08c0afc7ad5dd9ed7176cd062385df8fa8b.tar.gz edk2-ea7cb08c0afc7ad5dd9ed7176cd062385df8fa8b.tar.bz2 |
Minor coding style adjustment for DiskIo, Partition, English and Ebc modules.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5200 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Universal/Disk/PartitionDxe')
-rw-r--r-- | MdeModulePkg/Universal/Disk/PartitionDxe/ElTorito.c | 2 | ||||
-rw-r--r-- | MdeModulePkg/Universal/Disk/PartitionDxe/Gpt.c | 23 | ||||
-rw-r--r-- | MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c | 2 | ||||
-rw-r--r-- | MdeModulePkg/Universal/Disk/PartitionDxe/Partition.h | 28 |
4 files changed, 25 insertions, 30 deletions
diff --git a/MdeModulePkg/Universal/Disk/PartitionDxe/ElTorito.c b/MdeModulePkg/Universal/Disk/PartitionDxe/ElTorito.c index f208194..ce33050 100644 --- a/MdeModulePkg/Universal/Disk/PartitionDxe/ElTorito.c +++ b/MdeModulePkg/Universal/Disk/PartitionDxe/ElTorito.c @@ -166,7 +166,7 @@ PartitionInstallElToritoChildHandles ( Check += CheckBuffer[Index];
}
- if (Check & 0xFFFF) {
+ if ((Check & 0xFFFF) != 0) {
DEBUG ((EFI_D_ERROR, "EltCheckBootCatalog: El Torito boot catalog header checksum failed\n"));
continue;
}
diff --git a/MdeModulePkg/Universal/Disk/PartitionDxe/Gpt.c b/MdeModulePkg/Universal/Disk/PartitionDxe/Gpt.c index ef3c766..6d3abae 100644 --- a/MdeModulePkg/Universal/Disk/PartitionDxe/Gpt.c +++ b/MdeModulePkg/Universal/Disk/PartitionDxe/Gpt.c @@ -79,7 +79,7 @@ PartitionRestoreGptTable ( /**
- Restore Partition Table to its alternate place
+ Restore Partition Table to its alternate place.
(Primary -> Backup or Backup -> Primary)
@param[in] PartHeader Partition table header structure
@@ -97,7 +97,7 @@ PartitionCheckGptEntry ( /**
- Checks the CRC32 value in the table header
+ Checks the CRC32 value in the table header.
@param MaxSize Max Size limit
@param Size The size of the table
@@ -116,7 +116,7 @@ PartitionCheckCrcAltSize ( /**
- Checks the CRC32 value in the table header
+ Checks the CRC32 value in the table header.
@param MaxSize Max Size limit
@param Hdr Table to check
@@ -133,7 +133,7 @@ PartitionCheckCrc ( /**
- Updates the CRC32 value in the table header
+ Updates the CRC32 value in the table header.
@param Size The size of the table
@param Hdr Table to update
@@ -147,7 +147,7 @@ PartitionSetCrcAltSize ( /**
- Updates the CRC32 value in the table header
+ Updates the CRC32 value in the table header.
@param Hdr Table to update
@@ -619,7 +619,7 @@ Done: /**
- Restore Partition Table to its alternate place
+ Restore Partition Table to its alternate place.
(Primary -> Backup or Backup -> Primary)
@param[in] PartHeader Partition table header structure
@@ -681,7 +681,7 @@ PartitionCheckGptEntry ( /**
- Updates the CRC32 value in the table header
+ Updates the CRC32 value in the table header.
@param Hdr Table to update
@@ -696,7 +696,7 @@ PartitionSetCrc ( /**
- Updates the CRC32 value in the table header
+ Updates the CRC32 value in the table header.
@param Size The size of the table
@param Hdr Table to update
@@ -707,7 +707,6 @@ PartitionSetCrcAltSize ( IN UINTN Size,
IN OUT EFI_TABLE_HEADER *Hdr
)
-
{
UINT32 Crc;
@@ -718,7 +717,7 @@ PartitionSetCrcAltSize ( /**
- Checks the CRC32 value in the table header
+ Checks the CRC32 value in the table header.
@param MaxSize Max Size limit
@param Hdr Table to check
@@ -738,7 +737,7 @@ PartitionCheckCrc ( /**
- Checks the CRC32 value in the table header
+ Checks the CRC32 value in the table header.
@param MaxSize Max Size limit
@param Size The size of the table
@@ -768,7 +767,7 @@ PartitionCheckCrcAltSize ( return FALSE;
}
- if (MaxSize && Size > MaxSize) {
+ if ((MaxSize != 0) && (Size > MaxSize)) {
DEBUG ((EFI_D_ERROR, "CheckCrc32: Size > MaxSize\n"));
return FALSE;
}
diff --git a/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c b/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c index c95a866..68b389a 100644 --- a/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c +++ b/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c @@ -93,7 +93,7 @@ PartitionValidMbr ( }
}
//
- // Non of the regions overlapped so MBR is O.K.
+ // None of the regions overlapped so MBR is O.K.
//
return MbrValid;
}
diff --git a/MdeModulePkg/Universal/Disk/PartitionDxe/Partition.h b/MdeModulePkg/Universal/Disk/PartitionDxe/Partition.h index 9d6477c..6dcbd9b 100644 --- a/MdeModulePkg/Universal/Disk/PartitionDxe/Partition.h +++ b/MdeModulePkg/Universal/Disk/PartitionDxe/Partition.h @@ -15,8 +15,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. **/
-#ifndef _PARTITION_H
-#define _PARTITION_H
+#ifndef _PARTITION_H_
+#define _PARTITION_H_
#include <Uefi.h>
#include <Protocol/BlockIo.h>
@@ -150,10 +150,10 @@ PartitionDriverBindingStart ( EFI_STATUS
EFIAPI
PartitionDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
);
//
@@ -313,12 +313,11 @@ PartitionInstallChildHandle ( IN EFI_BLOCK_IO_PROTOCOL *ParentBlockIo,
IN EFI_DEVICE_PATH_PROTOCOL *ParentDevicePath,
IN EFI_DEVICE_PATH_PROTOCOL *DevicePathNode,
- IN UINT64 Start,
- IN UINT64 End,
+ IN EFI_LBA Start,
+ IN EFI_LBA End,
IN UINT32 BlockSize,
IN BOOLEAN InstallEspGuid
- )
-;
+ );
/**
Install child handles if the Handle supports GPT partition structure.
@@ -341,8 +340,7 @@ PartitionInstallGptChildHandles ( IN EFI_DISK_IO_PROTOCOL *DiskIo,
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath
- )
-;
+ );
/**
Install child handles if the Handle supports El Torito format.
@@ -366,8 +364,7 @@ PartitionInstallElToritoChildHandles ( IN EFI_DISK_IO_PROTOCOL *DiskIo,
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath
- )
-;
+ );
/**
Install child handles if the Handle supports MBR format.
@@ -390,8 +387,7 @@ PartitionInstallMbrChildHandles ( IN EFI_DISK_IO_PROTOCOL *DiskIo,
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath
- )
-;
+ );
typedef
EFI_STATUS
|