get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 2175402,
    "url": "http://patchwork.ozlabs.org/api/patches/2175402/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20251218015758.682498-1-yury.norov@gmail.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": "<20251218015758.682498-1-yury.norov@gmail.com>",
    "list_archive_url": null,
    "date": "2025-12-18T01:57:57",
    "name": "[v2] i40e: drop useless bitmap_weight() call in i40e_set_rxfh_fields()",
    "commit_ref": null,
    "pull_url": null,
    "state": "under-review",
    "archived": false,
    "hash": "14d8b33a26ee03965c2a13cf72866fc967720b3d",
    "submitter": {
        "id": 66118,
        "url": "http://patchwork.ozlabs.org/api/people/66118/?format=api",
        "name": "Yury Norov (NVIDIA)",
        "email": "yury.norov@gmail.com"
    },
    "delegate": {
        "id": 109701,
        "url": "http://patchwork.ozlabs.org/api/users/109701/?format=api",
        "username": "anguy11",
        "first_name": "Anthony",
        "last_name": "Nguyen",
        "email": "anthony.l.nguyen@intel.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20251218015758.682498-1-yury.norov@gmail.com/mbox/",
    "series": [
        {
            "id": 485780,
            "url": "http://patchwork.ozlabs.org/api/series/485780/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=485780",
            "date": "2025-12-18T01:57:57",
            "name": "[v2] i40e: drop useless bitmap_weight() call in i40e_set_rxfh_fields()",
            "version": 2,
            "mbox": "http://patchwork.ozlabs.org/series/485780/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2175402/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2175402/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@legolas.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=osuosl.org header.i=@osuosl.org header.a=rsa-sha256\n header.s=default header.b=NgL9lUxP;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=osuosl.org\n (client-ip=140.211.166.137; helo=smtp4.osuosl.org;\n envelope-from=intel-wired-lan-bounces@osuosl.org;\n receiver=patchwork.ozlabs.org)"
        ],
        "Received": [
            "from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4dWv2S3SqFz1xty\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 18 Dec 2025 12:58:06 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby smtp4.osuosl.org (Postfix) with ESMTP id 316E640A3C;\n\tThu, 18 Dec 2025 01:58:04 +0000 (UTC)",
            "from smtp4.osuosl.org ([127.0.0.1])\n by localhost (smtp4.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id cVH5f2LnK-fy; Thu, 18 Dec 2025 01:58:03 +0000 (UTC)",
            "from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142])\n\tby smtp4.osuosl.org (Postfix) with ESMTP id 5F22440F75;\n\tThu, 18 Dec 2025 01:58:03 +0000 (UTC)",
            "from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138])\n by lists1.osuosl.org (Postfix) with ESMTP id 76D582A2\n for <intel-wired-lan@lists.osuosl.org>; Thu, 18 Dec 2025 01:58:02 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n by smtp1.osuosl.org (Postfix) with ESMTP id 68A7B8248C\n for <intel-wired-lan@lists.osuosl.org>; Thu, 18 Dec 2025 01:58:02 +0000 (UTC)",
            "from smtp1.osuosl.org ([127.0.0.1])\n by localhost (smtp1.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id gcVQ6pNhgQn5 for <intel-wired-lan@lists.osuosl.org>;\n Thu, 18 Dec 2025 01:58:01 +0000 (UTC)",
            "from mail-yx1-xb130.google.com (mail-yx1-xb130.google.com\n [IPv6:2607:f8b0:4864:20::b130])\n by smtp1.osuosl.org (Postfix) with ESMTPS id 7EFD582423\n for <intel-wired-lan@lists.osuosl.org>; Thu, 18 Dec 2025 01:58:01 +0000 (UTC)",
            "by mail-yx1-xb130.google.com with SMTP id\n 956f58d0204a3-6447743ce59so113778d50.0\n for <intel-wired-lan@lists.osuosl.org>; Wed, 17 Dec 2025 17:58:01 -0800 (PST)",
            "from localhost ([2601:346:0:79bd:52c0:aec0:bf15:a891])\n by smtp.gmail.com with ESMTPSA id\n 956f58d0204a3-646636e86ccsm472527d50.5.2025.12.17.17.57.59\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Wed, 17 Dec 2025 17:57:59 -0800 (PST)"
        ],
        "X-Virus-Scanned": [
            "amavis at osuosl.org",
            "amavis at osuosl.org"
        ],
        "X-Comment": "SPF check N/A for local connections - client-ip=140.211.166.142;\n helo=lists1.osuosl.org; envelope-from=intel-wired-lan-bounces@osuosl.org;\n receiver=<UNKNOWN> ",
        "DKIM-Filter": [
            "OpenDKIM Filter v2.11.0 smtp4.osuosl.org 5F22440F75",
            "OpenDKIM Filter v2.11.0 smtp1.osuosl.org 7EFD582423"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org;\n\ts=default; t=1766023083;\n\tbh=bQOfmftLH8KAfTXHZBw4TB9dKu3rPCHujQ+Dm7h606A=;\n\th=From:To:Cc:Date:Subject:List-Id:List-Unsubscribe:List-Archive:\n\t List-Post:List-Help:List-Subscribe:From;\n\tb=NgL9lUxPAMStrgd0tvm/1FlZfHh2ZLZMS4UQ2kPGcKX2E6o+HH0ujQOpaZT/Tkneb\n\t ZfovDTsFfJSeAZgPbfmKBis4A5BhSdIMjifIwL67chzQQwAD9R4BBiQ9q+Bs7t9sZ/\n\t bV3gcPCVOfqLuFj9Gm8AIhkZA1CyiF6WeHE2cLKWuw5AR41TFKyVjtxGxOVLbHXEkI\n\t P0UX0bDMxITTStIsKC6jCVDLQiD4uAL5fq6M4pAKZf6+NuGIRsniyIi00VxqsGfTZZ\n\t pqzN3B0C3lcBRzuFeEa4FkdW7kr9ZOb8TY2c02tesc6fHVNn01KllQ7bS0waFT0ivi\n\t Z8W7HDOJKLCpg==",
        "Received-SPF": "Pass (mailfrom) identity=mailfrom;\n client-ip=2607:f8b0:4864:20::b130; helo=mail-yx1-xb130.google.com;\n envelope-from=yury.norov@gmail.com; receiver=<UNKNOWN>",
        "DMARC-Filter": "OpenDMARC Filter v1.4.2 smtp1.osuosl.org 7EFD582423",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1766023080; x=1766627880;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date\n :message-id:reply-to;\n bh=bQOfmftLH8KAfTXHZBw4TB9dKu3rPCHujQ+Dm7h606A=;\n b=rC6rNkeoBf6Kig1O5W/mZ/KKpg0lQXluDR8DsvyM+35thua8JvSbvub12h4F/LqDqu\n 4QzdQWqkEmw+kdvKr9B5chtPXoM9FTxWcnNjqegAXROe0rbaVKNtsjh4hsFD2/zmjCw7\n OHXWTavBOd1clLGbq6FQ8le8EKzxtuJRqBrGB2C/BGDkHouIcZHw9vnm0SHCW3icM2C4\n qmT32Aq8Cn3sJUYpi0fPG/11NvCkYrDbRvABnAvR9FsrovlN6Moe1ooLJ+rwVeq28OMJ\n 2vWn6HAvxzOYh4WtdmCRL3NhSitAEsLPTYjm4JNrw1w5LUJ6pujFdj+nvnClBhauVbpA\n w4mg==",
        "X-Forwarded-Encrypted": "i=1;\n AJvYcCVGPDpRks6pifw9OsGdAhl6niAllsQRhIcM8nOqwfNv+ZMu2fxNo9Q067OgkHRFYNOajC4oX6AoshImmInakTA=@lists.osuosl.org",
        "X-Gm-Message-State": "AOJu0YxWjvGbTAhB0cTPsBqhUmVtAHy50uBxImz4k2WULO0KCsXjvkbI\n HS4wg90QSFfjvAx8CSznWT9pbkx0SoDYQmajToA1tZvfKrTZUnmlu7gF",
        "X-Gm-Gg": "AY/fxX7I/OXRkf6beeP4lE4vCNzW4Az4R7icLg+kgspJnlMYyAaAXRc05n/YBHtKD2l\n uXD7/YibuQUe6N1bmnFRvHJnRh/1Tcse4eKk1/3y8lC1BA/i2N0Emos97lPUE77uC37ZB2kU7fg\n xR+PITSmbj4P0PooUcEBZSw+6u+Gb9YVTqDRcflRPSyqL1DvngXfUt5I/z65INkDYtEQ4L6VKOn\n Cew5+CzK8kCx124sJwvmN1EHalvgFhqpCOXr16agO1wYwzgyg0VinjTWP0WfKv7y/SvoWc5h6l6\n v6hvYwGTGT6DuobBD7ePTEWc2KrocdpOKoHcLIJwERN3nhpzwWIN7qDSsqLk/hRDwmD704gX0Hj\n EjB/lG+hqi2vnM/3R/6FZv4j88Imu0rgLBp3fYdx6Rf16w0Lk69kppARQHbpOUdkjzDLHY6PNpv\n Xt9M7VYDo=",
        "X-Google-Smtp-Source": "\n AGHT+IF7Lkwj0sSdZaNQ3dsB15WX1orUqF+lFaxr1wSODVAJtotITBD0kMje1L4hZ+gr1DxEnLMwlw==",
        "X-Received": "by 2002:a05:690e:1407:b0:644:60d9:865a with SMTP id\n 956f58d0204a3-6455567d629mr14606696d50.93.1766023080117;\n Wed, 17 Dec 2025 17:58:00 -0800 (PST)",
        "From": "\"Yury Norov (NVIDIA)\" <yury.norov@gmail.com>",
        "To": "Tony Nguyen <anthony.l.nguyen@intel.com>,\n Przemek Kitszel <przemyslaw.kitszel@intel.com>,\n Andrew Lunn <andrew+netdev@lunn.ch>,\n \"David S. Miller\" <davem@davemloft.net>,\n Eric Dumazet <edumazet@google.com>, Jakub Kicinski <kuba@kernel.org>,\n Paolo Abeni <pabeni@redhat.com>, intel-wired-lan@lists.osuosl.org,\n netdev@vger.kernel.org, linux-kernel@vger.kernel.org",
        "Cc": "\"Yury Norov (NVIDIA)\" <yury.norov@gmail.com>,\n \"Loktionov, Aleksandr\" <aleksandr.loktionov@intel.com>",
        "Date": "Wed, 17 Dec 2025 20:57:57 -0500",
        "Message-ID": "<20251218015758.682498-1-yury.norov@gmail.com>",
        "X-Mailer": "git-send-email 2.43.0",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-Mailman-Original-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=gmail.com; s=20230601; t=1766023080; x=1766627880; darn=lists.osuosl.org;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:from:to:cc:subject:date:message-id:reply-to;\n bh=bQOfmftLH8KAfTXHZBw4TB9dKu3rPCHujQ+Dm7h606A=;\n b=Z7YHdnpELUCpdwpTVWtLTICV6VtpvebCXRkg5Fopr1X1fy+Mxc/qeIc15KNY8IA7V0\n RxI/TcXdPTr+r15ynPu0xcJiqJdwCwGdg/jwQ/7ZPrNmQQtmUt/Ka38CbTLK7vpW/IBM\n AXmdHb46RJjaxxcZ1YG5QnZ7vUtDASa+fnhA0unqvYw8+cByhAY5I/ozIsweb+Xk/rB2\n eB2e5zQ5uKtIQ7eR4Yvz6ISN43RH0ZregZunVJM1q/tgJjtyH4DBabMk0cb84d6k1YTu\n rGBvP0RTBZNEnQmcr+CEsuu6Xx0lTILOIvNd+QTK9Su4ARDigu7ZMw5x60i5r+f9GzIq\n WsIw==",
        "X-Mailman-Original-Authentication-Results": [
            "smtp1.osuosl.org;\n dmarc=pass (p=none dis=none)\n header.from=gmail.com",
            "smtp1.osuosl.org;\n dkim=pass (2048-bit key,\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20230601 header.b=Z7YHdnpE"
        ],
        "Subject": "[Intel-wired-lan] [PATCH v2] i40e: drop useless bitmap_weight()\n call in i40e_set_rxfh_fields()",
        "X-BeenThere": "intel-wired-lan@osuosl.org",
        "X-Mailman-Version": "2.1.30",
        "Precedence": "list",
        "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n <intel-wired-lan.osuosl.org>",
        "List-Unsubscribe": "<https://lists.osuosl.org/mailman/options/intel-wired-lan>,\n <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 <mailto:intel-wired-lan-request@osuosl.org?subject=subscribe>",
        "Errors-To": "intel-wired-lan-bounces@osuosl.org",
        "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@osuosl.org>"
    },
    "content": "bitmap_weight() is O(N) and useless here, because the following\nfor_each_set_bit() returns immediately in case of empty flow_pctypes.\n\nSigned-off-by: Yury Norov (NVIDIA) <yury.norov@gmail.com>\n---\nv1: https://lore.kernel.org/all/20251216002852.334561-1-yury.norov@gmail.com/\nv2: don't drop flow_id (Aleksandr).\n\n .../net/ethernet/intel/i40e/i40e_ethtool.c    | 21 +++++++------------\n 1 file changed, 8 insertions(+), 13 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\nindex f2c2646ea298..e64880b6b047 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\n@@ -3637,6 +3637,7 @@ static int i40e_set_rxfh_fields(struct net_device *netdev,\n \t\t   ((u64)i40e_read_rx_ctl(hw, I40E_PFQF_HENA(1)) << 32);\n \tDECLARE_BITMAP(flow_pctypes, FLOW_PCTYPES_SIZE);\n \tu64 i_set, i_setc;\n+\tu8 flow_id;\n \n \tbitmap_zero(flow_pctypes, FLOW_PCTYPES_SIZE);\n \n@@ -3720,20 +3721,14 @@ static int i40e_set_rxfh_fields(struct net_device *netdev,\n \t\treturn -EINVAL;\n \t}\n \n-\tif (bitmap_weight(flow_pctypes, FLOW_PCTYPES_SIZE)) {\n-\t\tu8 flow_id;\n+\tfor_each_set_bit(flow_id, flow_pctypes, FLOW_PCTYPES_SIZE) {\n+\t\ti_setc = (u64)i40e_read_rx_ctl(hw, I40E_GLQF_HASH_INSET(0, flow_id)) |\n+\t\t\t ((u64)i40e_read_rx_ctl(hw, I40E_GLQF_HASH_INSET(1, flow_id)) << 32);\n+\t\ti_set = i40e_get_rss_hash_bits(&pf->hw, nfc, i_setc);\n \n-\t\tfor_each_set_bit(flow_id, flow_pctypes, FLOW_PCTYPES_SIZE) {\n-\t\t\ti_setc = (u64)i40e_read_rx_ctl(hw, I40E_GLQF_HASH_INSET(0, flow_id)) |\n-\t\t\t\t ((u64)i40e_read_rx_ctl(hw, I40E_GLQF_HASH_INSET(1, flow_id)) << 32);\n-\t\t\ti_set = i40e_get_rss_hash_bits(&pf->hw, nfc, i_setc);\n-\n-\t\t\ti40e_write_rx_ctl(hw, I40E_GLQF_HASH_INSET(0, flow_id),\n-\t\t\t\t\t  (u32)i_set);\n-\t\t\ti40e_write_rx_ctl(hw, I40E_GLQF_HASH_INSET(1, flow_id),\n-\t\t\t\t\t  (u32)(i_set >> 32));\n-\t\t\thena |= BIT_ULL(flow_id);\n-\t\t}\n+\t\ti40e_write_rx_ctl(hw, I40E_GLQF_HASH_INSET(0, flow_id), (u32)i_set);\n+\t\ti40e_write_rx_ctl(hw, I40E_GLQF_HASH_INSET(1, flow_id), (u32)(i_set >> 32));\n+\t\thena |= BIT_ULL(flow_id);\n \t}\n \n \ti40e_write_rx_ctl(hw, I40E_PFQF_HENA(0), (u32)hena);\n",
    "prefixes": [
        "v2"
    ]
}