Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 17506
b: refs/heads/master
c: c7ab337
h: refs/heads/master
v: v3
  • Loading branch information
Thomas Schaefer authored and Greg Kroah-Hartman committed Jan 9, 2006
1 parent 457517f commit 57e8f79
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9d265124d051c2cf6716639239609d83f736dcdb
refs/heads/master: c7ab337f91b59f71a30c3ab71e3bdfff41671977
19 changes: 17 additions & 2 deletions trunk/drivers/pci/hotplug/pciehp_hpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -787,8 +787,13 @@ static int hpc_power_on_slot(struct slot * slot)

slot_cmd = (slot_ctrl & ~PWR_CTRL) | POWER_ON;

/* Enable detection that we turned off at slot power-off time */
if (!pciehp_poll_mode)
slot_cmd = slot_cmd | HP_INTR_ENABLE;
slot_cmd = slot_cmd |
PWR_FAULT_DETECT_ENABLE |
MRL_DETECT_ENABLE |
PRSN_DETECT_ENABLE |
HP_INTR_ENABLE;

retval = pcie_write_cmd(slot, slot_cmd);

Expand Down Expand Up @@ -833,8 +838,18 @@ static int hpc_power_off_slot(struct slot * slot)

slot_cmd = (slot_ctrl & ~PWR_CTRL) | POWER_OFF;

/*
* If we get MRL or presence detect interrupts now, the isr
* will notice the sticky power-fault bit too and issue power
* indicator change commands. This will lead to an endless loop
* of command completions, since the power-fault bit remains on
* till the slot is powered on again.
*/
if (!pciehp_poll_mode)
slot_cmd = slot_cmd | HP_INTR_ENABLE;
slot_cmd = (slot_cmd &
~PWR_FAULT_DETECT_ENABLE &
~MRL_DETECT_ENABLE &
~PRSN_DETECT_ENABLE) | HP_INTR_ENABLE;

retval = pcie_write_cmd(slot, slot_cmd);

Expand Down

0 comments on commit 57e8f79

Please sign in to comment.