From patchwork Mon Aug 29 18:40:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 2319 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pg1-f200.google.com (mail-pg1-f200.google.com [209.85.215.200]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 1B2F640F47 for ; Mon, 29 Aug 2022 20:41:05 +0200 (CEST) Received: by mail-pg1-f200.google.com with SMTP id a12-20020a65604c000000b0042a8c1cc701sf4363278pgp.1 for ; Mon, 29 Aug 2022 11:41:05 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1661798464; cv=pass; d=google.com; s=arc-20160816; b=WlHSe7JINaului6kgcv/hB88Dua0YQQiFAr92FHiAgAljm1lGDrzxW7Uv4j8hZ7Y6Q vYYhKsB7cMWlhxv9TbJPb8aP8fEm3uyVbLhg+hHiYsZ55JmFpC8unJtznXvBEfsHijOE EpmLHs8c6zQXOriSG5m8LqXkTxCOIi/ICUzyUokX9pKNBCQOfM0BT5TGMooLw5izRX6+ B1yVVTbgWcAPr0Sgnapx9ij4V8BV9AShuh444DH6ppAViO8jAFzcmjEYGt57gHRY7Gkw ZJ+68IU6wlxwKziAFb91P0fAjsGsW5SrtaiV6Ngz8K7TSWFZeMA0qnKJ3B7Es69j5Adz m4cg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=Ah9BpxnzN+c7JKwem5diUC1AkB7Dpa+09CYzK24cgR0=; b=U6rVv5NeHrAv/mygSB9xnyBu75sKE5BKjlMvF36tKLm94F8eaZOluquuyL/GJ9IDFG xFGms5rJscSsVfBAnt0xH7G6eJCc25fzkIf1/RcZWd0CZDmsVnjrLso9QxUnrVMjgG7i 9jmZsV1Rky9tKae/OcCkUTF4HRJEAvDKVZegJ99YU5NeF7bhLWLkGHDYDb6HX71PV/2B /Vwx/tTRvkgfJnif0Jsf9IgRVtUBzKYiK7U+T5exlwJZefNTTQklbhXg1v+a6WBClYAI oOdiWsE08HpPQNXTc049+lwNwZ6FKvJ7XWhjcoKdGWkKUbd2I+J3AGd2ahiW3Lfs/hgs ZA1g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=EPSFr67+; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:from:to:cc; bh=Ah9BpxnzN+c7JKwem5diUC1AkB7Dpa+09CYzK24cgR0=; b=NuM9Tv3M5sBOSidc+qChnFxM4zYaIAnSzfbyBrv4HwR8m1NQlS0E8RjrZ0zMiAFMxt zNVMlpiRf5MJsMsqtLFNpawMu74Pw7QGCIFb+xXGE4UQANxBx7HesZie5XGFtee4cKgo c5SavnVek9GlHHpC3mYdHPfy/LCDPpBycm8dM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc; bh=Ah9BpxnzN+c7JKwem5diUC1AkB7Dpa+09CYzK24cgR0=; b=FZMD4qNMnpzvAgj1v1vScr6+moWncVheCntmakFagHhm1X9AhYkoYrIOolHfx70IPh O7z2oWT8rkO2Yj3poN3lE8h5zaDJEL4usB8xWtybdQv+CUIrQaH+90MSQLNtyHPj/XC4 cUBcJu1V/cwN/Fm9J72+cKwS0rUBVB683o8ua2EtGizp6qW6g3y07qXyEPB+HnC3uqQO WIMKfari84xVISYVyr4Mu8E1Q/fyxPyzMTtjUdd1vJNENYgXDvFJ+/rM9uT0R/NxM4r3 HiNnkGjdhX1Iy2hxwTFIM/jxMS3pcgl6e0yxi5O3nHuTq4nSw5n1gZ46rP8fRZHDLK2O izxA== X-Gm-Message-State: ACgBeo2vMZj8s+VyF+SvJM5xRW/FCCTSry1xEpv4oQHnLZ61V9bM8MU4 fh6iEvigSPF+x/YYmwvJrzk06WCi X-Google-Smtp-Source: AA6agR4dC0SADATEVIr9Vu9PKb/lkDJQ9uN2dP+GVCdIq6R9/xLBi0Um/havAisjxgmeLx/om9xtxA== X-Received: by 2002:a63:1726:0:b0:41d:b30:46d4 with SMTP id x38-20020a631726000000b0041d0b3046d4mr14923444pgl.27.1661798463711; Mon, 29 Aug 2022 11:41:03 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a17:90b:2351:b0:1fd:81ab:cf6b with SMTP id ms17-20020a17090b235100b001fd81abcf6bls4424592pjb.2.-pod-prod-gmail; Mon, 29 Aug 2022 11:41:03 -0700 (PDT) X-Received: by 2002:a17:90b:d81:b0:1fd:7fed:4a9c with SMTP id bg1-20020a17090b0d8100b001fd7fed4a9cmr14480049pjb.127.1661798462845; Mon, 29 Aug 2022 11:41:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661798462; cv=none; d=google.com; s=arc-20160816; b=peLl9A3qYkNzrWCU1iPC2INih5rBW+XYNkVrK3SYF28bkAkYYmRdb/3UI70YRmL3Qy vlRSz44/ZGwhj1FIl/UCpGeL5z25W6n10Ntt6bRvUynK8QC0GuTHQBvV5NnT4vlNdsV7 VmjI8QCp84zH9/yjmsEs+5wQoC9YOHEG+m1VvzoNNwuRXKpPNYAFH4ZljWfjvu1+Z70Y Wv/CyfbPrD5hgh9N0D0dp/t2kqfB8D5lFaVyuPj9wGqq4pfx3AvtfnrUCgsvf6N1n5Ay 6uAH96f2MQ/Egeato2ZqXEH2TUKtptyCc5xckOhQmrAbeepzHLlTy9hkzS7EZOCDk06/ gkYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=P8VFeEM/BFJI467dCNlhyUmXQlADynuLsgzoWk47wCg=; b=ll7QdJOuFGUw04TzkSmYZNOXpScmNYxQALAeeU7ovJWCjW1dWct1TlaTc4TrAJEiCa 1H9ebwgqsuKpgIXjRplmMZjbE5CF8JA6ehs/HVmBRjbD2YiUk9Rc52ygcz7UlsGaanEC Pr1TPDDncCPlmTjvZMOwNB13vxaAFVXUAwXYMPW6YV4NeFLrb3JUa3ck++AQV3visY26 YZLTRgVTAitanHYvCj3fZ6F5NdOcGZo2BKPIA8l58lazl/mSKnck0bWfUuuN2XBM8OG1 kxMLL4hWfPEd0tcfhjiuGHL208nd7mhGeUkJ0k+QNUhfhqEwqaGre4KDXbj2o9GcFJwH 3iMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=EPSFr67+; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id bi1-20020a056a02024100b0042b688ee460sor25893pgb.13.2022.08.29.11.41.02 for (Google Transport Security); Mon, 29 Aug 2022 11:41:02 -0700 (PDT) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:a63:1921:0:b0:42b:6eb3:bce5 with SMTP id z33-20020a631921000000b0042b6eb3bce5mr15304041pgl.231.1661798462536; Mon, 29 Aug 2022 11:41:02 -0700 (PDT) Received: from localhost.localdomain ([2405:201:c00a:a073:43f7:1644:6259:830d]) by smtp.gmail.com with ESMTPSA id k13-20020aa7998d000000b005385e2e86eesm1619042pfh.18.2022.08.29.11.40.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Aug 2022 11:41:02 -0700 (PDT) From: Jagan Teki To: Andrzej Hajda , Inki Dae , Marek Szyprowski , Joonyoung Shim , Seung-Woo Kim , Kyungmin Park , Frieder Schrempf , Fancy Fang , Tim Harvey , Michael Nazzareno Trimarchi , Adam Ford , Neil Armstrong , Robert Foss , Laurent Pinchart , Tommaso Merciai , Marek Vasut Cc: Matteo Lisi , dri-devel@lists.freedesktop.org, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, NXP Linux Team , linux-amarula , Jagan Teki Subject: [PATCH v4 01/12] drm: exynos: dsi: Restore proper bridge chain order Date: Tue, 30 Aug 2022 00:10:20 +0530 Message-Id: <20220829184031.1863663-2-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220829184031.1863663-1-jagan@amarulasolutions.com> References: <20220829184031.1863663-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=EPSFr67+; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Marek Szyprowski Restore the proper bridge chain by finding the previous bridge in the chain instead of passing NULL. This establishes a proper bridge chain while attaching downstream bridges. v4: * none v3: * new patch Signed-off-by: Marek Szyprowski Signed-off-by: Jagan Teki --- drivers/gpu/drm/exynos/exynos_drm_dsi.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_dsi.c b/drivers/gpu/drm/exynos/exynos_drm_dsi.c index ec673223d6b7..e5b1540c4ae4 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_dsi.c +++ b/drivers/gpu/drm/exynos/exynos_drm_dsi.c @@ -1428,7 +1428,8 @@ static int exynos_dsi_attach(struct drm_bridge *bridge, { struct exynos_dsi *dsi = bridge_to_dsi(bridge); - return drm_bridge_attach(bridge->encoder, dsi->out_bridge, NULL, flags); + return drm_bridge_attach(bridge->encoder, dsi->out_bridge, bridge, + flags); } static const struct drm_bridge_funcs exynos_dsi_bridge_funcs = { @@ -1474,7 +1475,10 @@ static int exynos_dsi_host_attach(struct mipi_dsi_host *host, drm_bridge_add(&dsi->bridge); - drm_bridge_attach(encoder, &dsi->bridge, NULL, 0); + drm_bridge_attach(encoder, &dsi->bridge, + list_first_entry_or_null(&encoder->bridge_chain, + struct drm_bridge, + chain_node), 0); /* * This is a temporary solution and should be made by more generic way.