From nobody Fri Sep 18 12:00:41 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4hmWRM2YZNz6sMPD for ; Fri, 18 Sep 2026 12:00:47 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hmWRM0xtkz4KtX for ; Fri, 18 Sep 2026 12:00:47 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1789732847; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cifYZcyLwGtGuZwTPp7JV/RH+1ZuJi+PqHViulyG6Hk=; b=eDxWdBR+vjgegfgaSfBY2iclapsLryt6c5tCog3IdbbLpaRISRnxiy97tlu2au4xLjInYC RSETk5KtGYW9fEKN+TPEH5CtTm8Cms5FfpfS2Wgy6FdlPxVWzeaK1hLAjsMCWnZ3hBIXyp mYBokr3LxZGGLqQioi+N2lSgTWV/2p8czV2InfjaulsPMpch9kfe3KSyAnyJmygG/xIcKC HsHXIUaZHOXeY/2NxxAZheZL3vXsSX9k6JCK7LKIJSL+dcxe+MYANU+hcEGaZo2mHM+HUP /f/4PlQfcFYEllV3U78g/ZVxHg00KIMYvBuw2YxvF7zy0VNrT6Q3eR6Uf2x3TQ== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1789732847; b=Y2XX2vmxuuCcYuA0hdYmqx0VrUY0wQcC1RrpSbveX05DyCXqoBMXoLeihVRG1DpsJRBTia 9zuzVuykPTTdaw33wAFCTfdRHv1l4EVHCBQ/4gKmhh1t5RXBVREtyLybBIg3y5Gp3ELYwX rTmmZ1pQMLhqxoTY1NEEY2W/m7jfZzpqB4gL9DPL1KG+1ohdeN0Ft0kfDOpuE/JySs5Wu9 k3uxKZ8vejEFcuYBsCR6KuGCw5MDojxWoYIFnRs/JSGdRABw+P3QimY/3ovGpQSGsMEvCB VodkbBjtbUWFDmNSiJMC18HW15aPpIdGSHTVJ+JdHQZ3iOUMQLhL29QIbw6RaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1789732847; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=cifYZcyLwGtGuZwTPp7JV/RH+1ZuJi+PqHViulyG6Hk=; b=SoWRxKsv/yoiafj5d9Px/G/nzkVuJ1PujhPJMT5PVlV0SRdmIw/To4zUq3tP11oq+6CxTH lzM/VgtepUdc+jLeCbuMQ3tcLv7Ql/Hz3PNwmC3iLcTkhC6fa9CVWRib1fUIiA8RzHPhT8 vpVa8CuUOG2h2ra77PrJkjLkJeWqBfG5gFeP98lead/myeimrMkFEwEEY1Lola7Spe3qFd 2ntl2NxVdOvsFINFDSVDfqWMxZUIKJZU/yelad4TMQzUC3buQ+/cowpuVNqoUvVl+QVIkq /zjogrCM3esM8rcjNly/PZmr2eXkYOznwgoM98UY7Z3YR8K9HTjq29ZhAZHmrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hmWRL6v5BzHrt for ; Fri, 18 Sep 2026 12:00:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3716e by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 18 Sep 2026 12:00:41 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kevin Bowling Subject: git: 3c52d24acb42 - main - iavf: Reschedule pending virtchnl replies after the processing budget List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kbowling X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3c52d24acb422f5d80f50612bd990ce760a19de8 Auto-Submitted: auto-generated Date: Fri, 18 Sep 2026 12:00:41 +0000 Message-Id: <6aad27e9.3716e.1f549f5d@gitrepo.freebsd.org> The branch main has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=3c52d24acb422f5d80f50612bd990ce760a19de8 commit 3c52d24acb422f5d80f50612bd990ce760a19de8 Author: Kevin Bowling AuthorDate: 2026-09-18 11:51:55 +0000 Commit: Kevin Bowling CommitDate: 2026-09-18 12:00:22 +0000 iavf: Reschedule pending virtchnl replies after the processing budget The VC worker ignores the pending count returned by iavf_process_adminq. If a pass exhausts its message budget, replies can remain in the receive ring without another interrupt to schedule the worker. During init, the iflib admin task cannot provide a backstop because init holds the context lock while waiting for ENABLE_QUEUES to complete. Reschedule the VC worker after a successful pass with messages remaining. Keep the per-pass budget and do not retry AdminQ errors. Stop self-rescheduling once detach clears INITIALIZED; the existing polling and reset-recovery gates continue to exclude asynchronous processing. Validation: reproduced the timeout on a three queue E835 VF under Hyper-V. Temporary tracing showed a successful ENABLE_QUEUES reply already in the guest receive ring after a three-message pass left two messages pending. With the fix and no tracing, a GENERIC kernel with WITNESS and INVARIANTS passed three batches of 30 down/up and MTU 1500/9000 cycles without enable/disable timeouts. MFC after: 2 weeks Sponsored by: BBOX.io --- sys/dev/iavf/if_iavf_iflib.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/sys/dev/iavf/if_iavf_iflib.c b/sys/dev/iavf/if_iavf_iflib.c index 0838eabbec1f..f0d1f39ee20c 100644 --- a/sys/dev/iavf/if_iavf_iflib.c +++ b/sys/dev/iavf/if_iavf_iflib.c @@ -434,9 +434,19 @@ static void iavf_vc_task(void *arg, int pending __unused) { struct iavf_sc *sc = (struct iavf_sc *)arg; - u16 var; + enum iavf_status status; + u16 remaining = 0; - iavf_process_adminq(sc, &var); + status = iavf_process_adminq(sc, &remaining); + /* + * A budget-limited pass may leave replies without another interrupt. + * Keep processing them here: init can hold the iflib context lock + * while waiting for a reply, preventing the iflib admin task from + * making progress. Do not perpetuate the task during detach. + */ + if (status == IAVF_SUCCESS && remaining != 0 && + iavf_test_state(&sc->state, IAVF_STATE_INITIALIZED)) + taskqueue_enqueue(sc->vc_tq, &sc->vc_task); } /**