提交 01daacfb 编写于 作者: Y Yicong Yang 提交者: Bjorn Helgaas

PCI/AER: Log which device prevents error recovery

PCI error recovery will fail if any device under the Root Port doesn't have
an error_detected callback.  Currently only the failure result is printed,
which is not enough to identify the driver that lacks the callback.

Log a message to identify the device with no error_detected callback.

[bhelgaas: tweak log message]
Link: https://lore.kernel.org/r/1576237474-32021-1-git-send-email-yangyicong@hisilicon.comSigned-off-by: NYicong Yang <yangyicong@hisilicon.com>
Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
上级 e42617b8
...@@ -61,10 +61,12 @@ static int report_error_detected(struct pci_dev *dev, ...@@ -61,10 +61,12 @@ static int report_error_detected(struct pci_dev *dev,
* error callbacks of "any" device in the subtree, and will * error callbacks of "any" device in the subtree, and will
* exit in the disconnected error state. * exit in the disconnected error state.
*/ */
if (dev->hdr_type != PCI_HEADER_TYPE_BRIDGE) if (dev->hdr_type != PCI_HEADER_TYPE_BRIDGE) {
vote = PCI_ERS_RESULT_NO_AER_DRIVER; vote = PCI_ERS_RESULT_NO_AER_DRIVER;
else pci_info(dev, "AER: Can't recover (no error_detected callback)\n");
} else {
vote = PCI_ERS_RESULT_NONE; vote = PCI_ERS_RESULT_NONE;
}
} else { } else {
err_handler = dev->driver->err_handler; err_handler = dev->driver->err_handler;
vote = err_handler->error_detected(dev, state); vote = err_handler->error_detected(dev, state);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册