From nobody Fri Jul 31 14:30:17 2026 X-Original-To: dev-commits-src-main@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 4hBT4T4hvNz6mv8m for ; Fri, 31 Jul 2026 14:30:17 +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 "YR1" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hBT4T43Dhz3g5x for ; Fri, 31 Jul 2026 14:30:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1785508217; 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=SH7xw4eq+MECXY7uGfd1srMOnXp+Ab9W6Ius1EoYseU=; b=YqL8v+zfKpUHVkcmVmxNLIZ6Q8DCwPn/GB2QDvlLzfydI9/yZPW2yjMZj9Py5UoRX1/7cu 5ZWS97cOTOVbn5aviOY0ah5qa4nWi+ZwilCuNwmxeF7gx83WO03+HSPb2zGBihiAADh51y DM9+xXh/bnHbgChEQXkL4ZO8CnWagvBH4TDhixuUek+y3TyVbrJcjo3MTnh/P19VmTH+XS gAAp13tD8xmEdyjbSG+Q//Kb1m4KfEQwnast743FdGN7AF2A1KAsTsqMy/xEipMJNvThWr kmDwv+Z/mXQIbbuzbuoEuVTG3iWgOsCjWT3zsqaNkCEC8NWYV7TZda4MmNU1UA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1785508217; a=rsa-sha256; cv=none; b=ktn3jdYe4MckAJCVwhhcxRG2dBoX7SSFjIM/5je1ng2cMMhiqSqFv5WFlgjQ1AQ+byLPwC 9A6BXPhPWEuWizAzlGF2iujq7spZxRVh44ST+Ik3i5bQ3Pr5+JPU6FXnF0UaiG0/VTz9Mk 8AnA4XbakUl4wiawjCX31OarJYwJ9zZi+3EUuSefpjDuI0HQkJoeAgJAic0Ae3BBBzzRKT +XVR3w9DYGyguOWy8vFgqiSKsv7TkezzlYcKq05wHUIbdePiMKOvSPHHbINDSa3V8dVm2Z rjswJB2N4DpJezm6Qzj0GHXw9+x5rEayl8sq86YNpttNm0tKzvd8wDi8jSOTyA== 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=1785508217; 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=SH7xw4eq+MECXY7uGfd1srMOnXp+Ab9W6Ius1EoYseU=; b=cHInHiC1k+5Z+Y9P94laIwxVZI77i9AuvIOQuFSU3I6uogcsCHRgES3ovy3s0deuyOpe1q SvRQKTtrJAxNUQemSBEuuZWhtK0jZnkXoyS2giE9jFlEVL7rMZtDsd2UswMuAtw+yy4T08 zm2CQoUPF+ozI/5EvGcJFhlf8lZWdBBc4vNf9h1YsG+ye5sxVuCpb+UW6VOCzWFwrnDuqh Bg/KHeYX9jWv+Q0xXDLvw1IdJUeDJJBkrUztU12myBD/O1q/I87mKibeYGoC06XAKNimCO /BkmdpOj5QDrZD/poVRbWToPvcFIk9oq0s1tUwirauZUtasw+b+IiGG82RamFg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hBT4T2rGvz12p5 for ; Fri, 31 Jul 2026 14:30:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 203f1 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 31 Jul 2026 14:30:17 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 1c1a3646a1c8 - main - bhyve: tpm: Avoid printing a message when clearing the cancel bit List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1c1a3646a1c86624e67a42636894fd1685386cf1 Auto-Submitted: auto-generated Date: Fri, 31 Jul 2026 14:30:17 +0000 Message-Id: <6a6cb179.203f1.35c691@gitrepo.freebsd.org> The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=1c1a3646a1c86624e67a42636894fd1685386cf1 commit 1c1a3646a1c86624e67a42636894fd1685386cf1 Author: Mark Johnston AuthorDate: 2026-07-31 14:22:46 +0000 Commit: Mark Johnston CommitDate: 2026-07-31 14:22:51 +0000 bhyve: tpm: Avoid printing a message when clearing the cancel bit Some drivers do this routinely, e.g., FreeBSD's tpm20 does this every time it sends a command in tpmcrb_transmit(). This causes the console to fill up with messages. Instead, only print a warning if the cancel bit is set to one. Reviewed by: corvink MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D52425 --- usr.sbin/bhyve/tpm_intf_crb.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/usr.sbin/bhyve/tpm_intf_crb.c b/usr.sbin/bhyve/tpm_intf_crb.c index d571e89bb5ae..7058b47733f3 100644 --- a/usr.sbin/bhyve/tpm_intf_crb.c +++ b/usr.sbin/bhyve/tpm_intf_crb.c @@ -371,11 +371,18 @@ tpm_crb_mem_handler(struct vcpu *vcpu __unused, const int dir, break; } case offsetof(struct tpm_crb_regs, ctrl_cancel): { - /* TODO: cancel the tpm command */ - warnx( - "%s: cancelling a TPM command is not implemented yet", - __func__); + union tpm_crb_reg_ctrl_cancel cancel; + + if ((size_t)size > sizeof(cancel)) + goto err_out; + tpm_crb_mmiocpy(&cancel, val, size); + if (cancel.cancel != 0) { + /* TODO: cancel the tpm command */ + warnx( + "%s: cancelling a TPM command is not implemented yet", + __func__); + } break; } case offsetof(struct tpm_crb_regs, int_enable):