Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1089836pxa; Sat, 1 Aug 2020 17:11:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwyPp2+3gaFeYu92GvTE+IxYQveb2fWRuJVM/bgszLZSoelkNFNnEJaCQ7LzCrZs18YEPbv X-Received: by 2002:a50:fc02:: with SMTP id i2mr10123562edr.121.1596327088308; Sat, 01 Aug 2020 17:11:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596327088; cv=none; d=google.com; s=arc-20160816; b=hAWTTS1mlWxR60esnf+d5qyU8BhvWlAqULfoZxsONpHgIu7ZYPUNy6ui5dRF+W87QX xCzTdZmdE1fRCi+EmR+/qVjZpAUVLdU6E43ES1w2vhFnvomK1x7+S0OvEbd4hDt6Ucr2 TJcBgnJMN/Pe6wmiWRWRpnQsPnBLjWMJCbKSjFkGQqOaNW9kkbXTfG/Pei3B3pMxWuYN qWtKrbZ5+Oc+inx9eJrS5SrOpui0VzFPs32nA0ZnDy7St1wWTq+yN8BfJQRuoMf+Gy2D ya6kjLje0CGeWvetlHvOkzUQ9dLHdPt6vl3NWyWJOEicGteKQOcusGdR6a+ou2QKrvQ9 hsaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=Ulu+SdmN2n0W12W/iK4+qWnk0eFqfzFb9kd4yLRkIWY=; b=BE3Gr1+o+PPMzE3MbpjA7mjdx8/30nVv5HAkEyciLtlN7zlc4mcl2+GaRtVS8/PBZ/ Qb0dzfpAzfYl5Rv+sr+PQZs/4/kJFcCr6grIG1CuNRjFd1zcOM+Pj2R3p1Dm3zPXFCcX ZEFD8nKBlFKCfv0piUvLuBaPCwiRxSdeN7gzMwipOefS5HHJGcGAt5uaVRoraiMIMbcU eeeQJbjCAZc/9IFeyn8ifPNYCnkb3E/YQrLB+Fft6vS+Zw3Blb1UPH+9NmggyVfSaJ/d Ts7ya4wox7XbD35tDi0tY6teSv6cI131xAvQLJXjigLZ/1J/wZzN27q1FU8/h7xKVzEt e42Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=auSXa5Kl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a14si2303849edb.100.2020.08.01.17.11.04; Sat, 01 Aug 2020 17:11:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=auSXa5Kl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726999AbgHBAI7 (ORCPT + 99 others); Sat, 1 Aug 2020 20:08:59 -0400 Received: from mail.kernel.org ([198.145.29.99]:33498 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725883AbgHBAI7 (ORCPT ); Sat, 1 Aug 2020 20:08:59 -0400 Received: from mail-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 218E420888 for ; Sun, 2 Aug 2020 00:08:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1596326938; bh=oCx/GR0RX1huNTjbv/4QOj0BuphlW+WSIv710+yID1o=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=auSXa5Kl4kZmf41UMcsHVRiDTL85kbbPlpxVkVFQ7kWooytCoMrwGXLSHsoRDdwJv xF/3YFiTpEPCuGF/rFnjd68Phkka9RwUgLkY0C5OL8mSPZFJdulDE16Q4HL+mBKiQZ 2aWsNLP3xq0tkonqfRAa1bYYq38KoR6z2FFtMzIc= Received: by mail-ed1-f49.google.com with SMTP id c2so18958718edx.8 for ; Sat, 01 Aug 2020 17:08:58 -0700 (PDT) X-Gm-Message-State: AOAM532JrvuJV7om7aXXR0BUHK4wyON+jNJ5NKPlPESu8CLUdVu84u9V uAZ/eFBriq6ay2Ssj43JZ4Jr6tBVXmfdKgLbrA== X-Received: by 2002:a05:6402:2037:: with SMTP id ay23mr9749512edb.48.1596326936640; Sat, 01 Aug 2020 17:08:56 -0700 (PDT) MIME-Version: 1.0 References: <20200728111800.77641-1-frank-w@public-files.de> <20200728111800.77641-3-frank-w@public-files.de> In-Reply-To: <20200728111800.77641-3-frank-w@public-files.de> From: Chun-Kuang Hu Date: Sun, 2 Aug 2020 08:08:44 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 2/5] drm/mediatek: fix boot up for 720 and 480 but 1080 To: Frank Wunderlich Cc: "moderated list:ARM/Mediatek SoC support" , Chun-Kuang Hu , Philipp Zabel , David Airlie , Daniel Vetter , Matthias Brugger , DRI Development , Linux ARM , linux-kernel , chunhui dai Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Frank: Frank Wunderlich =E6=96=BC 2020=E5=B9=B47=E6=9C= =8828=E6=97=A5 =E9=80=B1=E4=BA=8C =E4=B8=8B=E5=8D=887:19=E5=AF=AB=E9=81=93= =EF=BC=9A > > From: chunhui dai > > - disable tmds on phy on mt2701 > - support other resolutions like 1280x1024 If this patch does two things, it should be broken into two patches. > > without this Patch i see flickering on my TFT (1280x1024), > so i guess clock is wrong. > > Signed-off-by: chunhui dai > Signed-off-by: Frank Wunderlich > Tested-by: Frank Wunderlich > --- > drivers/gpu/drm/mediatek/mtk_hdmi_phy.c | 3 +++ > drivers/gpu/drm/mediatek/mtk_hdmi_phy.h | 1 + > drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c | 1 + > 3 files changed, 5 insertions(+) > > diff --git a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c b/drivers/gpu/drm/me= diatek/mtk_hdmi_phy.c > index 5223498502c4..edadb7a700f1 100644 > --- a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c > +++ b/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c > @@ -184,6 +184,9 @@ static int mtk_hdmi_phy_probe(struct platform_device = *pdev) > return PTR_ERR(phy_provider); > } > > + if (hdmi_phy->conf->pll_default_off) > + hdmi_phy->conf->hdmi_phy_disable_tmds(hdmi_phy); I think every pll is default off, so you should turn on pll rather than disable tmds. Regards, Chun-Kuang. > + > return of_clk_add_provider(dev->of_node, of_clk_src_simple_get, > hdmi_phy->pll); > } > diff --git a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h b/drivers/gpu/drm/me= diatek/mtk_hdmi_phy.h > index 2d8b3182470d..f472fdeb63dc 100644 > --- a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h > +++ b/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h > @@ -22,6 +22,7 @@ struct mtk_hdmi_phy; > struct mtk_hdmi_phy_conf { > bool tz_disabled; > unsigned long flags; > + bool pll_default_off; > const struct clk_ops *hdmi_phy_clk_ops; > void (*hdmi_phy_enable_tmds)(struct mtk_hdmi_phy *hdmi_phy); > void (*hdmi_phy_disable_tmds)(struct mtk_hdmi_phy *hdmi_phy); > diff --git a/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c b/drivers/gpu= /drm/mediatek/mtk_mt2701_hdmi_phy.c > index d3cc4022e988..6fbedacfc1e8 100644 > --- a/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c > +++ b/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c > @@ -239,6 +239,7 @@ static void mtk_hdmi_phy_disable_tmds(struct mtk_hdmi= _phy *hdmi_phy) > struct mtk_hdmi_phy_conf mtk_hdmi_phy_2701_conf =3D { > .tz_disabled =3D true, > .flags =3D CLK_SET_RATE_GATE, > + .pll_default_off =3D true, > .hdmi_phy_clk_ops =3D &mtk_hdmi_phy_pll_ops, > .hdmi_phy_enable_tmds =3D mtk_hdmi_phy_enable_tmds, > .hdmi_phy_disable_tmds =3D mtk_hdmi_phy_disable_tmds, > -- > 2.25.1 >