From patchwork Mon Oct 2 09:34:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Gaignard X-Patchwork-Id: 114572 Delivered-To: patch@linaro.org Received: by 10.140.22.163 with SMTP id 32csp474940qgn; Mon, 2 Oct 2017 02:35:33 -0700 (PDT) X-Received: by 10.101.92.6 with SMTP id u6mr12348381pgr.198.1506936932976; Mon, 02 Oct 2017 02:35:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1506936932; cv=none; d=google.com; s=arc-20160816; b=bprogHTxPO3+pjN70+afXnUdvZr0GGWZLdLF2fXeM2p3lT8JgSLAMIwP8H3WgdL8ar 9MB89gNwEFU1T3XPS7Z3JZ6KJqs71iux6HNQfeVsJgbE5BZenrjlyawYC59j34weilpr lMnWgp8hE+F9DlhqJtmlao1uffFBa3qA+j0ANk6vedp3JByyP6jpfkX+yeF1H+XZ1uzR wg80XCG3rDyZhQAMG1iGGj22JdxoR/W2cJCsCtYbmwftCm0sbaHImu9bB+L/8lNYv0rl bOf8sH1TwSjTGyVPL+T6K5O4YG3aX3TgOG2sMh1mffROMGtMqhJwZHa2nSqdW3pzQANX ZEhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=VcvizztyB3l0HfCGlPQ15vxBGD8cG1YHubi1VJZQLaM=; b=XmK/2bnB6QPy65Xz1hYHu7+4Nj2j2haexx8WFex8EH7UC50JP93rFJ0eb8UVCcdyYh 6tSGmbmQ32xvBeBQLhSv43QF6Sc48AreRDBiwoPGzMPUJaq3o2oDnXaJ3rmzWUk7p1RJ ddIhrwHo2M9y6RAT117/CPBwnkDPWFABqilUtLyFrbyYqdaUTid09qSm8YV3oVLkyn5+ fOtIrb4FaGcqPjbIdYxfkZO8iaEBfM3tG/1+hQiMbrrRJlNXJI5sfsughN4N2YFbpPmF A7mUjNo92SOAYbC5/SgOJ89k4bCzxbz+aWChZuscOqVWjCUCbr5f2O9D6GvjwuKQxnzC CJHg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eY8xymJE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m9si7963363plt.273.2017.10.02.02.35.32; Mon, 02 Oct 2017 02:35:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eY8xymJE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751420AbdJBJfb (ORCPT + 26 others); Mon, 2 Oct 2017 05:35:31 -0400 Received: from mail-wm0-f52.google.com ([74.125.82.52]:45397 "EHLO mail-wm0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751132AbdJBJf2 (ORCPT ); Mon, 2 Oct 2017 05:35:28 -0400 Received: by mail-wm0-f52.google.com with SMTP id q124so9358895wmb.0 for ; Mon, 02 Oct 2017 02:35:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=VcvizztyB3l0HfCGlPQ15vxBGD8cG1YHubi1VJZQLaM=; b=eY8xymJEWdikkBRk8aoyShopYi+UqSqQrHA8sHD2HyboXbEVwmHLtlPDKWnfL5nGQb ffQjmkDpsNe5qLYJ77VNyFnexQK/+1NhYD1W2y7LW1uSWBXvK/DA4oQlkIgg8PJmcy0P 1K7HKVrMQj09aV/KLeceMPsKx7kFfp2Q8Oa34= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=VcvizztyB3l0HfCGlPQ15vxBGD8cG1YHubi1VJZQLaM=; b=Y7VpvQW+77974mCqV8fXsJ2j2lSFrqVkrTowpPMykvpCYSChL3epvvJjGQ/iGzDl02 eL0+h7asOHOBUKB3j4Z1DhjO6g6XMw9Qsq6/gF53unX48+15hxKl5koaCPneHaovi0dw BYes8GRCRAl97PRtqgkJujl+MFp+lQypJSI16OZsj6ZDm3jThjrNkN3jXnVbpghIJRzG U2QECphltunZjwSPFXfgPXC9PXQguCcfcbqBxbWUFDzx8Faysx9s20kSJCv0LIN0grhN 5GzVShZdDjJvKzIohak1NPM4GURrlHSPPbLb5drXaHFXhpK7JOTmtmJpEOeop1e9aer1 vl6A== X-Gm-Message-State: AMCzsaUhpevVq/N8QFP2f5Suq8R4vwadhHhZ68OLddUVBeT0isNSs20W UlQJ6gYM7vW1MUFvzkhSYuP5KA== X-Google-Smtp-Source: AOwi7QBLyWgExh071CgB3rt1BHfwytSG233Wo/BYuCFuQv+5/u4EniJRfmBQdpv8EhRyGIR3U7Pq0g== X-Received: by 10.28.35.9 with SMTP id j9mr1891645wmj.109.1506936927753; Mon, 02 Oct 2017 02:35:27 -0700 (PDT) Received: from lmecxl0911.lme.st.com ([80.215.199.139]) by smtp.gmail.com with ESMTPSA id l4sm6516856wrb.74.2017.10.02.02.35.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 02 Oct 2017 02:35:27 -0700 (PDT) From: Benjamin Gaignard To: architt@codeaurora.org, a.hajda@samsung.com, Laurent.pinchart@ideasonboard.com, airlied@linux.ie, daniel.vetter@intel.com, jani.nikula@linux.intel.com, seanpaul@chromium.org, yannick.fertre@st.com, philippe.cornu@st.com Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Benjamin Gaignard Subject: [PATCH v2 5/5] drm/bridge/synopsys: dsi :remove is_panel_bridge Date: Mon, 2 Oct 2017 11:34:48 +0200 Message-Id: <1506936888-23844-6-git-send-email-benjamin.gaignard@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1506936888-23844-3-git-send-email-benjamin.gaignard@linaro.org> References: <1506936888-23844-3-git-send-email-benjamin.gaignard@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When using drm_of_panel_bridge_remove() we can simplify the code and remove is_panel_bridge from dw_mipi_dsi structure. Signed-off-by: Benjamin Gaignard Reviewed-by: Philippe Cornu Tested-by: Philippe Cornu --- drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) -- 2.7.4 diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c index f4f633a..d9cca4f 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c @@ -221,7 +221,6 @@ struct dw_mipi_dsi { struct drm_bridge bridge; struct mipi_dsi_host dsi_host; struct drm_bridge *panel_bridge; - bool is_panel_bridge; struct device *dev; void __iomem *base; @@ -297,7 +296,6 @@ static int dw_mipi_dsi_host_attach(struct mipi_dsi_host *host, bridge = drm_panel_bridge_add(panel, DRM_MODE_CONNECTOR_DSI); if (IS_ERR(bridge)) return PTR_ERR(bridge); - dsi->is_panel_bridge = true; } dsi->panel_bridge = bridge; @@ -312,8 +310,7 @@ static int dw_mipi_dsi_host_detach(struct mipi_dsi_host *host, { struct dw_mipi_dsi *dsi = host_to_dsi(host); - if (dsi->is_panel_bridge) - drm_panel_bridge_remove(dsi->panel_bridge); + drm_of_panel_bridge_remove(host->dev->of_node, 1, 0); drm_bridge_remove(&dsi->bridge);