From nobody Fri Apr 24 18:38:15 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 4g2MCq6znsz6b2GV for ; Fri, 24 Apr 2026 18:38:15 +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 "R13" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4g2MCq6Dhhz47gw for ; Fri, 24 Apr 2026 18:38:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1777055895; 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=81IDSCpKUloPa9MlMg4RGz/+4K+mb7F2DG7PeXt+fJA=; b=D6pinE+12CQLwK9ZrLVFjpPSH/r1TdanGr7rClX6ucxGuRh9ahUThwy3kkN0gB+xks8b9E amiyzZQmQg5KaWCkBMZ3t458nw88h3dXpfSVHspezOYYWc4taeJX+gF0bhAlR4wOWWdTJJ ZAqecmF5KIyg3jxZn+SIeXRePSMaJquXKZeU6rxUo3/CtDtHble3EqapMh0/WS51tJWjYe IGSzjD+NOhU4ZPMmdeNiIOLw6jhB87SCUkYqDF2PncygosNYtbinsHQ8jEW6UosGYeiJ33 +x/6XjBIa8Hf4ey5duhpy6ynjcBL5lbjbGvUf7iqNGi8QpDIi4MEmHA3ESTmPw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1777055895; a=rsa-sha256; cv=none; b=mkm/5AYlWD7yp5Eqc/k71jJR/SvwYMratOA7blKzclSzc0NC9b9a8j2Jl7ufwc/7Pn/MOB 00thXszmtbqbZL7HxMXSqVxrqSJPd66A3vc4VN2j0xm1tJATRv+JCEM5ac+XpbNfuVnli/ hhUgpY8xK1ZYR9HmuzSgOxyJ7KLAv/JpZ1Jk+S/qRgP293Eof6sLHoqut6xmfCpuuLaJOm bcGEjNm6gub6iDIEGeYR4NiudyttYnK3sK5IS4eLhc3tA7fOtw66nmYxIts+XP9Pnf5r0g iWQrVATYH8XJSZmSnzRcmqkQmVWLlRtw4b+XSU+adNWhrg1m9YLix2PvG+3G5Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1777055895; 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=81IDSCpKUloPa9MlMg4RGz/+4K+mb7F2DG7PeXt+fJA=; b=PGTi28mY4E+sGl2m5gx79l56VtXWHgdxAoqgTLW+9erlxHcTdzqQhjpYRBC0rcRBn4fWj3 XoI0nUbSmAoDpIf+8twJHT9I3LvBkkaW9OQj2HkyWQZ0xfmtBSd+/7PhL7ayc5CHlL4udq LSTHfKkm3YvfwGL01cByh98dF8IeVeQm3emt4KeEhe9XgKs3AkvVfnXusZejCGhTB91i72 Q4x/mN93DYR7xMXWWeTurrgdZNjnEHxdGpvJWJKhT4i6ZcJ7Q0S9DKFFIwYgksppqRHQ4+ PDcpFtgauxGQHW/842Z6LzMEJq301NjdKX6EYjspzQ2CluTEXevng7Z/nzeCCg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4g2MCq5V9tz1D4Q for ; Fri, 24 Apr 2026 18:38:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 220ac by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 24 Apr 2026 18:38:15 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 3454d97aaec1 - main - cam: Set ccb_h.status on XPT_GDEVLIST early-return paths 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 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3454d97aaec12f4a8c676c34182200471eecae24 Auto-Submitted: auto-generated Date: Fri, 24 Apr 2026 18:38:15 +0000 Message-Id: <69ebb897.220ac.76184070@gitrepo.freebsd.org> The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=3454d97aaec12f4a8c676c34182200471eecae24 commit 3454d97aaec12f4a8c676c34182200471eecae24 Author: Warner Losh AuthorDate: 2026-04-24 18:31:13 +0000 Commit: Warner Losh CommitDate: 2026-04-24 18:32:24 +0000 cam: Set ccb_h.status on XPT_GDEVLIST early-return paths XPT_GDEVLIST in xpt_action_default has two early-return paths (list changed and index not found) that set cgdl->status but not ccb_h.status. Since xpt_action sets ccb_h.status to CAM_REQ_INPROG before dispatching, and XPT_GDEVLIST is an non-queued CCB, cam_periph_ccbwait skips the sleep loop and immediately hits the KASSERT checking that status != CAM_REQ_INPROG, causing a panic. Set ccb_h.status = CAM_REQ_CMP at the top of the code rather than the bottom. Any future error paths will be right (since this command can't fail at the command level, just in the status of the data level). PR: 293899 Assisted-By: Claude Opus 4.6 (1M context) Sponsored by: Netflix Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D56487 --- sys/cam/cam_xpt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/cam/cam_xpt.c b/sys/cam/cam_xpt.c index f43dde8de401..605f4d8c3cf0 100644 --- a/sys/cam/cam_xpt.c +++ b/sys/cam/cam_xpt.c @@ -2779,6 +2779,7 @@ call_sim: device = path->device; periph_head = &device->periphs; cgdl = &start_ccb->cgdl; + start_ccb->ccb_h.status = CAM_REQ_CMP; /* * Check and see if the list has changed since the user @@ -2820,7 +2821,6 @@ call_sim: cgdl->index++; cgdl->generation = device->generation; - cgdl->ccb_h.status = CAM_REQ_CMP; break; } case XPT_DEV_MATCH: