From patchwork Fri Jun 28 16:01:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrzej Pietrasiewicz X-Patchwork-Id: 11022901 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8661F112C for ; Fri, 28 Jun 2019 16:04:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 74936287F5 for ; Fri, 28 Jun 2019 16:04:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6631328714; Fri, 28 Jun 2019 16:04:42 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 098F12886A for ; Fri, 28 Jun 2019 16:04:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=mNqzES5Bya+6CYcFOC4kqmQnehBPcpqeINlOvvvUDpA=; b=UpEZRw8XClsa31zOV/e670maFf kqdrnNtkhdRUs1VQwdJ4FNqvt8WFDpsCxFExvd+2ncnodjOTcEsRMx3tUaQgjxnBQDS8k1XX+cR/F 8uOhsdcqZozcufusbu01u3uWXgp9KiaPfNCrY+f+6XCt5k/RjSWjIokvNjtDlNffJRkgvAFKVfH/U Qvwyr7oxitQIbrqswT0zWP+ItDElSm8GwtWL6brFIWYu7Edu6prkM36/izfHm0On1SgDDmZXh4o94 L+dXSsQc87RrBpIhq+yjZ1xeRnDUEY7W+aTbF0NwAOv5U02a7xSVsZZG5Mf7BcGGTiskrIPeN2Zwl 3TJJ+YOQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hgtMf-0007Rv-5i; Fri, 28 Jun 2019 16:04:41 +0000 Received: from bhuna.collabora.co.uk ([2a00:1098:0:82:1000:25:2eeb:e3e3]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hgtMb-0007N5-20; Fri, 28 Jun 2019 16:04:38 +0000 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: andrzej.p) with ESMTPSA id 9083C280AB5 From: Andrzej Pietrasiewicz To: dri-devel@lists.freedesktop.org Subject: [PATCH v3 02/22] drm/exynos: Provide ddc symlink in connector's sysfs Date: Fri, 28 Jun 2019 18:01:16 +0200 Message-Id: <3f7bbe3420bbd30a21c771b7c9c24d9a23c85000.1561735433.git.andrzej.p@collabora.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: References: <3fb19371-db7d-f9dc-31a7-1ccd126f6784@collabora.com> In-Reply-To: References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190628_090437_382896_E9AFD16F X-CRM114-Status: GOOD ( 13.41 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Y.C. Chen" , =?utf-8?q?Heiko_St=C3=BCbner?= , Sam Ravnborg , Neil Armstrong , Maxime Ripard , Douglas Anderson , Andrzej Hajda , Thierry Reding , Laurent Pinchart , Benjamin Gaignard , kernel@collabora.com, Fabio Estevam , =?utf-8?b?VmlsbGUgU3lyasOkbMOk?= , "David \(ChunMing\) Zhou" , linux-samsung-soc@vger.kernel.org, Joonyoung Shim , linux-rockchip@lists.infradead.org, Vincent Abriou , Rob Clark , Krzysztof Kozlowski , Jonathan Hunter , David Airlie , Chen-Yu Tsai , Kukjin Kim , NXP Linux Team , CK Hu , Dave Airlie , freedreno@lists.freedesktop.org, linux-tegra@vger.kernel.org, Pengutronix Kernel Team , Jonas Karlman , Jani Nikula , linux-arm-msm@vger.kernel.org, Sascha Hauer , Maarten Lankhorst , Jyri Sarha , Inki Dae , Mamta Shukla , linux-mediatek@lists.infradead.org, Matthias Brugger , Daniel Vetter , Thomas Gleixner , Sean Paul , linux-arm-kernel@lists.infradead.org, amd-gfx@lists.freedesktop.org, Tomi Valkeinen , Eric Anholt , Thomas Zimmermann , Seung-Woo Kim , Sandy Huang , linux-kernel@vger.kernel.org, Todor Tomov , Kyungmin Park , Huang Rui , Philipp Zabel , Alex Deucher , Shawn Guo , =?utf-8?q?Christian_K=C3=B6nig?= , Gerd Hoffmann MIME-Version: 1.0 Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Switch to using the ddc provided by the generic connector. Signed-off-by: Andrzej Pietrasiewicz --- drivers/gpu/drm/exynos/exynos_hdmi.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_hdmi.c b/drivers/gpu/drm/exynos/exynos_hdmi.c index 894a99793633..6816e37861b7 100644 --- a/drivers/gpu/drm/exynos/exynos_hdmi.c +++ b/drivers/gpu/drm/exynos/exynos_hdmi.c @@ -126,7 +126,6 @@ struct hdmi_context { void __iomem *regs; void __iomem *regs_hdmiphy; struct i2c_client *hdmiphy_port; - struct i2c_adapter *ddc_adpt; struct gpio_desc *hpd_gpio; int irq; struct regmap *pmureg; @@ -872,10 +871,10 @@ static int hdmi_get_modes(struct drm_connector *connector) struct edid *edid; int ret; - if (!hdata->ddc_adpt) + if (!connector->ddc) return -ENODEV; - edid = drm_get_edid(connector, hdata->ddc_adpt); + edid = drm_get_edid(connector, connector->ddc); if (!edid) return -ENODEV; @@ -1893,7 +1892,7 @@ static int hdmi_get_ddc_adapter(struct hdmi_context *hdata) return -EPROBE_DEFER; } - hdata->ddc_adpt = adpt; + hdata->connector.ddc = adpt; return 0; } @@ -2045,7 +2044,7 @@ static int hdmi_probe(struct platform_device *pdev) if (hdata->regs_hdmiphy) iounmap(hdata->regs_hdmiphy); err_ddc: - put_device(&hdata->ddc_adpt->dev); + put_device(&hdata->connector.ddc->dev); return ret; } @@ -2072,7 +2071,7 @@ static int hdmi_remove(struct platform_device *pdev) if (hdata->regs_hdmiphy) iounmap(hdata->regs_hdmiphy); - put_device(&hdata->ddc_adpt->dev); + put_device(&hdata->connector.ddc->dev); mutex_destroy(&hdata->mutex);