From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2FEC5C4332F for ; Thu, 2 Nov 2023 14:56:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233077AbjKBO4J (ORCPT ); Thu, 2 Nov 2023 10:56:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232966AbjKBO4F (ORCPT ); Thu, 2 Nov 2023 10:56:05 -0400 Received: from mail11.truemail.it (mail11.truemail.it [217.194.8.81]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 486FD187 for ; Thu, 2 Nov 2023 07:56:03 -0700 (PDT) Received: from francesco-nb.int.toradex.com (93-49-2-63.ip317.fastwebnet.it [93.49.2.63]) by mail11.truemail.it (Postfix) with ESMTPA id 53AC1207BF; Thu, 2 Nov 2023 15:56:01 +0100 (CET) Date: Thu, 2 Nov 2023 15:55:59 +0100 From: Francesco Dolcini To: Tomi Valkeinen Cc: Aradhya Bhatia , Devarsh Thakkar , Jyri Sarha , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Laurent Pinchart Subject: Re: [PATCH 10/10] drm/tidss: Fix atomic_flush check Message-ID: References: <20231101-tidss-probe-v1-0-45149e0f9415@ideasonboard.com> <20231101-tidss-probe-v1-10-45149e0f9415@ideasonboard.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231101-tidss-probe-v1-10-45149e0f9415@ideasonboard.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 01, 2023 at 11:17:47AM +0200, Tomi Valkeinen wrote: > tidss_crtc_atomic_flush() checks if the crtc is enabled, and if not, > returns immediately as there's no reason to do any register changes. > > However, the code checks for 'crtc->state->enable', which does not > reflect the actual HW state. We should instead look at the > 'crtc->state->active' flag. > > This causes the tidss_crtc_atomic_flush() to proceed with the flush even > if the active state is false, which then causes us to hit the > WARN_ON(!crtc->state->event) check. > > Fix this by checking the active flag, and while at it, fix the related > debug print which had "active" and "needs modeset" wrong way. Candidate for stable? Add a Fixes tag? Francesco