Skip to content

Commit

Permalink
PCI: release temporary reference in __nv_msi_ht_cap_quirk()
Browse files Browse the repository at this point in the history
__nv_msi_ht_cap_quirk() acquires a temporary reference via
'pci_get_bus_and_slot()' that is never released.

This patch releases the temporary reference.

Signed-off-by: Myron Stowe <myron.stowe@redhat.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
  • Loading branch information
Myron Stowe authored and Bjorn Helgaas committed Jul 9, 2012
1 parent 2729d5b commit dff3aef
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions drivers/pci/quirks.c
Original file line number Diff line number Diff line change
Expand Up @@ -2541,15 +2541,18 @@ static void __devinit __nv_msi_ht_cap_quirk(struct pci_dev *dev, int all)
else
nv_ht_enable_msi_mapping(dev);
}
return;
goto out;
}

/* HT MSI is not enabled */
if (found == 1)
return;
goto out;

/* Host bridge is not to HT, disable HT MSI mapping on this device */
ht_disable_msi_mapping(dev);

out:
pci_dev_put(host_bridge);
}

static void __devinit nv_msi_ht_cap_quirk_all(struct pci_dev *dev)
Expand Down

0 comments on commit dff3aef

Please sign in to comment.