Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp2410797ybt; Tue, 16 Jun 2020 05:33:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz1xbDDJggtbzFoPUeZYaIlZ+slguwX3UBqJp8Jm+CTX556ZMlPYXn7R0D+0HZBbGZtpcIE X-Received: by 2002:a17:906:3158:: with SMTP id e24mr2456316eje.543.1592310818156; Tue, 16 Jun 2020 05:33:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592310818; cv=none; d=google.com; s=arc-20160816; b=ztAWa18wIovAO9iwbQlvhzHMwjxekmb3Gcu9xFWGhgDkeGU98BP6dvedkYw5UTfXUg TZ1RAhKREP288dAMk6FLSGE/RRAit5uuJV0XrPL36u97FS1dlSL6VN4D53UqZwXEoHgQ gcji93cKCuE9fPKJ7gRXCtHVYAONYgV5rKBMnskGk7ualyNPjZQTJJmorf/Ep1+3QGjg ksV3iCsCnQzO9fFnT2dHS8BD+SOeEyuDuI6UGy3yse6HBxKF0bZoQX4SHCVzCGRQ98aE L8wSNuAXQwijrrDruBw62+fhmFNNMkiraTovtR+ZtZe7Hp6eLjdenTYA/mDfysRqBpR9 /RZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature:dkim-signature; bh=Czu8B8/QH/WNCgJQNgYJNhpSKuet+bFlALwMiXQlt7Q=; b=rMti5N/ZJS0ncLWgZLS3Ec/xp6fWkG31IMFQjvTnINVU83FpAXCqZIzy7goqlfAJbL ETx6//KIsr4eOVjf2qIYvZGXHSco4k3KMg0/45AyK7yzDfCABRyKqKulTRFriKbH19Df IdcGB0J+LN5GYEuCxvkuwbGZQsZ2DPl5apiHCo/cyCPJfHv3WZ+W5Dz41hsUjr6AaHSL Pb68w93KOqBv2O6vCAcCmlhTBZ+Tdv5VcxC5H8WPEJjRbkhABT5RRIrQojQt5qSwfzTU IZG8xpSittUb8TsyyEM2HTPknXS2a7arqAZZ6AQdbCyWb7queehl3tr3VtEA54Uejtum vlHw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=M7dBEPbe; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=RkDOGdQS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=cerno.tech Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id yd12si10796345ejb.237.2020.06.16.05.33.15; Tue, 16 Jun 2020 05:33:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=M7dBEPbe; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=RkDOGdQS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=cerno.tech Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728634AbgFPMbG (ORCPT + 99 others); Tue, 16 Jun 2020 08:31:06 -0400 Received: from new4-smtp.messagingengine.com ([66.111.4.230]:42831 "EHLO new4-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725901AbgFPMbD (ORCPT ); Tue, 16 Jun 2020 08:31:03 -0400 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.nyi.internal (Postfix) with ESMTP id D5DD9580230; Tue, 16 Jun 2020 08:31:01 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Tue, 16 Jun 2020 08:31:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm3; bh=Czu8B8/QH/WNCgJQNgYJNhpSKue t+bFlALwMiXQlt7Q=; b=M7dBEPbeWLwwTqlbLUs3KVxosMxMWtxu157ekKSzfRe IRe2Cwba8ac60C0H4drOIvkhepU3/jYX5wACKHQ6Pzhr2Fp5PY1t3lN288pUc2Jn oE3m4e+kDBi+IdxV/jPLgZoT5lPxZC98W/R4VR2cTE+sDwMgd4pBrDinWuaAs9yo 9kX6uSS7/9VE3DvuQ+Cir2m5AfIE9+RxBkRC0ZSR9oOvFsisdXVHeFzuPGXLBk8d rw4uH6wyKm6Sv+Km/7lPWM5uJhXe0bdepy4avpEpriiTaZ/mBkM7PEN1bxRtOZx1 DiKqwSITgkDlpnI1a608T7j4pX2Rz9dh4PBvwzM+Dsg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=Czu8B8 /QH/WNCgJQNgYJNhpSKuet+bFlALwMiXQlt7Q=; b=RkDOGdQSXIbFE7mVnntUg6 gtzvEYQ929qV8uboYKIDxIxIrh7fs1z3L1xm/2zOJuUD6e0PcuF+wc1IcdlypP77 ICwnJdA2vYjAQoJoCoI0bUoC6LkYDEgcnOLbhGZS3Q3D9dH0202C7JvHttRBPRWS BKkADc3N9SS4nqjZPUQF9mZPr9/6aRlK0wTtIkatYBijvrFOMvYHCnlHb/6Sd6EN QTfVP68NhEnKUVCYpNRZBrECP5nGSD98qpzdF+RdSYuxa8jHsyHAXwkPYOfSMGUQ EanP8l0pKGV4V1a/RPuw4UGQfY3h7uiOypO0V56lmn0K9J7I7atsa3q5bsawJocA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudejtddgheeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtuggjsehgtderredttddunecuhfhrohhmpeforgigihhm vgcutfhiphgrrhguuceomhgrgihimhgvsegtvghrnhhordhtvggthheqnecuggftrfgrth htvghrnhepjeekkefftdffhffhvedvudetgfdtleejveffvedvvdetgeeltdfggefhhedv ieffnecuffhomhgrihhnpehkvghrnhgvlhdrohhrghenucfkphepledtrdekledrieekrd ejieenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehm rgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Received: from localhost (lfbn-tou-1-1502-76.w90-89.abo.wanadoo.fr [90.89.68.76]) by mail.messagingengine.com (Postfix) with ESMTPA id 200833280064; Tue, 16 Jun 2020 08:31:00 -0400 (EDT) Date: Tue, 16 Jun 2020 14:30:58 +0200 From: Maxime Ripard To: Stefan Wahren Cc: Eric Anholt , Tim Gover , Dave Stevenson , linux-kernel@vger.kernel.org, DRI Development , bcm-kernel-feedback-list@broadcom.com, Nicolas Saenz Julienne , Phil Elwell , linux-arm-kernel@lists.infradead.org, linux-rpi-kernel@lists.infradead.org Subject: Re: [PATCH v3 070/105] drm/vc4: hdmi: rework connectors and encoders Message-ID: <20200616123058.skjudypbsefiom5c@gilmour.lan> References: <020de18840a1075b2671736c6cc2e451030fad74.1590594512.git-series.maxime@cerno.tech> <20200602155421.niyvpwqc42xh5c7v@gilmour> <6cd190e0-c81c-8e47-3ca8-22360de9b46d@i2se.com> <20200605143536.i6cc2v57eupmlvtn@gilmour.lan> <197a3164-828b-510e-47a7-f18ce1300d9d@i2se.com> <20200611133444.narsdlxmko2wgyj7@gilmour.lan> <8ad354c1-203c-e4bc-ef24-36a2a7b4a9b5@i2se.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="mnj3pykzsuovov52" Content-Disposition: inline In-Reply-To: <8ad354c1-203c-e4bc-ef24-36a2a7b4a9b5@i2se.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --mnj3pykzsuovov52 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Jun 14, 2020 at 06:16:56PM +0200, Stefan Wahren wrote: > Am 11.06.20 um 15:34 schrieb Maxime Ripard: > > Hi Stefan, > > > > On Sat, Jun 06, 2020 at 10:06:12AM +0200, Stefan Wahren wrote: > >> Hi Maxime, > >> > >> Am 05.06.20 um 16:35 schrieb Maxime Ripard: > >>> Hi Stefan, > >>> > >>> On Wed, Jun 03, 2020 at 07:32:30PM +0200, Stefan Wahren wrote: > >>>> Am 02.06.20 um 17:54 schrieb Maxime Ripard: > >>>> FWIW this is the first patch which breaks X on my Raspberry Pi 3 B. > >>>> > >>>> Here are the bisect results: > >>>> > >>>> 587d6e4a529a8d807a5c0bae583dd432d77064d6 bad (black screen, no heart= beat) > >>>> > >>>> b0523c7b1c9d0edcd6c0fe6d2cb558a9ad5c60a8 good > >>>> > >>>> 2c6a651cac6359cb0244a40d3b7a14e72918f169 good > >>>> > >>>> 1705c3cb40906863ec0d24ee5ea5092f5ee2e994 bad (black screen, but hear= tbeat) > >>>> > >>>> 601527fea6bb226abd088a864e74b25368218e87 good > >>>> > >>>> 2165607ede34d229d0cbce916c70c7fb6c0337be good > >>>> > >>>> f094f388fc2df848227e2ae648df2c97872df42b good > >>>> > >>>> 020de18840a1075b2671736c6cc2e451030fad74 bad (black screen, but hear= tbeat) > >>>> > >>>> 4c4da3823e4d1a8189e96a59a79451fff372f70b good > >>>> > >>>> 020de18840a1075b2671736c6cc2e451030fad74 is the first bad commit > >>>> commit 020de18840a1075b2671736c6cc2e451030fad74 > >>>> Author: Maxime Ripard > >>>> Date:=A0=A0 Mon Jan 6 17:17:29 2020 +0100 > >>>> > >>>> =A0=A0=A0 drm/vc4: hdmi: rework connectors and encoders > >>>> =A0=A0=A0 > >>>> =A0=A0=A0 the vc4_hdmi driver has some custom structures to hold the= data it > >>>> needs to > >>>> =A0=A0=A0 associate with the drm_encoder and drm_connector structure= s. > >>>> =A0=A0=A0 > >>>> =A0=A0=A0 However, it allocates them separately from the vc4_hdmi st= ructure which > >>>> =A0=A0=A0 makes it more complicated than it needs to be. > >>>> =A0=A0=A0 > >>>> =A0=A0=A0 Move those structures to be contained by vc4_hdmi and upda= te the code > >>>> =A0=A0=A0 accordingly. > >>>> =A0=A0=A0 > >>>> =A0=A0=A0 Signed-off-by: Maxime Ripard > >>> So it looks like there was two issues on the Pi3. The first one was > >>> causing the timeouts (and therefore likely the black screen but > >>> heartbeat case you had) and I've fixed it. > >>> > >>> However, I can indeed reproduce the case with the black screen / no > >>> heartbeat you mentionned. My bisection however returns that it's the > >>> patch "drm/vc4: hdmi: Implement finer-grained hooks" that is at fault. > >>> I've pushed my updated branch, if you have some spare time, it would = be > >>> great if you could confirm it on your Pi. > >> yesterday i checked out your latest rpi4-kms branch, but i was still > >> facing similiar issues with my Raspberry Pi 3 and multi_v7_defconfig > >> (heartbeat stops, splashscreen freeze, heartbeat is abnormal fast). So= i > >> tried to bisect but the offending commit didn't cause an issue the > >> second time. > >> > >> By accident i noticed that a simple reboot seems to hang for at least 8 > >> minutes (using b0523c7b1c9d0edcd the base of your branch). This usually > >> take a few seconds. So i consider this base on linux-next as too > >> unstable for reliable testing. > >> > >> Is it possible to rebase this on something more stable like linux-5.7 = or > >> at least drm-misc-next? This should avoid chasing unrelated issues. > > I've rebased it on 5.7 here: > > https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux.git/log/?= h=3Drpi4-kms-5.7 > > > > And it looks to be indeed an issue coming from next. That branch can > > start the desktop just fine on an RPi3 here. It would be great if you > > could confirm on your end. > > > > Thanks! > > Maxime >=20 > thank you very much. The good news are that the "black screen, but > heartbeat" issue and reboot hang are gone. Unfortunately the "no > heartbeat" issue is still there. >=20 > Here are more details about the issue. It doesn't occur everytime. I > would guess the probability is about 40 percent, which made bisecting > much harder. Are you sure about that 40% reliability? I found out that the culprit was that the commit we mentionned was actually running atomic_disable before our own custom callbacks, meaning that we would run the custom callbacks with the clocks and the power domain shut down, resulting in a stall. I was seeing it all the time when X was shutting down the display, but maybe you were changing the resolution between the framebuffer console or something, and since the power domain is shut down asynchronously, it wasn't running fast enough for the next enable to come up and re-enable it again? > It is reproducible on my 2 Raspberry Pi 3 B Rev 1.2. It is > also seems independent from the display because the problem occured on > my Computer display and my TV. But only on HDMI, right? I've pushed a new branch with that fix. Maxime --mnj3pykzsuovov52 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCXui7ggAKCRDj7w1vZxhR xTIYAP4gnQF4W2S9Kk51AvcjH8hnbrHB6RyGKzF2l9eqWRerZgEA0wobgfw2R4Sr w16Vk3zTXggYQVJtfTF3hYpNXafEhQQ= =1RvC -----END PGP SIGNATURE----- --mnj3pykzsuovov52--