diff options
author | vanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-11-07 09:05:44 +0000 |
---|---|---|
committer | vanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-11-07 09:05:44 +0000 |
commit | a7cc3d261c0572739c0587af1a339237b7947159 (patch) | |
tree | a92e7b95b5c120d196a1084c62971eb5927cd478 /MdePkg/Include | |
parent | 378871863f99d1fbf1886d7c3ed5f9955b1556a7 (diff) | |
download | edk2-platforms-a7cc3d261c0572739c0587af1a339237b7947159.tar.xz |
add function header for SIGNATURE_XX, according to MDE Spec, 0.61e-7
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6428 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg/Include')
-rw-r--r-- | MdePkg/Include/Base.h | 42 |
1 files changed, 39 insertions, 3 deletions
diff --git a/MdePkg/Include/Base.h b/MdePkg/Include/Base.h index 8ddb52a5ac..a2c5511750 100644 --- a/MdePkg/Include/Base.h +++ b/MdePkg/Include/Base.h @@ -281,11 +281,47 @@ typedef INTN RETURN_STATUS; #define RETURN_WARN_WRITE_FAILURE ENCODE_WARNING (3)
#define RETURN_WARN_BUFFER_TOO_SMALL ENCODE_WARNING (4)
-//
-// Define macros to build data structure signatures from characters.
-//
+/**
+ Returns a 16-bit signature built from 2 ASCII characters.
+
+ @param A The first ASCII character.
+ @param B The second ASCII character.
+
+ @return A 16-bit value built from the two ASCII characters specified by A and B.
+
+**/
#define SIGNATURE_16(A, B) ((A) | (B << 8))
+
+/**
+ Returns a 32-bit signature built from 4 ASCII characters.
+
+ @param A The first ASCII character.
+ @param B The second ASCII character.
+ @param C The third ASCII character.
+ @param D The fourth ASCII character.
+
+ @return A 32-bit value built from the two ASCII characters specified by A, B,
+ C and D.
+
+**/
#define SIGNATURE_32(A, B, C, D) (SIGNATURE_16 (A, B) | (SIGNATURE_16 (C, D) << 16))
+
+/**
+ Returns a 64-bit signature built from 8 ASCII characters.
+
+ @param A The first ASCII character.
+ @param B The second ASCII character.
+ @param C The third ASCII character.
+ @param D The fourth ASCII character.
+ @param E The fifth ASCII character.
+ @param F The sixth ASCII character.
+ @param G The seventh ASCII character.
+ @param H The eighth ASCII character.
+
+ @return A 64-bit value built from the two ASCII characters specified by A, B,
+ C, D, E, F, G and H.
+
+**/
#define SIGNATURE_64(A, B, C, D, E, F, G, H) \
(SIGNATURE_32 (A, B, C, D) | ((UINT64) (SIGNATURE_32 (E, F, G, H)) << 32))
|