Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp909757ybv; Thu, 20 Feb 2020 09:23:49 -0800 (PST) X-Google-Smtp-Source: APXvYqy5V01rcMMpvtXTK99SSb99MHoVOc97rLctev9B43pYn41XeIwzgHXTbf5rWVgLfycN+aQJ X-Received: by 2002:a05:6808:50:: with SMTP id v16mr2705146oic.133.1582219429447; Thu, 20 Feb 2020 09:23:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582219429; cv=none; d=google.com; s=arc-20160816; b=qZ6IBV744+egEAGPnNxxLflZjdCB5sjs0qm8pzOl5WR2PyyGyTnzf6Vb8PdezxfV4q 8l9m9pABwcyntC4RiwxloLpnlX61mSyD6XTeksafUPEmlOemrlbTpHeoOyB8gqM624ru 70z3rme/oovhGC8C7crwD0AixHGeFwZn0RVETRdgBun1OC43K9+uvFgq9F2deGpeFLij B5FO64NBUI4LnohtXSbtyV4fD6RxklnOIP0z0/C4jvrUpXo1u5oL51+vRcF2DIjvo5Ms E142A+O65ptv7uuJ7IKf4Z/2xzuAzR445ES327yk3uENffdtLH+WYUXjRNp1bmrgofJN nfPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature:dkim-signature; bh=F59Fd4S1GGUgMmZ4kteMtbJWPk0n14U6PXOXNH3ut34=; b=nhQA/qgGyh1ke1Crkk8FMFbwEfb6CwRW6Vb0Eofc4Ii51T1OCZ05VaPbUEPFAZN+aN B+CcBZxc0wYTMEXlVKHM4IpsRahECE6jYdCzr1pD1OsL99snOdl7dHT9r6NnPS9NZQkz OukLNt98qA4VW1vKbrI7J/hwhkmjPNzqDhQB/DaWijpV7C9UVJ2JhlbBdJqohFfnYYkc A3f//ua1JmCfOPse/ZtvdsEaTsHdYLX4MM1fyLRhEtCSZIIRDxK0zAdkSk/ztOYB/G0y okHHLMeXpgjVt1ODSRjUrDOO95cn+4XkyHJmlLT6Cxv/Ys9ezJqOh8ZfR6BaXRoHZKpO 6Dyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm2 header.b=VUHxBO0z; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b="tbv/SagD"; 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=cerno.tech Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l5si40529otn.35.2020.02.20.09.23.36; Thu, 20 Feb 2020 09:23:49 -0800 (PST) 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=@cerno.tech header.s=fm2 header.b=VUHxBO0z; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b="tbv/SagD"; 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=cerno.tech Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728739AbgBTRWA (ORCPT + 99 others); Thu, 20 Feb 2020 12:22:00 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:37869 "EHLO out1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728692AbgBTRV7 (ORCPT ); Thu, 20 Feb 2020 12:21:59 -0500 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 593AF21D6E; Thu, 20 Feb 2020 12:21:58 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Thu, 20 Feb 2020 12:21:58 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm2; bh=F59Fd4S1GGUgMmZ4kteMtbJWPk0 n14U6PXOXNH3ut34=; b=VUHxBO0zQwwgUd9v0sbrKeNgkepO9x6Mgsf07D+aXm3 7sh5tSnnfbQduIEa0niXhJJ5PzhwSD/VJZNM1Iy22X2BVUZifuds1zoB/Yw1WfqK 98piyQbeTHBkz9Nm3BeA83uYYfVwIgd1kqDxJRZLJG3dff4R5PvzJCFgk7LKK3gL P6NH8pDPpzdlaBQJcfsnfkSDBCm6eh4LD3zKyOOsrke8T55Jc409Y38bCimGuQ3l mXUQP6N407IkE0BT7Ro6GovOkpO03VTbRtUxXMF71lmQ0URuFWhY0OiZ7KSfPi+g rhI2eidcHWV+qPj/v1AOB3vajzk8iL42niuNjlhK6rg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=F59Fd4 S1GGUgMmZ4kteMtbJWPk0n14U6PXOXNH3ut34=; b=tbv/SagDhZJx3TKjU5lu6L zMypsEcVI8cEuzk3Nj5rMqlQv6saXzs7QM4MbnsPXzFuKeb7ysS/G5Px2MmeTHn1 ghedvtWLg5IINkkR3n4O1f9VNJP92F9wak2qI4A9hfwR5iBP6UdzqAv+sOAH1Ac/ rMyAXPRpKcPiWO8NX/683vsry8LfOyRu+jyx5KYLpLqueQagi/CNvoOS9Qva7Eeq xMLWmRPwaIIhBVCOR8XJkYPVzyrIVEgFZAeQWZx6/lUoUQXcWhuHp/aysYOgvDCw C85AlMDbj/IDpJcwyOnlm+ZX04tJLcrNJLECm4fdEs+1SukHoquNuKdapMRBTbFA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrkedvgddutddvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtuggjsehgtderredttddvnecuhfhrohhmpeforgigihhm vgcutfhiphgrrhguuceomhgrgihimhgvsegtvghrnhhordhtvggthheqnecukfhppeeltd drkeelrdeikedrjeeinecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghi lhhfrhhomhepmhgrgihimhgvsegtvghrnhhordhtvggthh X-ME-Proxy: Received: from localhost (lfbn-tou-1-1502-76.w90-89.abo.wanadoo.fr [90.89.68.76]) by mail.messagingengine.com (Postfix) with ESMTPA id 4926D328005A; Thu, 20 Feb 2020 12:21:56 -0500 (EST) Date: Thu, 20 Feb 2020 18:21:54 +0100 From: Maxime Ripard To: Andrey Lebedev Cc: wens@csie.org, airlied@linux.ie, daniel@ffwll.ch, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-sunxi@googlegroups.com, Andrey Lebedev Subject: Re: [PATCH 1/5] drm/sun4i: tcon: Introduce LVDS setup routine setting Message-ID: <20200220172154.22gw55s2mzyr45tj@gilmour.lan> References: <20200210195633.GA21832@kedthinkpad> <20200219180858.4806-1-andrey.lebedev@gmail.com> <20200219180858.4806-2-andrey.lebedev@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="c624jhpfn4hat26s" Content-Disposition: inline In-Reply-To: <20200219180858.4806-2-andrey.lebedev@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --c624jhpfn4hat26s Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Feb 19, 2020 at 08:08:54PM +0200, Andrey Lebedev wrote: > From: Andrey Lebedev > > Different sunxi flavors require slightly different sequence for enabling > LVDS output. This allows to differentiate between them. > > Signed-off-by: Andrey Lebedev > --- > drivers/gpu/drm/sun4i/sun4i_tcon.c | 68 ++++++++++++++++-------------- > drivers/gpu/drm/sun4i/sun4i_tcon.h | 3 ++ > 2 files changed, 39 insertions(+), 32 deletions(-) > > diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c > index c81cdce6ed55..cc6b05ca2c69 100644 > --- a/drivers/gpu/drm/sun4i/sun4i_tcon.c > +++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c > @@ -114,46 +114,48 @@ static void sun4i_tcon_channel_set_status(struct sun4i_tcon *tcon, int channel, > } > } > > +static void sun6i_tcon_setup_lvds_phy(struct sun4i_tcon *tcon, > + const struct drm_encoder *encoder) > +{ > + u8 val; > + > + regmap_write(tcon->regs, SUN4I_TCON0_LVDS_ANA0_REG, > + SUN6I_TCON0_LVDS_ANA0_C(2) | > + SUN6I_TCON0_LVDS_ANA0_V(3) | > + SUN6I_TCON0_LVDS_ANA0_PD(2) | > + SUN6I_TCON0_LVDS_ANA0_EN_LDO); > + udelay(2); > + > + regmap_update_bits(tcon->regs, SUN4I_TCON0_LVDS_ANA0_REG, > + SUN6I_TCON0_LVDS_ANA0_EN_MB, > + SUN6I_TCON0_LVDS_ANA0_EN_MB); > + udelay(2); > + > + regmap_update_bits(tcon->regs, SUN4I_TCON0_LVDS_ANA0_REG, > + SUN6I_TCON0_LVDS_ANA0_EN_DRVC, > + SUN6I_TCON0_LVDS_ANA0_EN_DRVC); > + > + if (sun4i_tcon_get_pixel_depth(encoder) == 18) > + val = 7; > + else > + val = 0xf; > + > + regmap_write_bits(tcon->regs, SUN4I_TCON0_LVDS_ANA0_REG, > + SUN6I_TCON0_LVDS_ANA0_EN_DRVD(0xf), > + SUN6I_TCON0_LVDS_ANA0_EN_DRVD(val)); > + > +} > + There's an extra blank line here that was reported by checkpatch. I've fixed it up while applying. Maxime --c624jhpfn4hat26s Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCXk7AMgAKCRDj7w1vZxhR xRPmAQCP8Snrmn5Bhh4728GFgDNTv5Vaa/Z6hDqOEA60JuEqfwEAjU5pw2xAgG6t RZ127dNTQF3BXJ+J4Y6udTTvuGBrRwo= =Jwt1 -----END PGP SIGNATURE----- --c624jhpfn4hat26s--