diff options
author | Laszlo Ersek <lersek@redhat.com> | 2017-08-02 12:03:27 +0200 |
---|---|---|
committer | Laszlo Ersek <lersek@redhat.com> | 2017-08-05 01:31:52 +0200 |
commit | 5e365a97ecd92b49d17bf77e0d67bf88fff34197 (patch) | |
tree | 01faa622bc60bdc256e937b1b63c87961769fabe /OvmfPkg/IoMmuDxe/IoMmuDxe.c | |
parent | 60aa3a0e739e5eb4a3c8028380fae725bba5b567 (diff) | |
download | edk2-5e365a97ecd92b49d17bf77e0d67bf88fff34197.tar.gz edk2-5e365a97ecd92b49d17bf77e0d67bf88fff34197.tar.bz2 edk2-5e365a97ecd92b49d17bf77e0d67bf88fff34197.zip |
OvmfPkg/IoMmuDxe: don't initialize local variables
The edk2 coding style requires separate assignments.
Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Brijesh Singh <brijesh.singh@amd.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Tom Lendacky <thomas.lendacky@amd.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Tested-by: Brijesh Singh <brijesh.singh@amd.com>
Reviewed-by: Brijesh Singh <brijesh.singh@amd.com>
Diffstat (limited to 'OvmfPkg/IoMmuDxe/IoMmuDxe.c')
-rw-r--r-- | OvmfPkg/IoMmuDxe/IoMmuDxe.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/OvmfPkg/IoMmuDxe/IoMmuDxe.c b/OvmfPkg/IoMmuDxe/IoMmuDxe.c index 5809afc441..27b1856e0a 100644 --- a/OvmfPkg/IoMmuDxe/IoMmuDxe.c +++ b/OvmfPkg/IoMmuDxe/IoMmuDxe.c @@ -33,8 +33,10 @@ IoMmuDxeEntryPoint ( IN EFI_SYSTEM_TABLE *SystemTable
)
{
- EFI_STATUS Status = EFI_SUCCESS;
- EFI_HANDLE Handle = NULL;
+ EFI_STATUS Status;
+ EFI_HANDLE Handle;
+
+ Status = EFI_SUCCESS;
//
// When SEV is enabled, install IoMmu protocol otherwise install the
@@ -43,6 +45,8 @@ IoMmuDxeEntryPoint ( if (MemEncryptSevIsEnabled ()) {
AmdSevInstallIoMmuProtocol ();
} else {
+ Handle = NULL;
+
Status = gBS->InstallMultipleProtocolInterfaces (
&Handle,
&gIoMmuAbsentProtocolGuid,
|