Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp2478867rdh; Sun, 26 Nov 2023 07:47:18 -0800 (PST) X-Google-Smtp-Source: AGHT+IF/cuTd/ckyKi+YsxKcseGO4qqkoCFjKoKAce0py8CmhAMBNWDhtiYXtnBkfanM6vBYN63y X-Received: by 2002:a17:90b:33c2:b0:285:a0d1:60ff with SMTP id lk2-20020a17090b33c200b00285a0d160ffmr4575929pjb.38.1701013638111; Sun, 26 Nov 2023 07:47:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701013638; cv=none; d=google.com; s=arc-20160816; b=JlcVkxvhlVSEfDuDgUrTtw7Z08SMn83owADcT49tOAb26iHAJRV+dHYHBv/ez4l1gT TYFjsh1vGCyZ773jxmxBhD/HxFcLHBgwobtq7i3rZYjxwFuKfwTYx/aUmnW4vIzP1SDc 8CgmR0mQWeCFV+M6Evi+YMCJI6rTC4932OaI/SfhyjpEnVxHAeAzLrfAZm+6WWegk+P9 /XUkmOkHMBzrFasNlydXs1hV7GGRhYXkUiFe+gT4wVHgsUlf9lKmwz7A5LEB2nF6q4I5 agZB6XG00OY6PxZv+OSQhZHfdu849RWqCYZHVBfYSnvOpVr0T4C7Vln9OSqAbi+BA/2r aTOw== 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=ZPhojAvgi+YoDilK1ECw25JeY/ntj0LxcVc6MoPKWUg=; fh=yrurfj0wqsNBtuv2/DS7hXM5gjUdNl0RGba7zZuGnHQ=; b=b/XNxf2SIjSviKnxGTtJM5kLsNiOvfqxfc/gM0bTYX2Lwa0Lhqi1BV0tb7PB1ltQ4X CDFf0+u3pGSMjOvuERYeJiw6+nsh1aFVZGFvfDoqhz1TI/XsZ99j4K6Ul3sxWlfanGze OfWKpNBl8B8av9Osth/VmK6azXHob0NztCE2dXkTaMnDz4N0b8GgCIfKyb7Awt6NH8E2 oCx1L4KPvE6uBKxH4aNl2yxc80YEFEdbQj8jcGpUenLsdZYk/DQwJSzGb7jP+zWDF/qW zx2RXnomlnsLvvBEb+uhzOb+bV/FEHvQHSwPpN+skSxfP54+j4GUWjkJnmODKumPpXVG k7Qw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=GL9ss8D6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 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 morse.vger.email (morse.vger.email. [2620:137:e000::3:1]) by mx.google.com with ESMTPS id w32-20020a631620000000b005855f67e491si7937484pgl.696.2023.11.26.07.47.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Nov 2023 07:47:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) client-ip=2620:137:e000::3:1; Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=GL9ss8D6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 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 morse.vger.email (Postfix) with ESMTP id CEF358068E36; Sun, 26 Nov 2023 07:47:15 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230488AbjKZPql (ORCPT + 99 others); Sun, 26 Nov 2023 10:46:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44228 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230229AbjKZPqc (ORCPT ); Sun, 26 Nov 2023 10:46:32 -0500 Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E992010A for ; Sun, 26 Nov 2023 07:46:38 -0800 (PST) Received: by mail-ej1-x629.google.com with SMTP id a640c23a62f3a-a00a9c6f283so458823766b.0 for ; Sun, 26 Nov 2023 07:46:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1701013597; x=1701618397; 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=ZPhojAvgi+YoDilK1ECw25JeY/ntj0LxcVc6MoPKWUg=; b=GL9ss8D6v4qFRbk61VECZ4zLfvtoMVEqq2HUxlSxqnAJ5hWByl8N1rc8TmGgFwxXcT QoEnURT5m04l+nwl0NFFte5R93oCOYpd3G+nFwHOpsCNPCOHCwdoznRdy3b3xnl2ho9U tNX+taJEx6jSn13NSl+LjNTMg5q6XlaB4kzsU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701013597; x=1701618397; 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=ZPhojAvgi+YoDilK1ECw25JeY/ntj0LxcVc6MoPKWUg=; b=vb73W76jhSZa0m693LwAw/9kwxnIUladz7gvTnHCXO0o+Qkg5VLGTLwACsUzFjaoCh vvuV180Fu7fUmLBTp6EPSA1Mbvcv1ToTfHbxPreIjw6srG+WxOWIpUViTsPlBLMaeWyD P8Ey+llnyo/n02g+mb9cpdn3Y8tRpWvF39C0aYm1n3odMMQBAjVBtKPsHJWSlI3sk7/K d0kiOZ4vgrgtyi9eMde3BBVujh7MeK6JcCXLfvJJ8MFHo/GSDOLW7FPaNIBrPzFEhMcF NTHAPtDFRo/qOsHEvYtyPIg97pfLUAxmuIJlML12J6gKj/WBSg0dU2Zh9ZQuWhVyaE+q p6HQ== X-Gm-Message-State: AOJu0Yzs61EcdkChly2ho2jzevIck2ResCCXb0g5Kmo7FwTA8TGUTvzS peinM/oGNnzV+YodUdjdjcIVtZV35hfbuswAyExD4g== X-Received: by 2002:a17:906:2f14:b0:9fe:ab09:4d9 with SMTP id v20-20020a1709062f1400b009feab0904d9mr5649578eji.59.1701013596469; Sun, 26 Nov 2023 07:46:36 -0800 (PST) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-95-244-100-54.retail.telecomitalia.it. [95.244.100.54]) by smtp.gmail.com with ESMTPSA id h24-20020a170906591800b009fdc684a79esm4656158ejq.124.2023.11.26.07.46.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Nov 2023 07:46:34 -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 v2 01/11] drm/bridge: Fix bridge disable logic Date: Sun, 26 Nov 2023 16:44:53 +0100 Message-ID: <20231126154605.15767-2-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231126154605.15767-1-dario.binacchi@amarulasolutions.com> References: <20231126154605.15767-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 morse.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 (morse.vger.email [0.0.0.0]); Sun, 26 Nov 2023 07:47:15 -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.42.0