Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2218551/?format=api
{ "id": 2218551, "url": "http://patchwork.ozlabs.org/api/patches/2218551/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20260401120919.282668-3-ade@amicon.ru/", "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": "<20260401120919.282668-3-ade@amicon.ru>", "list_archive_url": null, "date": "2026-04-01T12:08:24", "name": "[net-next,v3,2/2] e1000e: limit endianness conversion to boundary words", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "ea58525d0fb76f25022ab24b13461940b276576f", "submitter": { "id": 92902, "url": "http://patchwork.ozlabs.org/api/people/92902/?format=api", "name": "Agalakov Daniil", "email": "ade@amicon.ru" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20260401120919.282668-3-ade@amicon.ru/mbox/", "series": [ { "id": 498327, "url": "http://patchwork.ozlabs.org/api/series/498327/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=498327", "date": "2026-04-01T12:08:22", "name": "e1000/e1000e: limit endianness conversion to boundary words", "version": 3, "mbox": "http://patchwork.ozlabs.org/series/498327/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2218551/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2218551/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=a/O1Iqto;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=osuosl.org\n (client-ip=140.211.166.136; helo=smtp3.osuosl.org;\n envelope-from=intel-wired-lan-bounces@osuosl.org;\n receiver=patchwork.ozlabs.org)" ], "Received": [ "from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136])\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 4fm3hN49P6z1xtJ\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 01 Apr 2026 23:09:56 +1100 (AEDT)", "from localhost (localhost [127.0.0.1])\n\tby smtp3.osuosl.org (Postfix) with ESMTP id 2419B600B3;\n\tWed, 1 Apr 2026 12:09:54 +0000 (UTC)", "from smtp3.osuosl.org ([127.0.0.1])\n by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id 30SQGrmveZ0n; Wed, 1 Apr 2026 12:09:52 +0000 (UTC)", "from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142])\n\tby smtp3.osuosl.org (Postfix) with ESMTP id 93B5C607F0;\n\tWed, 1 Apr 2026 12:09:52 +0000 (UTC)", "from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138])\n by lists1.osuosl.org (Postfix) with ESMTP id 2E76D2A2\n for <intel-wired-lan@lists.osuosl.org>; Wed, 1 Apr 2026 12:09:49 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n by smtp1.osuosl.org (Postfix) with ESMTP id BDF4C80BAA\n for <intel-wired-lan@lists.osuosl.org>; Wed, 1 Apr 2026 12:09:48 +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 RIj6BlUlWY5E for <intel-wired-lan@lists.osuosl.org>;\n Wed, 1 Apr 2026 12:09:47 +0000 (UTC)", "from mail.amicon.ru (unknown [77.108.111.100])\n by smtp1.osuosl.org (Postfix) with ESMTPS id 7DF8D8084A\n for <intel-wired-lan@lists.osuosl.org>; Wed, 1 Apr 2026 12:09:47 +0000 (UTC)", "from example.com (172.16.2.46) by mail.amicon.lan (192.168.0.59)\n with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.27; Wed, 1 Apr\n 2026 15:09:38 +0300" ], "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 smtp3.osuosl.org 93B5C607F0", "OpenDKIM Filter v2.11.0 smtp1.osuosl.org 7DF8D8084A" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org;\n\ts=default; t=1775045392;\n\tbh=q8vaIuEe2cd1R5zMCTru3e62zKNn23D0Cs0EZ+avHhk=;\n\th=From:To:CC:Date:In-Reply-To:References:Subject:List-Id:\n\t List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe:\n\t From;\n\tb=a/O1IqtocKO2WC2RBt4jM2RDEQX397qyTBDJ71Oen0kCCSwCPJObwlXZ8o2zRw2Nh\n\t uqYut+9AJvsnV/PTCxN73rUXQ5fVxp31vgipeqhJGAbmPHsObNNdTomg5sLyclsJMK\n\t NQW2cBdVqjQmXaebp9w5xD90TW2AgJGC5Onk4xPgCV+fik4W7icVXidhs86wKYencu\n\t +jWOJ+eij32/dlLT8nFEUPgJSf7sTb6EPvrH5QCgNpE+DKl0U4SEzGRhHBLbj1AcBL\n\t VOSum3wwKVaqWserapdc1USMJO8gUZyJodDeXS59Rp+rVxmSNms2w1oI+9QN9rJSAy\n\t Zx2sfH7LgAukg==", "Received-SPF": "Pass (mailfrom) identity=mailfrom; client-ip=77.108.111.100;\n helo=mail.amicon.ru; envelope-from=ade@amicon.ru; receiver=<UNKNOWN>", "DMARC-Filter": "OpenDMARC Filter v1.4.2 smtp1.osuosl.org 7DF8D8084A", "Content-Transfer-Encoding": "8bit", "Content-Type": "text/plain", "From": "Agalakov Daniil <ade@amicon.ru>", "To": "Tony Nguyen <anthony.l.nguyen@intel.com>", "CC": "Agalakov Daniil <ade@amicon.ru>, Przemek Kitszel\n <przemyslaw.kitszel@intel.com>, Andrew Lunn <andrew+netdev@lunn.ch>, \"David\n S. Miller\" <davem@davemloft.net>, Eric Dumazet <edumazet@google.com>, \"Jakub\n Kicinski\" <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,\n <intel-wired-lan@lists.osuosl.org>, <netdev@vger.kernel.org>,\n <linux-kernel@vger.kernel.org>, <lvc-project@linuxtesting.org>, \"Daniil\n Iskhakov\" <dish@amicon.ru>, Roman Razov <rrv@amicon.ru>", "Date": "Wed, 1 Apr 2026 15:08:24 +0300", "Message-ID": "<20260401120919.282668-3-ade@amicon.ru>", "X-Mailer": "git-send-email 2.51.0", "In-Reply-To": "<20260401120919.282668-1-ade@amicon.ru>", "References": "<20260325151615.1407182-1-ade@amicon.ru>\n <20260401120919.282668-1-ade@amicon.ru>", "MIME-Version": "1.0", "X-Originating-IP": "[172.16.2.46]", "X-ClientProxiedBy": "mail.amicon.lan (192.168.0.59) To mail.amicon.lan\n (192.168.0.59)", "X-Mailman-Original-DKIM-Signature": "v=1; a=rsa-sha256; d=amicon.ru; s=mail;\n c=simple/simple;\n t=1775045378; h=from:subject:to:date:message-id;\n bh=d7GuwT6Jl1KQtz7eotNRQp6Eo286Tux6gD8IH2Y6PeY=;\n b=eRemQYHB779uyNY7U10z6sTwbZOkk3cqeASFZGOdut2qCgujhTL6eTZJl4jXBD/m79nNZwZ+RQH\n h1szsSisywG3l6GEydnjLtk2borwwAPVz77zqhfEB373MFggnQzgytiD70v7h1gb3X/LbeK4nbLE7\n xo3LDm1Xw8qjRoWoOIXSxuvq8PD0mFox5i7SF5dclGGuF3/33PafSSuy4EMUVg1GxuMUcq3jCljXS\n w4Rw7mNPjjaKj5YJH1XK8G7/FD76KTdtsiv3eD/jBsUfog7apH9Y+CM42Es+17Jr0wHQ//m2tlISt\n A5zY8rW7JQ5EX+1pj8kqDaTxnhFEnqynmzBg==", "X-Mailman-Original-Authentication-Results": [ "smtp1.osuosl.org;\n dmarc=pass (p=quarantine dis=none)\n header.from=amicon.ru", "smtp1.osuosl.org;\n dkim=pass (2048-bit key) header.d=amicon.ru header.i=@amicon.ru\n header.a=rsa-sha256 header.s=mail header.b=eRemQYHB" ], "Subject": "[Intel-wired-lan] [PATCH net-next v3 2/2] e1000e: limit endianness\n conversion to boundary words", "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": "[Why]\nIn e1000_set_eeprom(), the eeprom_buff is allocated to hold a range of\nwords. However, only the boundary words (the first and the last) are\npopulated from the EEPROM if the write request is not word-aligned.\nThe words in the middle of the buffer remain uninitialized because they\nare intended to be completely overwritten by the new data via memcpy().\n\nThe previous implementation had a loop that performed le16_to_cpus()\non the entire buffer. This resulted in endianness conversion being\nperformed on uninitialized memory for all interior words.\n\nFix this by converting the endianness only for the boundary words\nimmediately after they are successfully read from the EEPROM.\n\nFound by Linux Verification Center (linuxtesting.org) with SVACE.\n\nCo-developed-by: Iskhakov Daniil <dish@amicon.ru>\nSigned-off-by: Iskhakov Daniil <dish@amicon.ru>\nSigned-off-by: Agalakov Daniil <ade@amicon.ru>\n---\nv3:\n - Reverted to v1's \"check-then-convert\" logic: the return value of\n e1000_read_nvm() is now checked before performing le16_to_cpus().\n - Removed the redundant full-buffer loops that caused double endianness\n conversion in v2.\n\nv2:\n - Split from the original bugfix series and targeted at 'net-next'.\n - Removed the Fixes: tag; limiting the conversion scope is an\n improvement to avoid unnecessary processing of uninitialized memory.\n - Improved commit description for clarity.\n - Note on e1000e: this driver already contains the necessary return\n value checks for EEPROM reads, so only the endianness conversion\n cleanup is included for e1000e.\n\n drivers/net/ethernet/intel/e1000e/ethtool.c | 19 ++++++++++++-------\n 1 file changed, 12 insertions(+), 7 deletions(-)", "diff": "diff --git a/drivers/net/ethernet/intel/e1000e/ethtool.c b/drivers/net/ethernet/intel/e1000e/ethtool.c\nindex dbed30943ef4..a8b35ae41141 100644\n--- a/drivers/net/ethernet/intel/e1000e/ethtool.c\n+++ b/drivers/net/ethernet/intel/e1000e/ethtool.c\n@@ -583,20 +583,25 @@ static int e1000_set_eeprom(struct net_device *netdev,\n \t\t/* need read/modify/write of first changed EEPROM word */\n \t\t/* only the second byte of the word is being modified */\n \t\tret_val = e1000_read_nvm(hw, first_word, 1, &eeprom_buff[0]);\n+\t\tif (ret_val)\n+\t\t\tgoto out;\n+\n+\t\t/* Device's eeprom is always little-endian, word addressable */\n+\t\tle16_to_cpus(&eeprom_buff[0]);\n+\n \t\tptr++;\n \t}\n-\tif (((eeprom->offset + eeprom->len) & 1) && (!ret_val))\n+\tif ((eeprom->offset + eeprom->len) & 1) {\n \t\t/* need read/modify/write of last changed EEPROM word */\n \t\t/* only the first byte of the word is being modified */\n \t\tret_val = e1000_read_nvm(hw, last_word, 1,\n \t\t\t\t\t &eeprom_buff[last_word - first_word]);\n+\t\tif (ret_val)\n+\t\t\tgoto out;\n \n-\tif (ret_val)\n-\t\tgoto out;\n-\n-\t/* Device's eeprom is always little-endian, word addressable */\n-\tfor (i = 0; i < last_word - first_word + 1; i++)\n-\t\tle16_to_cpus(&eeprom_buff[i]);\n+\t\t/* Device's eeprom is always little-endian, word addressable */\n+\t\tle16_to_cpus(&eeprom_buff[last_word - first_word]);\n+\t}\n \n \tmemcpy(ptr, bytes, eeprom->len);\n \n", "prefixes": [ "net-next", "v3", "2/2" ] }