From nobody Tue Dec 9 15:27:14 2025 X-Original-To: dev-commits-src-branches@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 4dQjQh55yzz6Kn7D; Tue, 09 Dec 2025 15:27:40 +0000 (UTC) (envelope-from ashafer@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4dQjQh32fjz40MJ; Tue, 09 Dec 2025 15:27:40 +0000 (UTC) (envelope-from ashafer@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1765294060; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RMylcktqDhOcdCTdOKhzsn2sdl37whIUQyndZzGar30=; b=v35ywwPRlkTKhr6XYrjJRtlsyJ66m71xOBdImdu5n/6g3FkxkdGnBAzU09Tor3R3qO65G8 VgpDMiN73a3a0Sa7kuGveYCPBuIhSYIVCgsBb7i549sV8syjWQ19V66poYv9NyHe2/i6Oj VXGVO2YTgSH2n/2yTN8Qd6lmEzeDqCljBMJ78gWwC0tvz0ME5FT0qW8dM08we4on0ThOZL KxcsElGWvm0lq6aR3m/vOJjT2i+K5yh+obXsT++FRbLPYD3/PHXv4QB1Xhkx6rKR9eaQO0 sqrtHQsbNC+wfacLGFvBJYTSYjcsxXKhSm0GQ/UjjjgknZwd2B4PpvMnqkK7Jg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1765294060; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RMylcktqDhOcdCTdOKhzsn2sdl37whIUQyndZzGar30=; b=jl30mjMQFZh11yNnG3zahN4/+KGCwxaQFV2kCdphl8lSbGS4DFX4M5yZgpl21x0WVIQ9qQ RiHkX2I/UmY2YfUSM5JHJ6r9buFZ09v5TTGVa2EecYl2lsE1+zDFaITK8tdB17sWj0boJr gtGQ6BlAeRYCXMLySeGOFJDbfZLP2DrXAbDYDuixB2sNGaHSGgcMOj2zoWEU7Q6UZWVdq/ UeGiHjCiG6ei6B02PSpnUYVS7ZQCInWzDTEybTeLqNEieU/DCBSCy03Si+CEEydYUCkE4m MbQikk3K1Dp9kOn3dOhBMC3E1Kcdj1iD1I6K9VErD2IslRGW0C8zIoIYFyiqzg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1765294060; a=rsa-sha256; cv=none; b=F/qqgweQZ12fJh1Shz9oUG2InmgwMOIdrb03XvScv41BR9Gk8S25MI+2lsshrkblep+9OF zZe2CG1Pel0iQzzbuxFC0KkusKcQvnHIW9zp6V3doe3ZqC4r3Hsk3ctSHgUgmgP+mNZEn8 /P5Pfm2ei7153lDlEc+xKrbS98WPKO6laolUazVLHNxhP04y/UXyRtereS2nw7iAP/hTFP H/x4Ie9XPbEDlcg6Ju82UWZLFw8CXvpmSpamC328GNcfwYoS9RHq+5ZZiYYV1ZyyOWgIo2 VbNHpaTbJBSOI3aY4l7B5fP+8ER/jNflzilpQgBlqZmGS2ZywLp+C7/DhQYrxw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [10.20.214.191] (unknown [12.22.141.131]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: ashafer) by smtp.freebsd.org (Postfix) with ESMTPSA id 4dQjQh0DbfzQnX; Tue, 09 Dec 2025 15:27:39 +0000 (UTC) (envelope-from ashafer@FreeBSD.org) Message-ID: <629adec7-02e8-47d2-9ceb-65d0b11589b2@FreeBSD.org> Date: Tue, 9 Dec 2025 10:27:14 -0500 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: git: 5287dd47b5b6 - stable/14 - linuxkpi: add stub implementation of pm_vt_switch_(un)register To: Adrian Chadd Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-branches@freebsd.org References: <693750e9.387bb.3a5268c@gitrepo.freebsd.org> Content-Language: en-US From: Austin Shafer In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit In the default behavior I believe it does. The reason for it is that the VT switch path triggers the driver to save app contexts and video memory and the like, so historically (on Linux too) having the VT switch triggered that shared path to get things ready before doing the suspend. I don't think I've tested with turning that off, I'm not sure exactly why you'd want to. I haven't heard of that sysctl actually. Thanks, Austin On 12/8/25 5:58 PM, Adrian Chadd wrote: > .. does it? There's a sysctl to turn on vt switching on/off for > suspend/resume, no? > > > > -a > > On Mon, 8 Dec 2025 at 14:27, Austin Shafer wrote: >> >> The branch stable/14 has been updated by ashafer: >> >> URL: https://cgit.FreeBSD.org/src/commit/?id=5287dd47b5b643baba645cde51bf39f787c738d6 >> >> commit 5287dd47b5b643baba645cde51bf39f787c738d6 >> Author: Austin Shafer >> AuthorDate: 2025-10-28 17:03:18 +0000 >> Commit: Austin Shafer >> CommitDate: 2025-12-08 20:46:48 +0000 >> >> linuxkpi: add stub implementation of pm_vt_switch_(un)register >> >> This adds empty implementations of pm_vt_switch_(un)register which >> are used by nvidia-drm. We do not need to specify anything here as >> a VT switch always happens on suspend/resume. >> >> Sponsored by: NVIDIA >> Reviewed by: kbowling (mentor), emaste >> Differential Revision: https://reviews.freebsd.org/D53400 >> >> (cherry picked from commit 75aa13c64aba71f6f26d05e8fcf96e3862d44cde) >> --- >> sys/compat/linuxkpi/common/include/linux/pm.h | 14 ++++++++++++++ >> 1 file changed, 14 insertions(+) >> >> diff --git a/sys/compat/linuxkpi/common/include/linux/pm.h b/sys/compat/linuxkpi/common/include/linux/pm.h >> index c8d943027909..932697e0eda8 100644 >> --- a/sys/compat/linuxkpi/common/include/linux/pm.h >> +++ b/sys/compat/linuxkpi/common/include/linux/pm.h >> @@ -97,4 +97,18 @@ pm_wakeup_event(struct device *dev __unused, unsigned int x __unused) >> pr_debug("%s: TODO\n", __func__); >> } >> >> +/* >> + * We do not need to specify anything here as a VT switch always happens on >> + * suspend/resume. >> + */ >> +static inline void >> +pm_vt_switch_required(struct device *dev __unused, bool required __unused) >> +{ >> +} >> + >> +static inline void >> +pm_vt_switch_unregister(struct device *dev __unused) >> +{ >> +} >> + >> #endif /* _LINUXKPI_LINUX_PM_H */ >>