]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg/PciHostBridgeDxe: remove unused but set variables
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 24 Mar 2016 06:28:17 +0000 (07:28 +0100)
committerLaszlo Ersek <lersek@redhat.com>
Fri, 25 Mar 2016 09:52:22 +0000 (10:52 +0100)
Remove variables that are declared, assigned but never referenced. This
fixes a warning emitted by GCC when -Wunused-but-set-variable is in effect.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridge.c

index d5da6995af36ca0dfbbeacf30e892d38d0239f58..50f1407e7aeac57783a9183e380da08d8a4248bf 100644 (file)
@@ -628,7 +628,6 @@ NotifyPhase (
   PCI_ROOT_BRIDGE_INSTANCE              *RootBridge;\r
   LIST_ENTRY                            *Link;\r
   EFI_PHYSICAL_ADDRESS                  BaseAddress;\r
-  UINT64                                AddrLen;\r
   UINTN                                 BitsOfAlignment;\r
   UINT64                                Alignment;\r
   EFI_STATUS                            Status;\r
@@ -735,7 +734,6 @@ NotifyPhase (
 \r
           ASSERT (Index < TypeMax);\r
           ResNodeHandled[Index] = TRUE;\r
-          AddrLen = RootBridge->ResAllocNode[Index].Length;\r
           Alignment = RootBridge->ResAllocNode[Index].Alignment;\r
           BitsOfAlignment = LowBitSet64 (Alignment + 1);\r
           BaseAddress = MAX_UINT64;\r
@@ -1110,9 +1108,6 @@ SetBusNumbers (
   PCI_ROOT_BRIDGE_INSTANCE  *RootBridge;\r
   EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR *Descriptor;\r
   EFI_ACPI_END_TAG_DESCRIPTOR       *End;\r
-  UINTN                     BusStart;\r
-  UINTN                     BusEnd;\r
-  UINTN                     BusLen;\r
 \r
   if (Configuration == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
@@ -1138,9 +1133,6 @@ SetBusNumbers (
        ) {\r
     RootBridge = ROOT_BRIDGE_FROM_LINK (Link);\r
     if (RootBridgeHandle == RootBridge->Handle) {\r
-      BusStart  = (UINTN) Descriptor->AddrRangeMin;\r
-      BusLen    = (UINTN) Descriptor->AddrLen;\r
-      BusEnd    = BusStart + BusLen - 1;\r
 \r
       if (Descriptor->AddrLen == 0) {\r
         return EFI_INVALID_PARAMETER;\r