Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp1686087rdb; Thu, 7 Dec 2023 06:19:40 -0800 (PST) X-Google-Smtp-Source: AGHT+IGS+1u5s8nP0TcQYZmBp8wvSanz6fV981VyxsNRTWKJcRbN8NCjAQtBN3FlQQv96zT6HPy9 X-Received: by 2002:a17:903:1d0:b0:1d0:d312:bc52 with SMTP id e16-20020a17090301d000b001d0d312bc52mr2454786plh.45.1701958779883; Thu, 07 Dec 2023 06:19:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701958779; cv=none; d=google.com; s=arc-20160816; b=wVBu23qLX0ZzeUcX1LAtOGqwqsDyjhCbQdqfPL9CcFQuevio3D0guyznIGJn0yCWZD SfpbEQnEGlRo+E5Y9nJwESrP08Z+3J/USbO0V7u+gTH4A00A741urGypeib5YceJtk0d c17+gswfinEZuqr3y+2KtM/qLDouK8hwSaCfdtWve4IdHcpiBMJgTt/Kox0JabGzaf2d aWje91SruSSPkKLgiHQafwzYc768GHO/ruAO8RQxkpXo9SAP3krqwp5dUhdWl4VKkoP2 mEv1fEloNifQ5/DfUCK010F4k6DR4RYt2k8ZBJaK136YCRwyUFNCuQzzl4vqGtTeiEfV AEdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=9yGi3UQjgH7vKIKdKQCwE11iHS9JPf1l9kS7cSUyqbg=; fh=yrurfj0wqsNBtuv2/DS7hXM5gjUdNl0RGba7zZuGnHQ=; b=tXAnYOFEAW7N86GPmH6+GeXOmDtwOVWksdS7LXrlILC1z6JT8tiIpVGVwEDq7jAA+E XYBwC60p3xJ2OfS930szbLqkJBoHhcqVgOGfH/+nvWX6CHVNKFQ/9GdyxlIBXm5B9mMW t2FNFzgHjeTsPwoHaqjwDoc0kLUSEMYEKnrnc3rd8gowDdCzDb5Cqps95AKVKT/MsM+C LY9kUCVuFYONB0pPior6IT1+BdZQTHyiUSfNynm6/FqnuptJPQ14/9ckJKJIwjFHxrdu agseAZi1x/2v8zhviv1KR1Et2Hnp9EusLGCyyCOQepy+oQG5RoJfJ0eysgGsc+9S7rvl U8Xg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=kxLmN75T; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id z11-20020a170903018b00b001cff3536eb6si1206012plg.463.2023.12.07.06.19.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 06:19:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=kxLmN75T; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 9BD01804194E; Thu, 7 Dec 2023 06:19:33 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1443318AbjLGOTB (ORCPT + 99 others); Thu, 7 Dec 2023 09:19:01 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48984 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1443293AbjLGOSW (ORCPT ); Thu, 7 Dec 2023 09:18:22 -0500 Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DC3721BFB for ; Thu, 7 Dec 2023 06:17:34 -0800 (PST) Received: by mail-ed1-x534.google.com with SMTP id 4fb4d7f45d1cf-54cb4fa667bso1322509a12.3 for ; Thu, 07 Dec 2023 06:17:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1701958649; x=1702563449; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=9yGi3UQjgH7vKIKdKQCwE11iHS9JPf1l9kS7cSUyqbg=; b=kxLmN75TgX5uFIBJuDTFH1+xNWuzgedppS0kPCGWDoBGRDA7SJpPXO3kMHuPtS+3jS 8/34YgTmoAYy/FBfScUVsXXnid5r/hCPz0oJeFAETn6vrcCyoAV6FH/vSgLiqkBT9YTz +vRjo8hDwR1xJ5c7Oi8himUlFU6vBYp0xsuY0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701958649; x=1702563449; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=9yGi3UQjgH7vKIKdKQCwE11iHS9JPf1l9kS7cSUyqbg=; b=ptHO4dq35Q4f1QrpfS8n9u6CHLM7AS5p/H/Dxkf2mbl707k7IE5LYB8LwtJCIyIISA VSHUsQYlv103Oue23u1DWjES3q15FmKhUlaGRcv8iAbUx1qS2vFn8KXtpuVnMBkMuDuk G1oQ4tjH2xQ2RxDr0Hx/nUkWsS1ePCBWbtm30CLrb0OczdegeWziWZupjf5Gs8qX8vH1 Lt4oSSqVssuu0L8ss2lHz6yYRoxBSL7tUEoxBvPacwnm8wLFQBlrowPzjnq5CwPfL45n M3gWz0hrzuw5cUtFUsIIt5rvH3OeaAM+WPs9pdiMjWV+kPWRB3Lo8rgq/XJEcKFHtQlF 3pbA== X-Gm-Message-State: AOJu0Yz3jhx9b84F10N9ehEQ0df6Vmt1TV9l5zAVGc9dgTLxTXnKdgU2 3oKRXE4pZ++rUZ2xhJ8xsh7f6Mb8ftSFG/lRW0SfKg== X-Received: by 2002:a17:907:b88:b0:a1c:eea8:e34b with SMTP id ey8-20020a1709070b8800b00a1ceea8e34bmr1371325ejc.100.1701958649228; Thu, 07 Dec 2023 06:17:29 -0800 (PST) Received: from localhost.localdomain ([2001:b07:6474:ebbf:9bf:959c:3c66:46c2]) by smtp.gmail.com with ESMTPSA id f24-20020a170906c09800b00a1e814b7155sm885421ejz.62.2023.12.07.06.17.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 06:17:28 -0800 (PST) From: Dario Binacchi To: linux-kernel@vger.kernel.org Cc: Amarula patchwork , michael@amarulasolutions.com, Dario Binacchi , Andrzej Hajda , Daniel Vetter , Dave Stevenson , David Airlie , Frieder Schrempf , Jernej Skrabec , Jonas Karlman , Laurent Pinchart , Maarten Lankhorst , Maxime Ripard , Neil Armstrong , Robert Foss , Thomas Zimmermann , dri-devel@lists.freedesktop.org Subject: [PATCH v5 01/10] drm/bridge: Fix bridge disable logic Date: Thu, 7 Dec 2023 15:16:30 +0100 Message-ID: <20231207141723.108004-2-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231207141723.108004-1-dario.binacchi@amarulasolutions.com> References: <20231207141723.108004-1-dario.binacchi@amarulasolutions.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 07 Dec 2023 06:19:33 -0800 (PST) As explained by the comment of the fixed code, we need to find the next bridge that hasn't set the "pre_enable_prev_first" flag to true. The code, on the contrary, was doing the opposite. So, the order of disabling the bridges couldn't be altered as required by setting the "pre_enable_prev_first" flag to true. Fixes: 4fb912e5e190 ("drm/bridge: Introduce pre_enable_prev_first to alter bridge init order") Signed-off-by: Dario Binacchi --- (no changes since v1) drivers/gpu/drm/drm_bridge.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/gpu/drm/drm_bridge.c index 30d66bee0ec6..f66bf4925dd8 100644 --- a/drivers/gpu/drm/drm_bridge.c +++ b/drivers/gpu/drm/drm_bridge.c @@ -686,7 +686,7 @@ void drm_atomic_bridge_chain_post_disable(struct drm_bridge *bridge, */ list_for_each_entry_from(next, &encoder->bridge_chain, chain_node) { - if (next->pre_enable_prev_first) { + if (!next->pre_enable_prev_first) { next = list_prev_entry(next, chain_node); limit = next; break; -- 2.43.0