mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-23 05:56:14 -04:00
PCI pciehp: fix power fault interrupt storm problem
Enabling power fault detected event notification in current pciehp might cause power fault interrupt storm on some machines. On those machines. On those machines, power fault detected bit in the slot status register was set again immediately when it is cleared in the interrupt service routine, and next power fault detected interrupt was notified again. Therefore, disable power fault detected event notification for now. This patch also removes unnecessary handling for power fault cleared event because this event is not supported by PCIe spec. Tested-by: Jens Axboe <jens.axboe@oracle.com> Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
This commit is contained in:
committed by
Jesse Barnes
parent
13598378f2
commit
5651c48cfa
@@ -142,23 +142,9 @@ u8 pciehp_handle_power_fault(struct slot *p_slot)
|
||||
|
||||
/* power fault */
|
||||
ctrl_dbg(ctrl, "Power fault interrupt received\n");
|
||||
|
||||
if (!pciehp_query_power_fault(p_slot)) {
|
||||
/*
|
||||
* power fault Cleared
|
||||
*/
|
||||
ctrl_info(ctrl, "Power fault cleared on Slot(%s)\n",
|
||||
slot_name(p_slot));
|
||||
event_type = INT_POWER_FAULT_CLEAR;
|
||||
} else {
|
||||
/*
|
||||
* power fault
|
||||
*/
|
||||
ctrl_info(ctrl, "Power fault on Slot(%s)\n", slot_name(p_slot));
|
||||
event_type = INT_POWER_FAULT;
|
||||
ctrl_info(ctrl, "Power fault bit %x set\n", 0);
|
||||
}
|
||||
|
||||
ctrl_err(ctrl, "Power fault on slot %s\n", slot_name(p_slot));
|
||||
event_type = INT_POWER_FAULT;
|
||||
ctrl_info(ctrl, "Power fault bit %x set\n", 0);
|
||||
queue_interrupt_event(p_slot, event_type);
|
||||
|
||||
return 1;
|
||||
@@ -224,13 +210,12 @@ static int board_added(struct slot *p_slot)
|
||||
retval = pciehp_check_link_status(ctrl);
|
||||
if (retval) {
|
||||
ctrl_err(ctrl, "Failed to check link status\n");
|
||||
set_slot_off(ctrl, p_slot);
|
||||
return retval;
|
||||
goto err_exit;
|
||||
}
|
||||
|
||||
/* Check for a power fault */
|
||||
if (pciehp_query_power_fault(p_slot)) {
|
||||
ctrl_dbg(ctrl, "Power fault detected\n");
|
||||
if (ctrl->power_fault_detected || pciehp_query_power_fault(p_slot)) {
|
||||
ctrl_err(ctrl, "Power fault on slot %s\n", slot_name(p_slot));
|
||||
retval = -EIO;
|
||||
goto err_exit;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user