{"id":2234732,"url":"http://patchwork.ozlabs.org/api/1.2/patches/2234732/?format=json","web_url":"http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20260508031226.3601800-5-aleksandr.loktionov@intel.com/","project":{"id":46,"url":"http://patchwork.ozlabs.org/api/1.2/projects/46/?format=json","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":"<20260508031226.3601800-5-aleksandr.loktionov@intel.com>","list_archive_url":null,"date":"2026-05-08T03:12:22","name":"[iwl-next,4/8] ixgbe: increase SECRX_RDY polling frequency in ixgbe_disable_rx_buff_generic","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"f240299b4ace1518174fde4e0e0fff4161268bea","submitter":{"id":75597,"url":"http://patchwork.ozlabs.org/api/1.2/people/75597/?format=json","name":"Loktionov, Aleksandr","email":"aleksandr.loktionov@intel.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20260508031226.3601800-5-aleksandr.loktionov@intel.com/mbox/","series":[{"id":503311,"url":"http://patchwork.ozlabs.org/api/1.2/series/503311/?format=json","web_url":"http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=503311","date":"2026-05-08T03:12:18","name":"ixgbe: small cleanups and improvements","version":1,"mbox":"http://patchwork.ozlabs.org/series/503311/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2234732/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2234732/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=RQuYCKZu;\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 4gBZ1V60spz1yJq\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 08 May 2026 13:12:46 +1000 (AEST)","from localhost (localhost [127.0.0.1])\n\tby smtp4.osuosl.org (Postfix) with ESMTP id 4B2CD4145C;\n\tFri,  8 May 2026 03:12:39 +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 dCEVfPf2FOTv; Fri,  8 May 2026 03:12:38 +0000 (UTC)","from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142])\n\tby smtp4.osuosl.org (Postfix) with ESMTP id 17F234145B;\n\tFri,  8 May 2026 03:12:38 +0000 (UTC)","from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133])\n by lists1.osuosl.org (Postfix) with ESMTP id 46B7A272\n for <intel-wired-lan@lists.osuosl.org>; Fri,  8 May 2026 03:12:36 +0000 (UTC)","from localhost (localhost [127.0.0.1])\n by smtp2.osuosl.org (Postfix) with ESMTP id 389D8409B3\n for <intel-wired-lan@lists.osuosl.org>; Fri,  8 May 2026 03:12:36 +0000 (UTC)","from smtp2.osuosl.org ([127.0.0.1])\n by localhost (smtp2.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP\n id 2RRO1vXijxwk for <intel-wired-lan@lists.osuosl.org>;\n Fri,  8 May 2026 03:12:35 +0000 (UTC)","from mgamail.intel.com (mgamail.intel.com [192.198.163.17])\n by smtp2.osuosl.org (Postfix) with ESMTPS id 24A7B4030E\n for <intel-wired-lan@lists.osuosl.org>; Fri,  8 May 2026 03:12:35 +0000 (UTC)","from fmviesa005.fm.intel.com ([10.60.135.145])\n by fmvoesa111.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 07 May 2026 20:12:35 -0700","from amlin-019-225.igk.intel.com ([10.102.19.225])\n by fmviesa005.fm.intel.com with ESMTP; 07 May 2026 20:12:34 -0700"],"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 17F234145B","OpenDKIM Filter v2.11.0 smtp2.osuosl.org 24A7B4030E"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org;\n\ts=default; t=1778209958;\n\tbh=FWeMcMH4Y7gba5572DmLBG8HvXsFTUSzXvdhjzkrpdM=;\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=RQuYCKZuSagM5w6LGiEa4GmWhMiJySlHFUfdbGiE0g5L5536Tu3mCZCvRq9N55Y8y\n\t xKepsmeo7N0ZE2wGobpphGRql+8F0351qhNqDp1rwigzSGtuUsRkIEmTNvNyYkjXE+\n\t QoXBpXM2jSOfT3eaSg5lLOT4XrGtt691HqXsd+wRgauUcOeY6GfmuXWzY8i8J9s1SL\n\t 1pAjHQpiLVZPbqOzoyoT6seKxQDIfWoHldvaobjElQW9koOOq6Ee29kHjt6KhXhoAO\n\t jiTfs+yEN1bFP1Zmo2od5tFIaMEXGArHrRlxk24/ZjyDLZIgU3i3AprS+C/miSCQLb\n\t Xrd+P8/NwlZ7g==","Received-SPF":"Pass (mailfrom) identity=mailfrom; client-ip=192.198.163.17;\n helo=mgamail.intel.com; envelope-from=aleksandr.loktionov@intel.com;\n receiver=<UNKNOWN>","DMARC-Filter":"OpenDMARC Filter v1.4.2 smtp2.osuosl.org 24A7B4030E","X-CSE-ConnectionGUID":["5ePhOdTJSoiKHUTl1DCJqw==","5yJMNqWSQUqKtuGONmWiwQ=="],"X-CSE-MsgGUID":["fjlLbu11TB+LcrZDCHNv9Q==","7mzQEoI5QO2MZbBwMkcYrw=="],"X-IronPort-AV":["E=McAfee;i=\"6800,10657,11779\"; a=\"79027503\"","E=Sophos;i=\"6.23,222,1770624000\"; d=\"scan'208\";a=\"79027503\"","E=Sophos;i=\"6.23,222,1770624000\"; d=\"scan'208\";a=\"241623201\""],"X-ExtLoop1":"1","From":"Aleksandr Loktionov <aleksandr.loktionov@intel.com>","To":"intel-wired-lan@lists.osuosl.org, anthony.l.nguyen@intel.com,\n aleksandr.loktionov@intel.com","Cc":"netdev@vger.kernel.org","Date":"Fri,  8 May 2026 05:12:22 +0200","Message-ID":"<20260508031226.3601800-5-aleksandr.loktionov@intel.com>","X-Mailer":"git-send-email 2.52.0","In-Reply-To":"<20260508031226.3601800-1-aleksandr.loktionov@intel.com>","References":"<20260508031226.3601800-1-aleksandr.loktionov@intel.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","X-Mailman-Original-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple;\n d=intel.com; i=@intel.com; q=dns/txt; s=Intel;\n t=1778209955; x=1809745955;\n h=from:to:cc:subject:date:message-id:in-reply-to:\n references:mime-version:content-transfer-encoding;\n bh=cyk7C6u2sQlQMQ/Lr6UpLcUYzBBZP3dUYKCPN5FKMgg=;\n b=TOKw2stFzwWHzxgJeGgaDDsCk63rAq9uNcDvaCKQ5DH85K/oRj1aZG94\n LJEeDg0PvVHv7ZbQ8cN87TVbM+TuGYg6isw9rEyRWUa3ai0P2ffJxR4SN\n Hh2I3f+EQoPEsE6nupqb7+AOiRnNSqq81favawa12tLoij/lE4lKVy6va\n DHGVYyrxfgBA2dreEtZXua3TNVPErGyPsikCMx5eF1VOimugRxVYEYvxG\n gAPJ6wgtlqJ20PIX8nEZ2xYRKvJGT82G29XKFZ241epHxNbmTCEQkSzLf\n wq6pZLOwoBcRSBXhPBwcl8GrBoS+CRvL9YTC52DO15I00Agy4VTvIw5VL\n A==;","X-Mailman-Original-Authentication-Results":["smtp2.osuosl.org;\n dmarc=pass (p=none dis=none)\n header.from=intel.com","smtp2.osuosl.org;\n dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com\n header.a=rsa-sha256 header.s=Intel header.b=TOKw2stF"],"Subject":"[Intel-wired-lan] [PATCH iwl-next 4/8] ixgbe: increase SECRX_RDY\n polling frequency in ixgbe_disable_rx_buff_generic","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":"From: Maciej Rabeda <maciej.rabeda@intel.com>\n\nixgbe_disable_rx_buff_generic polls for SECRX_RDY with 40 iterations\nand a 1000 us (1 ms) busy-wait per iteration via udelay(), giving an\nexact total wait of 40 ms.  On fast hardware the security block is\ntypically ready well under 1 ms, so each iteration wastes up to\n999 us of stalled initialization time.\n\nReplace udelay(1000) with usleep_range(10, 20) and raise the iteration\nlimit to 4000.  Because usleep_range(min, max) is guaranteed to sleep\nat least 'min' microseconds, 4000 * 10 us preserves the original 40 ms\nminimum wait before timeout.  The worst-case is now ~80 ms (4000 * 20\nus) plus scheduler latency, which is acceptable since SECRX_RDY\nfailing to assert is a non-fatal informational condition (the function\njust logs a debug message).\n\nOn platforms where SECRX_RDY asserts quickly this reduces the typical\nstall from up to ~1 ms per iteration to ~10-20 us.  The function is\ncalled only from process context, so usleep_range is appropriate.\n\nSigned-off-by: Maciej Rabeda <maciej.rabeda@intel.com>\nSigned-off-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>\n---\n drivers/net/ethernet/intel/ixgbe/ixgbe_common.c | 5 ++---\n 1 file changed, 2 insertions(+), 3 deletions(-)","diff":"diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c\nindex 3ea6765..c85618c 100644\n--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c\n+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_common.c\n@@ -2683,7 +2683,7 @@ int prot_autoc_write_generic(struct ixgbe_hw *hw, u32 reg_val, bool locked)\n  **/\n int ixgbe_disable_rx_buff_generic(struct ixgbe_hw *hw)\n {\n-#define IXGBE_MAX_SECRX_POLL 40\n+#define IXGBE_MAX_SECRX_POLL 4000\n \tint i;\n \tint secrxreg;\n \n@@ -2695,8 +2695,7 @@ int ixgbe_disable_rx_buff_generic(struct ixgbe_hw *hw)\n \t\tif (secrxreg & IXGBE_SECRXSTAT_SECRX_RDY)\n \t\t\tbreak;\n \t\telse\n-\t\t\t/* Use interrupt-safe sleep just in case */\n-\t\t\tudelay(1000);\n+\t\t\tusleep_range(10, 20);\n \t}\n \n \t/* For informational purposes only */\n","prefixes":["iwl-next","4/8"]}