summaryrefslogtreecommitdiff
path: root/OvmfPkg/VirtioBlkDxe/VirtioBlk.c
diff options
context:
space:
mode:
Diffstat (limited to 'OvmfPkg/VirtioBlkDxe/VirtioBlk.c')
-rw-r--r--OvmfPkg/VirtioBlkDxe/VirtioBlk.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/OvmfPkg/VirtioBlkDxe/VirtioBlk.c b/OvmfPkg/VirtioBlkDxe/VirtioBlk.c
index 5559884..95e42ef 100644
--- a/OvmfPkg/VirtioBlkDxe/VirtioBlk.c
+++ b/OvmfPkg/VirtioBlkDxe/VirtioBlk.c
@@ -11,7 +11,7 @@
synchronous requests and EFI_BLOCK_IO_PROTOCOL for now.
Copyright (C) 2012, Red Hat, Inc.
- Copyright (c) 2012 - 2016, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2012 - 2018, Intel Corporation. All rights reserved.<BR>
Copyright (c) 2017, AMD Inc, All rights reserved.<BR>
This program and the accompanying materials are licensed and made available
@@ -265,6 +265,13 @@ SynchronousRequest (
BlockSize = Dev->BlockIoMedia.BlockSize;
//
+ // Set BufferMapping and BufferDeviceAddress to suppress incorrect
+ // compiler/analyzer warnings.
+ //
+ BufferMapping = NULL;
+ BufferDeviceAddress = 0;
+
+ //
// ensured by VirtioBlkInit()
//
ASSERT (BlockSize > 0);