get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 761933,
    "url": "http://patchwork.ozlabs.org/api/patches/761933/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1494642416-21796-1-git-send-email-maurosr@linux.vnet.ibm.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": "<1494642416-21796-1-git-send-email-maurosr@linux.vnet.ibm.com>",
    "list_archive_url": null,
    "date": "2017-05-13T02:26:56",
    "name": "[net] i40e: Fix state flags for bit set and clean operations of PF",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "a352b09e4871b667123a80e3159db2e4ef29ecf5",
    "submitter": {
        "id": 71608,
        "url": "http://patchwork.ozlabs.org/api/people/71608/?format=api",
        "name": "Mauro S. M. Rodrigues",
        "email": "maurosr@linux.vnet.ibm.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/1494642416-21796-1-git-send-email-maurosr@linux.vnet.ibm.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/761933/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/761933/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"
        ],
        "Received": [
            "from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\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 3wPsP52tpXz9s7y\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat, 13 May 2017 13:13:29 +1000 (AEST)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 926D726455;\n\tSat, 13 May 2017 03:13:27 +0000 (UTC)",
            "from silver.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id nsi-efqCDoJi; Sat, 13 May 2017 03:13:24 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby silver.osuosl.org (Postfix) with ESMTP id BF47F30A48;\n\tSat, 13 May 2017 03:13:24 +0000 (UTC)",
            "from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138])\n\tby ash.osuosl.org (Postfix) with ESMTP id 63CED1BFF4E\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tSat, 13 May 2017 02:41:59 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 4BE6589747\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tSat, 13 May 2017 02:41:59 +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 9q2qT5yZRyfZ for <intel-wired-lan@lists.osuosl.org>;\n\tSat, 13 May 2017 02:41:58 +0000 (UTC)",
            "from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com\n\t[148.163.158.5])\n\tby whitealder.osuosl.org (Postfix) with ESMTPS id 809DF89713\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tSat, 13 May 2017 02:41:58 +0000 (UTC)",
            "from pps.filterd (m0098413.ppops.net [127.0.0.1])\n\tby mx0b-001b2d01.pphosted.com (8.16.0.20/8.16.0.20) with SMTP id\n\tv4D2OQpi061476 for <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 May 2017 22:27:20 -0400",
            "from e24smtp01.br.ibm.com (e24smtp01.br.ibm.com [32.104.18.85])\n\tby mx0b-001b2d01.pphosted.com with ESMTP id 2adffkdt4w-1\n\t(version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT)\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 May 2017 22:27:20 -0400",
            "from localhost\n\tby e24smtp01.br.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use\n\tOnly! Violators will be prosecuted\n\tfor <intel-wired-lan@lists.osuosl.org> from\n\t<maurosr@linux.vnet.ibm.com>; Fri, 12 May 2017 23:27:17 -0300",
            "from d24relay03.br.ibm.com (9.18.232.225)\n\tby e24smtp01.br.ibm.com (10.172.0.143) with IBM ESMTP SMTP Gateway:\n\tAuthorized Use Only! Violators will be prosecuted; \n\tFri, 12 May 2017 23:27:16 -0300",
            "from d24av01.br.ibm.com (d24av01.br.ibm.com [9.8.31.91])\n\tby d24relay03.br.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id\n\tv4D2RFBV23462016 for <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 May 2017 23:27:15 -0300",
            "from d24av01.br.ibm.com (localhost [127.0.0.1])\n\tby d24av01.br.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id\n\tv4D2REnX029063 for <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 May 2017 23:27:15 -0300",
            "from localhost ([9.85.179.115])\n\tby d24av01.br.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id\n\tv4D2RDvQ029041; Fri, 12 May 2017 23:27:14 -0300"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "delayed 00:14:37 by SQLgrey-1.7.6",
        "From": "\"Mauro S. M. Rodrigues\" <maurosr@linux.vnet.ibm.com>",
        "To": "netdev@vger.kernel.org, intel-wired-lan@lists.osuosl.org",
        "Date": "Fri, 12 May 2017 23:26:56 -0300",
        "X-Mailer": "git-send-email 2.7.4",
        "X-TM-AS-MML": "disable",
        "x-cbid": "17051302-1523-0000-0000-0000029EDFAC",
        "X-IBM-AV-DETECTION": "SAVI=unused REMOTE=unused XFE=unused",
        "x-cbparentid": "17051302-1524-0000-0000-00002A3547A9",
        "Message-Id": "<1494642416-21796-1-git-send-email-maurosr@linux.vnet.ibm.com>",
        "X-Proofpoint-Virus-Version": "vendor=fsecure engine=2.50.10432:, ,\n\tdefinitions=2017-05-13_01:, , signatures=0",
        "X-Proofpoint-Spam-Details": "rule=outbound_notspam policy=outbound score=0\n\tspamscore=0 suspectscore=0\n\tmalwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam\n\tadjust=0 reason=mlx scancount=1 engine=8.0.1-1703280000\n\tdefinitions=main-1705130046",
        "X-Mailman-Approved-At": "Sat, 13 May 2017 03:13:22 +0000",
        "Cc": "\"Mauro S. M. Rodrigues\" <maurosr@linux.vnet.ibm.com>,\n\tgpiccoli@linux.vnet.ibm.com",
        "Subject": "[Intel-wired-lan] [PATCH net] i40e: Fix state flags for bit set and\n\tclean operations of PF",
        "X-BeenThere": "intel-wired-lan@osuosl.org",
        "X-Mailman-Version": "2.1.18-1",
        "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": "Commit 0da36b9774cc (\"i40e: use DECLARE_BITMAP for state fields\")\nintroduced changes in the way i40e works with state flags converting\nthem to bitmaps using kernel bitmap API. This change introduced a\nregression due to a mistaken substitution using __I40E_VSI_DOWN instead\nof __I40E_DOWN when testing state of a PF at i40e_reset_subtask()\nfunction. This caused a flood in the kernel log with the follow message:\n\n[49.013] i40e 0002:01:00.0: bad reset request 0x00000020\n\nCommit d19cb64b9222 (\"i40e: separate PF and VSI state flags\")\nalso introduced some misuse of the VSI and PF flags, so both could be\nconsidered as the offenders.\n\nThis patch simply fixes the flags where it makes sense by changing\n__I40E_VSI_DOWN to __I40E_DOWN.\n\nFixes: 0da36b9774cc (\"i40e: use DECLARE_BITMAP for state fields\")\nFixes: d19cb64b9222 (\"i40e: separate PF and VSI state flags\")\n\nReviewed-by: Guilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>\nSigned-off-by: Mauro S. M. Rodrigues <maurosr@linux.vnet.ibm.com>\n---\n drivers/net/ethernet/intel/i40e/i40e_main.c | 36 ++++++++++++++---------------\n 1 file changed, 18 insertions(+), 18 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c\nindex d5c9c9e..150caf6 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_main.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_main.c\n@@ -295,7 +295,7 @@ 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_VSI_DOWN, pf->state) &&\n+\tif (!test_bit(__I40E_DOWN, pf->state) &&\n \t    !test_bit(__I40E_RESET_RECOVERY_PENDING, pf->state))\n \t\tqueue_work(i40e_wq, &pf->service_task);\n }\n@@ -3611,7 +3611,7 @@ static irqreturn_t i40e_intr(int irq, void *data)\n \t\t * this is not a performance path and napi_schedule()\n \t\t * can deal with rescheduling.\n \t\t */\n-\t\tif (!test_bit(__I40E_VSI_DOWN, pf->state))\n+\t\tif (!test_bit(__I40E_DOWN, pf->state))\n \t\t\tnapi_schedule_irqoff(&q_vector->napi);\n \t}\n \n@@ -3687,7 +3687,7 @@ static irqreturn_t i40e_intr(int irq, void *data)\n enable_intr:\n \t/* re-enable interrupt causes */\n \twr32(hw, I40E_PFINT_ICR0_ENA, ena_mask);\n-\tif (!test_bit(__I40E_VSI_DOWN, pf->state)) {\n+\tif (!test_bit(__I40E_DOWN, pf->state)) {\n \t\ti40e_service_event_schedule(pf);\n \t\ti40e_irq_dynamic_enable_icr0(pf, false);\n \t}\n@@ -6203,7 +6203,7 @@ static void i40e_fdir_reinit_subtask(struct i40e_pf *pf)\n {\n \n \t/* if interface is down do nothing */\n-\tif (test_bit(__I40E_VSI_DOWN, pf->state))\n+\tif (test_bit(__I40E_DOWN, pf->state))\n \t\treturn;\n \n \tif (test_bit(__I40E_FD_FLUSH_REQUESTED, pf->state))\n@@ -6344,7 +6344,7 @@ static void i40e_watchdog_subtask(struct i40e_pf *pf)\n \tint i;\n \n \t/* if interface is down do nothing */\n-\tif (test_bit(__I40E_VSI_DOWN, pf->state) ||\n+\tif (test_bit(__I40E_DOWN, pf->state) ||\n \t    test_bit(__I40E_CONFIG_BUSY, pf->state))\n \t\treturn;\n \n@@ -6399,9 +6399,9 @@ static void i40e_reset_subtask(struct i40e_pf *pf)\n \t\treset_flags |= BIT(__I40E_GLOBAL_RESET_REQUESTED);\n \t\tclear_bit(__I40E_GLOBAL_RESET_REQUESTED, pf->state);\n \t}\n-\tif (test_bit(__I40E_VSI_DOWN_REQUESTED, pf->state)) {\n-\t\treset_flags |= BIT(__I40E_VSI_DOWN_REQUESTED);\n-\t\tclear_bit(__I40E_VSI_DOWN_REQUESTED, pf->state);\n+\tif (test_bit(__I40E_DOWN_REQUESTED, pf->state)) {\n+\t\treset_flags |= BIT(__I40E_DOWN_REQUESTED);\n+\t\tclear_bit(__I40E_DOWN_REQUESTED, pf->state);\n \t}\n \n \t/* If there's a recovery already waiting, it takes\n@@ -6415,7 +6415,7 @@ static void i40e_reset_subtask(struct i40e_pf *pf)\n \n \t/* If we're already down or resetting, just bail */\n \tif (reset_flags &&\n-\t    !test_bit(__I40E_VSI_DOWN, pf->state) &&\n+\t    !test_bit(__I40E_DOWN, pf->state) &&\n \t    !test_bit(__I40E_CONFIG_BUSY, pf->state)) {\n \t\trtnl_lock();\n \t\ti40e_do_reset(pf, reset_flags, true);\n@@ -7002,7 +7002,7 @@ 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_VSI_DOWN, pf->state))\n+\tif (test_bit(__I40E_DOWN, pf->state))\n \t\tgoto clear_recovery;\n \tdev_dbg(&pf->pdev->dev, \"Rebuilding internal switch\\n\");\n \n@@ -9767,7 +9767,7 @@ int i40e_vsi_release(struct i40e_vsi *vsi)\n \t\treturn -ENODEV;\n \t}\n \tif (vsi == pf->vsi[pf->lan_vsi] &&\n-\t    !test_bit(__I40E_VSI_DOWN, pf->state)) {\n+\t    !test_bit(__I40E_DOWN, pf->state)) {\n \t\tdev_info(&pf->pdev->dev, \"Can't remove PF VSI\\n\");\n \t\treturn -ENODEV;\n \t}\n@@ -11003,7 +11003,7 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)\n \t}\n \tpf->next_vsi = 0;\n \tpf->pdev = pdev;\n-\tset_bit(__I40E_VSI_DOWN, pf->state);\n+\tset_bit(__I40E_DOWN, pf->state);\n \n \thw = &pf->hw;\n \thw->back = pf;\n@@ -11293,7 +11293,7 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)\n \t * before setting up the misc vector or we get a race and the vector\n \t * ends up disabled forever.\n \t */\n-\tclear_bit(__I40E_VSI_DOWN, pf->state);\n+\tclear_bit(__I40E_DOWN, pf->state);\n \n \t/* In case of MSIX we are going to setup the misc vector right here\n \t * to handle admin queue events etc. In case of legacy and MSI\n@@ -11448,7 +11448,7 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)\n \n \t/* Unwind what we've done if something failed in the setup */\n err_vsis:\n-\tset_bit(__I40E_VSI_DOWN, pf->state);\n+\tset_bit(__I40E_DOWN, pf->state);\n \ti40e_clear_interrupt_scheme(pf);\n \tkfree(pf->vsi);\n err_switch_setup:\n@@ -11500,7 +11500,7 @@ static void i40e_remove(struct pci_dev *pdev)\n \n \t/* no more scheduling of any task */\n \tset_bit(__I40E_SUSPENDED, pf->state);\n-\tset_bit(__I40E_VSI_DOWN, pf->state);\n+\tset_bit(__I40E_DOWN, pf->state);\n \tif (pf->service_timer.data)\n \t\tdel_timer_sync(&pf->service_timer);\n \tif (pf->service_task.func)\n@@ -11740,7 +11740,7 @@ static void i40e_shutdown(struct pci_dev *pdev)\n \tstruct i40e_hw *hw = &pf->hw;\n \n \tset_bit(__I40E_SUSPENDED, pf->state);\n-\tset_bit(__I40E_VSI_DOWN, pf->state);\n+\tset_bit(__I40E_DOWN, pf->state);\n \trtnl_lock();\n \ti40e_prep_for_reset(pf, true);\n \trtnl_unlock();\n@@ -11789,7 +11789,7 @@ static int i40e_suspend(struct pci_dev *pdev, pm_message_t state)\n \tint retval = 0;\n \n \tset_bit(__I40E_SUSPENDED, pf->state);\n-\tset_bit(__I40E_VSI_DOWN, pf->state);\n+\tset_bit(__I40E_DOWN, pf->state);\n \n \tif (pf->wol_en && (pf->flags & I40E_FLAG_WOL_MC_MAGIC_PKT_WAKE))\n \t\ti40e_enable_mc_magic_wake(pf);\n@@ -11841,7 +11841,7 @@ static int i40e_resume(struct pci_dev *pdev)\n \n \t/* handling the reset will rebuild the device state */\n \tif (test_and_clear_bit(__I40E_SUSPENDED, pf->state)) {\n-\t\tclear_bit(__I40E_VSI_DOWN, pf->state);\n+\t\tclear_bit(__I40E_DOWN, pf->state);\n \t\trtnl_lock();\n \t\ti40e_reset_and_rebuild(pf, false, true);\n \t\trtnl_unlock();\n",
    "prefixes": [
        "net"
    ]
}