diff options
author | jljusten <jljusten@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-10-12 18:52:50 +0000 |
---|---|---|
committer | jljusten <jljusten@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-10-12 18:52:50 +0000 |
commit | 2c3239f305e6d3cab32cb408cdde97fed6bc639c (patch) | |
tree | 322b885704830d17758247a15ea5f29b7c0b9f13 | |
parent | d1281916206b835e51596bffc744a99f7b71e874 (diff) | |
download | edk2-2c3239f305e6d3cab32cb408cdde97fed6bc639c.zip edk2-2c3239f305e6d3cab32cb408cdde97fed6bc639c.tar.gz edk2-2c3239f305e6d3cab32cb408cdde97fed6bc639c.tar.bz2 |
OvmfPkg: IndustryStandard/Virtio.h: use OFFSET_OF in OFFSET_OF_VHDR
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13838 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r-- | OvmfPkg/Include/IndustryStandard/Virtio.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/OvmfPkg/Include/IndustryStandard/Virtio.h b/OvmfPkg/Include/IndustryStandard/Virtio.h index ff4b71c..600d3d2 100644 --- a/OvmfPkg/Include/IndustryStandard/Virtio.h +++ b/OvmfPkg/Include/IndustryStandard/Virtio.h @@ -118,7 +118,7 @@ typedef struct { } VBLK_HDR;
#pragma pack()
-#define OFFSET_OF_VHDR(Field) ((UINTN)(UINT8 *)&((VBLK_HDR *) 0)->Field)
+#define OFFSET_OF_VHDR(Field) OFFSET_OF (VBLK_HDR, Field)
#define SIZE_OF_VHDR(Field) (sizeof ((VBLK_HDR *) 0)->Field)
|