From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796155171; b=5VJ685M6v+lcP4TbKKdCbjsKWS549RHqO3zjRJC/xD3e0XWiUBcf3V0UZs8XPCHkhWTi MoTjXVhYUQlaCfV7LBkhCYx0a9zO5ZLvZ2H9XM5pKKN7neZHmBOuIXUF1n1IJtVuA/NDw vbrK4F2+gMiipWNJGXuxRnE5x9WWQIOO0E3Fxd2WLKTlmnrN+zNelnxJREnza+aaEC0G1 AdRIl1WLlsi9z103Wok9290h2n3qgsK+mALtaxgsuPXrpmnWCY4BHKjFHtC2IaZC+W3BV 5wKIccHlvhnZQQpFYO7DIzI7Iff1YqUqFYaeRCV01kzBQOEd46EmIusNieEIEP2o8pw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796155171; h=Received:DKIM-Signature:Message-ID:Date:MIME-Version:User-Agent: Subject:Content-Language:To:Cc:References:From:In-Reply-To: Content-Type:Content-Transfer-Encoding; bh=8Sc9c+SsxclPUyIEdtVZUz4lr3y2QZmra7tNExOXPpg=; b=C08MNdOQkFysF/lAkpdL3nPyPsgC1ASemI920r4cM2RQNFLqzgI+Giff1SK+4tUT9HOF pz98jOWJ+epth2AK1quCrLG68XD89uWaNhWo/ggUKDKIp8gAdwip1OwHvaf9aRBXrf9aQ 8OIFaz5EnrK/h7fDiVsTl1Iha7ZeLq0CzamASLcgMJFubjla/wCfUrormz8/v1tIsmqeo v2pDBY0iia9jAZFm0suQ9zCbwU5borEBLBalj1Xq6Lhz+IVXtzSpJvO5PfNpjcIMgfhZg 3Rcb3pCpYtqMcvW4FQ7zP24kTAz0twiVz6wjOQPnlICGR+gWmj1hQs21VMqg4k8fNdQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=BjW9WYjO; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 56375606A31A for ; Tue, 1 Dec 2026 19:59:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=BjW9WYjO Received: by smtp.kernel.org (Postfix) with ESMTPSA id ED56B1F000C1; Tue, 1 Dec 2026 19:59:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796155171; bh=8Sc9c+SsxclPUyIEdtVZUz4lr3y2QZmra7tNExOXPpg=; h=Date:Subject:To:Cc:References:From:In-Reply-To; b=BjW9WYjOu8wqtemjdPLCnyQTRs/cBmPfvCq2v7yWEDWqsGcnvPq/6ZV9EEo8Pswn4 Mvbc3iuzK0MJObGfG2bz10c76rjH0b1/qeLMkzVRQcbkYhfx51juZP8ct39teeS3dn HVwbFNa23754zFas8o5bChZAZerMYkXcEcN1/L7xBN/f6Ut+S9XaCus493ZyCqvNay ByGQgzjh41mYbzwvpX98/FaqXqjyDz3zPdP4bVb/CcMUYhDFx+K9n4UoLNCpkDmwsd NLyCStIwknqV6ZNjwsblFm4IYPJq+jsYfz7RDYMa8OfZbqyr04BtblRnk2e096bS/N wZdbd+muyaUFw== Message-ID: <4e9adf36-e10a-44d2-8dc4-562120784824@kernel.org> Date: Tue, 1 Dec 2026 13:59:30 -0600 X-Mailing-List: linux-usb@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [REGRESSION/BUG] thunderbolt: ASM4242 fails to restore DP tunnel after resume on Ryzen 8700G (7.4-rc4) Content-Language: en-US To: =?UTF-8?Q?Achim_L=C3=B6bbert?= , Mika Westerberg Cc: linux-usb@vger.kernel.org References: <286e5547-70f8-4275-9777-1a723dbcb388@kernel.org> From: Mario Limonciello In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 12/1/26 13:17, Achim Löbbert wrote: > On Tuesday, 1. Dezember 2026 18:36:24 CET Mario Limonciello wrote: >> On 12/1/26 11:24, Achim Löbbert wrote: >>> On Tuesday, 1. December 2026 15:53:25 CET Mario Limonciello wrote: >>>> On 12/1/26 08:45, Achim Löbbert wrote: >>>>> Hi Mario, >>>>> >>>>> On Tuesday, 1. December 2026 05:29:52 CET Mario Limonciello wrote: >>>>> [...] >>>>> >>>>>> Can you have a try with this patch to force replug events? I think it >>>>>> should help on top of Mika's other inline patch. Whether it should be >>>>>> a >>>>>> quirk or some other form can be up for discussion. Let's see if the >>>>>> concept works. >>>>> >>>>> Thanks for the patch and the bug description, which summarizes it very >>>>> well. I applied the patch together with Mika's patch against 7.4-rc5 and >>>>> rebuilt. I also deactivated my hook script using >>>>> >>>>> sudo chmod -x /etc/elogind/system-sleep/99-bolt-wake.sh >>>>> >>>>> and added 'log_buf_len=1M' on kernel command line to log more sleep >>>>> cycles. >>>>> >>>>> Attached dmesg log now shows two suspend/resume cycles with following >>>>> results: >>>>> >>>>> #1: PC resumes after 1st keypress and remote ssh to it works. U3225QE >>>>> wakes up from powersaving, but a screen image is shown only after >>>>> another >>>>> 2nd keypress. Seen this before with my hook script, and that's what the >>>>> for loop is for: to prevent to return to elogind too early before DP-2 >>>>> is >>>>> actually connected. >>>>> >>>>> #2: PC resumes, ssh works again, screen comes up from power saving, but >>>>> stays black again, unfortunately. But after waiting several (>10) >>>>> minutes, another keypress might still turn it on and unlock screen is >>>>> displayed. >>>>> >>>>> Another observation: with the latest patches, DP-2 status now always >>>>> shows >>>>> connected, even in case of black screen, for which it showed >>>>> disconnected >>>>> before the patch. >>>>> $ for i in /sys/class/drm/card0-DP-*/status; do echo "$i: $(cat $i)"; >>>>> done >>>>> /sys/class/drm/card0-DP-1/status: disconnected >>>>> /sys/class/drm/card0-DP-2/status: connected >>>>> /sys/class/drm/card0-DP-3/status: disconnected >>>>> /sys/class/drm/card0-DP-4/status: disconnected >>>>> /sys/class/drm/card0-DP-5/status: disconnected >>>>> /sys/class/drm/card0-DP-6/status: disconnected >>>>> >>>>> Confusing results. Certainly some race condition is involved. >>>>> Would be happy to assist with further testing. >>>>> >>>>> BR, Achim >>>> >>>> Confusing results indeed. But I think this is at least the right >>>> direction. >>>> >>>> To rule out a race with a compositor; can you stop all userspace that >>>> holds DRM master and work from a VT while testing? >>>> >>>> Then the kernel should be lighting up all the displays and we shouldn't >>>> have to worry about anything induced by races. >>> >>> Good idea: service display-manager (sddm/wayland) deleted from run-level >>> default, reboot, with everything else unchanged. Text mode VTs only, no >>> GUI. >>> >>> To enter sleep, on the console this was executed 5 times: >>> $ echo mem | sudo tee /sys/power/state >>> wait until U3225QE enters power saving state, then press a key to wake up: >>> >>> Text mode console screen comes up immediately, turns black exactly once >>> for 2 seconds each time, then comes up solid without any further issues. >>> >>> 2 more times 'sudo tee /sys/power/state' printed "device or resource busy" >>> and sleep mode S3 was not entered, no clue why. But wanted to mention in >>> case there is something peculiar in the log. >>> >>> Log attached with 5 suspend/resume cycles >> >> OK so now with compositor out of the picture it sounds like what I would >> expect happens. Basically it forces the plug event after resume and >> everything works fine. I don't think the patch as I shared it is what >> we should be putting in. > > Agreed, because of see below. > >> The surprising part to me is that it was visible before the the black >> screen. Is this consistent every single time? Or just some cycles it >> happens? > > In case you referred to this (just to avoid misunderstandings): >>> Text mode console screen comes up immediately, turns black exactly once >>> for 2 seconds each time, then comes up solid without any further issues. > Consistent: 2 second black console screen happened every of the 5 times with > Mika's and your patch applied (Log tb-resume-bug-dmesg.8.txt sent earlier). > >> With just Mika's inline patch and no compositor/userspace running is it >> a failure rate when there is a black screen vs not? > The 2 second black console screen did not occur at all while trying 10 times > with Mika's patch only. Log tb-resume-bug-dmesg.9.txt attached, with ~3 > cycles, but I tested more than 10 cycles without 2s black screen showing up. If it's working 100% of the time with just Mika's patch that sounds like the preferred approach to me. Any remaining black screen issues sound like they would be caused by userland then, no?