/* sym2_io_error_detected() - called when PCI error is detected @pdev: pointer to PCI device @state: current state of the PCI slot  */
static pci_ers_result_t sym2_io_error_detected(struct pci_dev *pdev, enum pci_channel_state state)
/* sym2_io_error_detected() - called when PCI error is detected @pdev: pointer to PCI device @state: current state of the PCI slot  */
static pci_ers_result_t sym2_io_error_detected(struct pci_dev *pdev, enum pci_channel_state state)
{
	if (state == pci_channel_io_perm_failure) {
		sym2_remove(pdev);
		return PCI_ERS_RESULT_DISCONNECT;
	}
	disable_irq(pdev->irq);
	pci_disable_device(pdev);
	return PCI_ERS_RESULT_CAN_RECOVER;
}