--- zzzz-none-000/linux-3.10.107/drivers/net/wireless/p54/p54pci.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/net/wireless/p54/p54pci.c 2021-02-04 17:41:59.000000000 +0000 @@ -13,7 +13,6 @@ * published by the Free Software Foundation. */ -#include #include #include #include @@ -33,7 +32,7 @@ MODULE_ALIAS("prism54pci"); MODULE_FIRMWARE("isl3886pci"); -static DEFINE_PCI_DEVICE_TABLE(p54p_table) = { +static const struct pci_device_id p54p_table[] = { /* Intersil PRISM Duette/Prism GT Wireless LAN adapter */ { PCI_DEVICE(0x1260, 0x3890) }, /* 3COM 3CRWE154G72 Wireless LAN adapter */ @@ -432,6 +431,7 @@ { struct p54p_priv *priv = dev->priv; int err; + long timeout; init_completion(&priv->boot_comp); err = request_irq(priv->pdev->irq, p54p_interrupt, @@ -469,10 +469,12 @@ P54P_WRITE(dev_int, cpu_to_le32(ISL38XX_DEV_INT_RESET)); P54P_READ(dev_int); - if (!wait_for_completion_interruptible_timeout(&priv->boot_comp, HZ)) { + timeout = wait_for_completion_interruptible_timeout( + &priv->boot_comp, HZ); + if (timeout <= 0) { wiphy_err(dev->wiphy, "Cannot boot firmware!\n"); p54p_stop(dev); - return -ETIMEDOUT; + return timeout ? -ERESTARTSYS : -ETIMEDOUT; } P54P_WRITE(int_enable, cpu_to_le32(ISL38XX_INT_IDENT_UPDATE)); @@ -631,7 +633,6 @@ iounmap(priv->map); err_free_dev: - pci_set_drvdata(pdev, NULL); p54_free_common(dev); err_free_reg: