get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/952638/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 952638,
    "url": "http://patchwork.ozlabs.org/api/patches/952638/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20180802004036.89363-1-alice.michael@intel.com/",
    "project": {
        "id": 46,
        "url": "http://patchwork.ozlabs.org/api/projects/46/?format=api",
        "name": "Intel Wired Ethernet development",
        "link_name": "intel-wired-lan",
        "list_id": "intel-wired-lan.osuosl.org",
        "list_email": "intel-wired-lan@osuosl.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20180802004036.89363-1-alice.michael@intel.com>",
    "list_archive_url": null,
    "date": "2018-08-02T00:40:24",
    "name": "[next,S94,01/13] i40e: Introduce recovery mode support",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "540939fab13d4961d3a03f02d5e9f4f927633707",
    "submitter": {
        "id": 71123,
        "url": "http://patchwork.ozlabs.org/api/people/71123/?format=api",
        "name": "Michael, Alice",
        "email": "alice.michael@intel.com"
    },
    "delegate": {
        "id": 68,
        "url": "http://patchwork.ozlabs.org/api/users/68/?format=api",
        "username": "jtkirshe",
        "first_name": "Jeff",
        "last_name": "Kirsher",
        "email": "jeffrey.t.kirsher@intel.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20180802004036.89363-1-alice.michael@intel.com/mbox/",
    "series": [
        {
            "id": 58959,
            "url": "http://patchwork.ozlabs.org/api/series/58959/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=58959",
            "date": "2018-08-02T00:40:24",
            "name": "[next,S94,01/13] i40e: Introduce recovery mode support",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/58959/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/952638/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/952638/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<intel-wired-lan-bounces@osuosl.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=osuosl.org\n\t(client-ip=140.211.166.137; helo=fraxinus.osuosl.org;\n\tenvelope-from=intel-wired-lan-bounces@osuosl.org;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org;\n\tdmarc=fail (p=none dis=none) header.from=intel.com"
        ],
        "Received": [
            "from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 41h3nX23vYz9s2g\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu,  2 Aug 2018 18:51:43 +1000 (AEST)",
            "from localhost (localhost [127.0.0.1])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id 7C52586F89;\n\tThu,  2 Aug 2018 08:51:42 +0000 (UTC)",
            "from fraxinus.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id 6dDfGsIp22KP; Thu,  2 Aug 2018 08:51:41 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id 6D41986F62;\n\tThu,  2 Aug 2018 08:51:41 +0000 (UTC)",
            "from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138])\n\tby ash.osuosl.org (Postfix) with ESMTP id CA66F1CF334\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu,  2 Aug 2018 08:51:18 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id C7E2A87CAC\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu,  2 Aug 2018 08:51:18 +0000 (UTC)",
            "from whitealder.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id 26p59jCiTufI for <intel-wired-lan@lists.osuosl.org>;\n\tThu,  2 Aug 2018 08:51:16 +0000 (UTC)",
            "from mga04.intel.com (mga04.intel.com [192.55.52.120])\n\tby whitealder.osuosl.org (Postfix) with ESMTPS id BFAE381E2E\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu,  2 Aug 2018 08:51:16 +0000 (UTC)",
            "from fmsmga002.fm.intel.com ([10.253.24.26])\n\tby fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t02 Aug 2018 01:51:16 -0700",
            "from alicemic-2.jf.intel.com ([10.166.16.121])\n\tby fmsmga002.fm.intel.com with ESMTP; 02 Aug 2018 01:51:16 -0700"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.51,434,1526367600\"; d=\"scan'208\";a=\"72695368\"",
        "From": "Alice Michael <alice.michael@intel.com>",
        "To": "alice.michael@intel.com,\n\tintel-wired-lan@lists.osuosl.org",
        "Date": "Wed,  1 Aug 2018 17:40:24 -0700",
        "Message-Id": "<20180802004036.89363-1-alice.michael@intel.com>",
        "X-Mailer": "git-send-email 2.9.5",
        "Subject": "[Intel-wired-lan] [next PATCH S94 01/13] i40e: Introduce recovery\n\tmode support",
        "X-BeenThere": "intel-wired-lan@osuosl.org",
        "X-Mailman-Version": "2.1.24",
        "Precedence": "list",
        "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n\t<intel-wired-lan.osuosl.org>",
        "List-Unsubscribe": "<https://lists.osuosl.org/mailman/options/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@osuosl.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.osuosl.org/pipermail/intel-wired-lan/>",
        "List-Post": "<mailto:intel-wired-lan@osuosl.org>",
        "List-Help": "<mailto:intel-wired-lan-request@osuosl.org?subject=help>",
        "List-Subscribe": "<https://lists.osuosl.org/mailman/listinfo/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@osuosl.org?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "intel-wired-lan-bounces@osuosl.org",
        "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@osuosl.org>"
    },
    "content": "From: Mariusz Stachura <mariusz.stachura@intel.com>\n\nThis patch introduces \"recovery mode\" to the i40e driver. It is\npart of a new Any2Any idea of upgrading the firmware. In this\napproach, it is required for the driver to have support for\n\"transition firmware\", that is used for migrating from structured\nto flat firmware image. In this new, very basic mode, i40e driver\nmust be able to handle particular IOCTL calls from the NVM Update\nTool and run a small set of AQ commands.\n\nSigned-off-by: Mariusz Stachura <mariusz.stachura@intel.com>\n---\n drivers/net/ethernet/intel/i40e/i40e.h         |   1 +\n drivers/net/ethernet/intel/i40e/i40e_ethtool.c |  14 +-\n drivers/net/ethernet/intel/i40e/i40e_main.c    | 212 ++++++++++++++++++++++---\n 3 files changed, 206 insertions(+), 21 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/i40e/i40e.h b/drivers/net/ethernet/intel/i40e/i40e.h\nindex 7a80652..db911e3 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e.h\n+++ b/drivers/net/ethernet/intel/i40e/i40e.h\n@@ -140,6 +140,7 @@ enum i40e_state_t {\n \t__I40E_RESET_FAILED,\n \t__I40E_PORT_SUSPENDED,\n \t__I40E_VF_DISABLE,\n+\t__I40E_RECOVERY_MODE,\n \t__I40E_MACVLAN_SYNC_PENDING,\n \t__I40E_UDP_FILTER_SYNC_PENDING,\n \t__I40E_TEMP_LINK_POLLING,\ndiff --git a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\nindex abcd096..19606a2 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\n@@ -4829,6 +4829,12 @@ static int i40e_get_module_eeprom(struct net_device *netdev,\n \treturn 0;\n }\n \n+static const struct ethtool_ops i40e_ethtool_recovery_mode_ops = {\n+\t.set_eeprom\t\t= i40e_set_eeprom,\n+\t.get_eeprom_len\t\t= i40e_get_eeprom_len,\n+\t.get_eeprom\t\t= i40e_get_eeprom,\n+};\n+\n static const struct ethtool_ops i40e_ethtool_ops = {\n \t.get_drvinfo\t\t= i40e_get_drvinfo,\n \t.get_regs_len\t\t= i40e_get_regs_len,\n@@ -4874,5 +4880,11 @@ static const struct ethtool_ops i40e_ethtool_ops = {\n \n void i40e_set_ethtool_ops(struct net_device *netdev)\n {\n-\tnetdev->ethtool_ops = &i40e_ethtool_ops;\n+\tstruct i40e_netdev_priv *np = netdev_priv(netdev);\n+\tstruct i40e_pf\t\t*pf = np->vsi->back;\n+\n+\tif (!test_bit(__I40E_RECOVERY_MODE, pf->state))\n+\t\tnetdev->ethtool_ops = &i40e_ethtool_ops;\n+\telse\n+\t\tnetdev->ethtool_ops = &i40e_ethtool_recovery_mode_ops;\n }\ndiff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c\nindex a730f48..c4ba44c 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_main.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_main.c\n@@ -44,6 +44,8 @@ static int i40e_setup_pf_filter_control(struct i40e_pf *pf);\n static void i40e_prep_for_reset(struct i40e_pf *pf, bool lock_acquired);\n static int i40e_reset(struct i40e_pf *pf);\n static void i40e_rebuild(struct i40e_pf *pf, bool reinit, bool lock_acquired);\n+static bool i40e_check_recovery_mode(struct i40e_pf *pf);\n+static int i40e_init_recovery_mode(struct i40e_pf *pf, struct i40e_hw *hw);\n static void i40e_fdir_sb_setup(struct i40e_pf *pf);\n static int i40e_veb_get_bw_info(struct i40e_veb *veb);\n static int i40e_get_capabilities(struct i40e_pf *pf,\n@@ -276,8 +278,9 @@ struct i40e_vsi *i40e_find_vsi_from_id(struct i40e_pf *pf, u16 id)\n  **/\n void i40e_service_event_schedule(struct i40e_pf *pf)\n {\n-\tif (!test_bit(__I40E_DOWN, pf->state) &&\n-\t    !test_bit(__I40E_RESET_RECOVERY_PENDING, pf->state))\n+\tif ((!test_bit(__I40E_DOWN, pf->state) &&\n+\t     !test_bit(__I40E_RESET_RECOVERY_PENDING, pf->state)) ||\n+\t      test_bit(__I40E_RECOVERY_MODE, pf->state))\n \t\tqueue_work(i40e_wq, &pf->service_task);\n }\n \n@@ -9332,7 +9335,14 @@ static void i40e_rebuild(struct i40e_pf *pf, bool reinit, bool lock_acquired)\n \tu32 val;\n \tint v;\n \n-\tif (test_bit(__I40E_DOWN, pf->state))\n+\tif (pf->hw.mac.type == I40E_MAC_X722 &&\n+\t    test_bit(__I40E_EMP_RESET_INTR_RECEIVED, pf->state) &&\n+\t    i40e_check_recovery_mode(pf)) {\n+\t\ti40e_set_ethtool_ops(pf->vsi[pf->lan_vsi]->netdev);\n+\t}\n+\n+\tif (test_bit(__I40E_DOWN, pf->state) &&\n+\t    !test_bit(__I40E_RECOVERY_MODE, pf->state))\n \t\tgoto clear_recovery;\n \tdev_dbg(&pf->pdev->dev, \"Rebuilding internal switch\\n\");\n \n@@ -9358,8 +9368,14 @@ static void i40e_rebuild(struct i40e_pf *pf, bool reinit, bool lock_acquired)\n \t}\n \n \t/* re-verify the eeprom if we just had an EMP reset */\n-\tif (test_and_clear_bit(__I40E_EMP_RESET_INTR_RECEIVED, pf->state))\n+\tif (test_and_clear_bit(__I40E_EMP_RESET_INTR_RECEIVED, pf->state)) {\n \t\ti40e_verify_eeprom(pf);\n+\t\t/* bail out in case recovery mode was detected, as there is\n+\t\t * no need for further configuration.\n+\t\t */\n+\t\tif (test_bit(__I40E_RECOVERY_MODE, pf->state))\n+\t\t\tgoto end_unlock;\n+\t}\n \n \ti40e_clear_pxe_mode(hw);\n \tret = i40e_get_capabilities(pf, i40e_aqc_opc_list_func_capabilities);\n@@ -9827,25 +9843,31 @@ static void i40e_service_task(struct work_struct *work)\n \tif (test_and_set_bit(__I40E_SERVICE_SCHED, pf->state))\n \t\treturn;\n \n-\ti40e_detect_recover_hung(pf->vsi[pf->lan_vsi]);\n-\ti40e_sync_filters_subtask(pf);\n-\ti40e_reset_subtask(pf);\n-\ti40e_handle_mdd_event(pf);\n-\ti40e_vc_process_vflr_event(pf);\n-\ti40e_watchdog_subtask(pf);\n-\ti40e_fdir_reinit_subtask(pf);\n-\tif (test_and_clear_bit(__I40E_CLIENT_RESET, pf->state)) {\n-\t\t/* Client subtask will reopen next time through. */\n-\t\ti40e_notify_client_of_netdev_close(pf->vsi[pf->lan_vsi], true);\n-\t} else {\n-\t\ti40e_client_subtask(pf);\n-\t\tif (test_and_clear_bit(__I40E_CLIENT_L2_CHANGE,\n-\t\t\t\t       pf->state))\n-\t\t\ti40e_notify_client_of_l2_param_changes(\n+\tif (!test_bit(__I40E_RECOVERY_MODE, pf->state)) {\n+\t\ti40e_detect_recover_hung(pf->vsi[pf->lan_vsi]);\n+\t\ti40e_sync_filters_subtask(pf);\n+\t\ti40e_reset_subtask(pf);\n+\t\ti40e_handle_mdd_event(pf);\n+\t\ti40e_vc_process_vflr_event(pf);\n+\t\ti40e_watchdog_subtask(pf);\n+\t\ti40e_fdir_reinit_subtask(pf);\n+\t\tif (pf->flags & __I40E_CLIENT_RESET) {\n+\t\t\t/* Client subtask will reopen next time through. */\n+\t\t\ti40e_notify_client_of_netdev_close(\n+\t\t\t\t\t\tpf->vsi[pf->lan_vsi], true);\n+\t\t} else {\n+\t\t\ti40e_client_subtask(pf);\n+\t\t\tif (test_and_clear_bit(__I40E_CLIENT_L2_CHANGE,\n+\t\t\t\t\t       pf->state))\n+\t\t\t\ti40e_notify_client_of_l2_param_changes(\n \t\t\t\t\t\t\tpf->vsi[pf->lan_vsi]);\n+\t\t}\n+\t\ti40e_sync_udp_filters_subtask(pf);\n+\n+\t} else {\n+\t\ti40e_reset_subtask(pf);\n \t}\n \ti40e_sync_filters_subtask(pf);\n-\ti40e_sync_udp_filters_subtask(pf);\n \ti40e_clean_adminq_subtask(pf);\n \n \t/* flush memory to make sure state is correct before next watchdog */\n@@ -13524,6 +13546,137 @@ static void i40e_get_platform_mac_addr(struct pci_dev *pdev, struct i40e_pf *pf)\n }\n \n /**\n+ * i40e_check_recovery_mode - check if we are running transition firmware\n+ * @pf: board private structure\n+ *\n+ * Check registers indicating the firmware runs in recovery mode. Sets the\n+ * appropriate driver state.\n+ *\n+ * Returns true if the recovery mode was detected, false otherwise\n+ **/\n+static bool i40e_check_recovery_mode(struct i40e_pf *pf)\n+{\n+\tu32 val = rd32(&pf->hw, I40E_GL_FWSTS);\n+\n+\tif (val & I40E_GL_FWSTS_FWS1B_MASK) {\n+\t\tdev_info(&pf->pdev->dev, \"transition FW detected, running in recovery mode\\n\");\n+\t\tset_bit(__I40E_RECOVERY_MODE, pf->state);\n+\n+\t\treturn true;\n+\t}\n+\tclear_bit(__I40E_RECOVERY_MODE, pf->state);\n+\n+\treturn false;\n+}\n+\n+/**\n+ * i40e_init_recovery_mode - initialize subsystems needed in recovery mode\n+ * @pf: board private structure\n+ * @hw: ptr to the hardware info\n+ *\n+ * This function does a minimal setup of all subsystems needed for running\n+ * recovery mode.\n+ *\n+ * Returns 0 on success, negative on failure\n+ **/\n+static int i40e_init_recovery_mode(struct i40e_pf *pf, struct i40e_hw *hw)\n+{\n+\tstruct i40e_vsi *vsi;\n+\tint err;\n+\tint v_idx;\n+\n+\terr = i40e_sw_init(pf);\n+\tif (err) {\n+\t\tdev_info(&pf->pdev->dev, \"sw_init failed: %d\\n\", err);\n+\t\tgoto err_sw_init;\n+\t}\n+\n+\t/* allow a platform config to override the HW addr */\n+\ti40e_get_platform_mac_addr(pf->pdev, pf);\n+\n+\tif (!is_valid_ether_addr(hw->mac.addr)) {\n+\t\t/* normally we would return -EIO here */\n+\t\tdev_info(&pf->pdev->dev, \"invalid MAC address %pM\\n\",\n+\t\t\t hw->mac.addr);\n+\t} else {\n+\t\tdev_info(&pf->pdev->dev, \"MAC address: %pM\\n\", hw->mac.addr);\n+\t}\n+\tether_addr_copy(hw->mac.perm_addr, hw->mac.addr);\n+\ti40e_get_port_mac_addr(hw, hw->mac.port_addr);\n+\tif (is_valid_ether_addr(hw->mac.port_addr))\n+\t\tpf->hw_features |= I40E_HW_PORT_ID_VALID;\n+\n+\tpci_save_state(pf->pdev);\n+\n+\t/* set up periodic task facility */\n+\ttimer_setup(&pf->service_timer, i40e_service_timer, (unsigned long)pf);\n+\tpf->service_timer_period = HZ;\n+\n+\tINIT_WORK(&pf->service_task, i40e_service_task);\n+\tclear_bit(__I40E_SERVICE_SCHED, pf->state);\n+\n+\terr = i40e_init_interrupt_scheme(pf);\n+\tif (err)\n+\t\tgoto err_switch_setup;\n+\n+\t/* The number of VSIs reported by the FW is the minimum guaranteed\n+\t * to us; HW supports far more and we share the remaining pool with\n+\t * the other PFs. We allocate space for more than the guarantee with\n+\t * the understanding that we might not get them all later.\n+\t */\n+\tif (pf->hw.func_caps.num_vsis < I40E_MIN_VSI_ALLOC)\n+\t\tpf->num_alloc_vsi = I40E_MIN_VSI_ALLOC;\n+\telse\n+\t\tpf->num_alloc_vsi = pf->hw.func_caps.num_vsis;\n+\n+\t/* Set up the *vsi struct and our local tracking of the MAIN PF vsi. */\n+\tpf->vsi = kcalloc(pf->num_alloc_vsi, sizeof(struct i40e_vsi *),\n+\t\t\t  GFP_KERNEL);\n+\tif (!pf->vsi) {\n+\t\terr = -ENOMEM;\n+\t\tgoto err_switch_setup;\n+\t}\n+\n+\tv_idx = i40e_vsi_mem_alloc(pf, I40E_VSI_MAIN);\n+\tif (v_idx < 0)\n+\t\tgoto err_switch_setup;\n+\tvsi = pf->vsi[v_idx];\n+\tif (!vsi)\n+\t\tgoto err_switch_setup;\n+\terr = i40e_config_netdev(vsi);\n+\tif (err)\n+\t\tgoto err_switch_setup;\n+\terr = register_netdev(vsi->netdev);\n+\tif (err)\n+\t\tgoto err_switch_setup;\n+\ti40e_dbg_pf_init(pf);\n+\n+\t/* tell the firmware that we're starting */\n+\ti40e_send_version(pf);\n+\n+\t/* since everything's happy, start the service_task timer */\n+\tmod_timer(&pf->service_timer,\n+\t\t  round_jiffies(jiffies + pf->service_timer_period));\n+\n+\treturn 0;\n+\n+err_switch_setup:\n+\ti40e_reset_interrupt_capability(pf);\n+\tdel_timer_sync(&pf->service_timer);\n+err_sw_init:\n+\ti40e_shutdown_adminq(hw);\n+\tiounmap(hw->hw_addr);\n+\tkfree(pf);\n+\tpci_disable_pcie_error_reporting(pf->pdev);\n+\tpci_release_selected_regions(pf->pdev,\n+\t\t\t\t     pci_select_bars(pf->pdev,\n+\t\t\t\t\t\t     IORESOURCE_MEM));\n+\tpci_disable_device(pf->pdev);\n+\n+\treturn err;\n+}\n+\n+/**\n  * i40e_probe - Device initialization routine\n  * @pdev: PCI device information struct\n  * @ent: entry in i40e_pci_tbl\n@@ -13708,6 +13861,11 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)\n \t\tdev_warn(&pdev->dev, \"This device is a pre-production adapter/LOM. Please be aware there may be issues with your hardware. If you are experiencing problems please contact your Intel or hardware representative who provided you with this hardware.\\n\");\n \n \ti40e_clear_pxe_mode(hw);\n+\n+\tif (pf->hw.mac.type == I40E_MAC_X722)\n+\t\tif (i40e_check_recovery_mode(pf))\n+\t\t\treturn i40e_init_recovery_mode(pf, hw);\n+\n \terr = i40e_get_capabilities(pf, i40e_aqc_opc_list_func_capabilities);\n \tif (err)\n \t\tgoto err_adminq_setup;\n@@ -14100,6 +14258,19 @@ static void i40e_remove(struct pci_dev *pdev)\n \tif (pf->service_task.func)\n \t\tcancel_work_sync(&pf->service_task);\n \n+\tif (test_bit(__I40E_RECOVERY_MODE, pf->state)) {\n+\t\tstruct i40e_vsi *vsi = pf->vsi[0];\n+\n+\t\t/* We know that we have allocated only one vsi for this PF,\n+\t\t * * it was just for registering netdevice, so the interface\n+\t\t * could be visible in the 'ifconfig' output\n+\t\t */\n+\t\tunregister_netdev(vsi->netdev);\n+\t\tfree_netdev(vsi->netdev);\n+\n+\t\tgoto unmap;\n+\t}\n+\n \t/* Client close must be called explicitly here because the timer\n \t * has been stopped.\n \t */\n@@ -14149,6 +14320,7 @@ static void i40e_remove(struct pci_dev *pdev)\n \t\t\t\t ret_code);\n \t}\n \n+unmap:\n \t/* shutdown the adminq */\n \ti40e_shutdown_adminq(hw);\n \n",
    "prefixes": [
        "next",
        "S94",
        "01/13"
    ]
}