summaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/pciehp_hpc.c
diff options
context:
space:
mode:
authorRajat Jain <rajatxjain@gmail.com>2014-06-26 11:58:55 -0700
committerBjorn Helgaas <bhelgaas@google.com>2014-07-05 11:38:26 -0600
commit6c1a32e06758ba1c997f81a3c41e780cfc77b3c2 (patch)
treee161765638a6dbefd8f12fc40aa11431e354eab3 /drivers/pci/hotplug/pciehp_hpc.c
parent2cc56f3028091578dcf0093cd00f1fee7a21515d (diff)
downloadop-kernel-dev-6c1a32e06758ba1c997f81a3c41e780cfc77b3c2.zip
op-kernel-dev-6c1a32e06758ba1c997f81a3c41e780cfc77b3c2.tar.gz
PCI: pciehp: Remove struct controller.no_cmd_complete
"no_cmd_complete" is only used once, and it duplicates read-only information we already have in the cached Slot Capabilities value. Remove the field and use the existing macro NO_CMD_CMPL() instead. [bhelgaas: changelog] Signed-off-by: Rajat Jain <rajatxjain@gmail.com> Signed-off-by: Rajat Jain <rajatjain@juniper.net> Signed-off-by: Guenter Roeck <groeck@juniper.net> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/hotplug/pciehp_hpc.c')
-rw-r--r--drivers/pci/hotplug/pciehp_hpc.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c
index a3a5c65..f7c3709 100644
--- a/drivers/pci/hotplug/pciehp_hpc.c
+++ b/drivers/pci/hotplug/pciehp_hpc.c
@@ -140,7 +140,7 @@ static void pcie_wait_cmd(struct controller *ctrl)
* If the controller does not generate notifications for command
* completions, we never need to wait between writes.
*/
- if (ctrl->no_cmd_complete)
+ if (NO_CMD_CMPL(ctrl))
return;
if (!ctrl->cmd_busy)
@@ -772,15 +772,6 @@ struct controller *pcie_init(struct pcie_device *dev)
init_waitqueue_head(&ctrl->queue);
dbg_ctrl(ctrl);
- /*
- * Controller doesn't notify of command completion if the "No
- * Command Completed Support" bit is set in Slot Capabilities.
- * If set, it means the controller can accept hotplug commands
- * with no delay between them.
- */
- if (NO_CMD_CMPL(ctrl))
- ctrl->no_cmd_complete = 1;
-
/* Check if Data Link Layer Link Active Reporting is implemented */
pcie_capability_read_dword(pdev, PCI_EXP_LNKCAP, &link_cap);
if (link_cap & PCI_EXP_LNKCAP_DLLLARC) {
OpenPOWER on IntegriCloud