Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp887903ybl; Tue, 13 Aug 2019 04:17:56 -0700 (PDT) X-Google-Smtp-Source: APXvYqxQCJVjIoAaFgAQlfh6RtP6YIbg0oel0PebO3/k4O5QwBfsXeT9v3nkz1agt8WxwWShWOPg X-Received: by 2002:a63:1f03:: with SMTP id f3mr33530164pgf.249.1565695075956; Tue, 13 Aug 2019 04:17:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565695075; cv=none; d=google.com; s=arc-20160816; b=Cg4TNs4OAMRaHxLVSU+RnbuG3gvpT/rhFguFxWDWxFYpfXRq2Qy9fS02ftcRdelDbt zwdsj/qz4dTtQpqbKnb0IuX9K6et+ev7Wuj1z+XniZJtxtbWdLEaw+oKyzrEGK5xxK5E /VosRatX0xHjcsKV9HOnCpRLJkSDdAolWSJh8OwRlyeEGztVSnAUc+vOMaVQ1D844AIX Ing+19MKgalCBOI+LP0rbRtC5yYJSK6WdnRAQMhmjwvshnGjeUqFP1lTzqr7VUxo3Euh Ji1EwGVW0IMUxDRNOWeMAbUdjaFbR6a9l3kRRcW81secZ/3tDbgtXrpZ+F1a22J2/PLa Rdvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=aFWecJjCjH2/wiVDay0ark0T2PtPRWCQGrri1tJLRSs=; b=WOd0lohRvDKPt/tC4/D7XxN6g9XOv+247VYDKJjMZVUkBWnwK2yAXxiwvp8oEhtg+E zk+R+krp9r32GHMHT7J6flWe7919VSH6qf5nmUDxMrESz3mYUM6Mf9LkEsGAWhTmraJo Tn2V/2bycEJP/5nFzLpy+a0mtxE3SPx35ZaojK5kvvsd/D2yFxe3FPJbn3d+U+6B662y TMw/AQrfN/Hq4iJrtk3dA2IphevsUpa85K91iBlfP3c/ZMof7XAQ0Z6e3oFrMVInWTHF 5ys5SvogCIcFaoXWDEu8UFi5lu2jneCDMtrapA4sn+/+qwz6E8QXpEpAzD3Ez6OsUUD8 Qg+A== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 33si60394022plk.225.2019.08.13.04.17.40; Tue, 13 Aug 2019 04:17:55 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728859AbfHMKLA (ORCPT + 99 others); Tue, 13 Aug 2019 06:11:00 -0400 Received: from honk.sigxcpu.org ([24.134.29.49]:52062 "EHLO honk.sigxcpu.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727466AbfHMKLA (ORCPT ); Tue, 13 Aug 2019 06:11:00 -0400 Received: from localhost (localhost [127.0.0.1]) by honk.sigxcpu.org (Postfix) with ESMTP id 030BEFB03; Tue, 13 Aug 2019 12:10:59 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at honk.sigxcpu.org Received: from honk.sigxcpu.org ([127.0.0.1]) by localhost (honk.sigxcpu.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id j52cSuWGG3AI; Tue, 13 Aug 2019 12:10:57 +0200 (CEST) Received: by bogon.sigxcpu.org (Postfix, from userid 1000) id B21FD416CC; Tue, 13 Aug 2019 12:10:57 +0200 (CEST) Date: Tue, 13 Aug 2019 12:10:57 +0200 From: Guido =?iso-8859-1?Q?G=FCnther?= To: Arnd Bergmann Cc: David Airlie , Daniel Vetter , Rob Herring , Mark Rutland , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Andrzej Hajda , Neil Armstrong , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , Lee Jones , dri-devel , DTML , Linux ARM , Linux Kernel Mailing List , Robert Chiras , Sam Ravnborg Subject: Re: [PATCH v2 1/3] arm64: imx8mq: add imx8mq iomux-gpr field defines Message-ID: <20190813101057.GB10751@bogon.m.sigxcpu.org> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Arnd, On Tue, Aug 13, 2019 at 10:08:44AM +0200, Arnd Bergmann wrote: > On Fri, Aug 9, 2019 at 6:24 PM Guido G?nther wrote: > > > > This adds all the gpr registers and the define needed for selecting > > the input source in the imx-nwl drm bridge. > > > > Signed-off-by: Guido G?nther > > + > > +#define IOMUXC_GPR0 0x00 > > +#define IOMUXC_GPR1 0x04 > > +#define IOMUXC_GPR2 0x08 > > +#define IOMUXC_GPR3 0x0c > > +#define IOMUXC_GPR4 0x10 > > +#define IOMUXC_GPR5 0x14 > > +#define IOMUXC_GPR6 0x18 > > +#define IOMUXC_GPR7 0x1c > (more of the same) > > huh? These are the names from the imx8MQ reference manual (general purpose registers, they lump together all sorts of things), it's the same on imx6/imx7): https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/include/linux/mfd/syscon/imx6q-iomuxc-gpr.h https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/include/linux/mfd/syscon/imx7-iomuxc-gpr.h > > +/* i.MX8Mq iomux gpr register field defines */ > > +#define IMX8MQ_GPR13_MIPI_MUX_SEL BIT(2) > > I think this define should probably be local to the pinctrl driver, to > ensure that no other drivers fiddle with the registers manually. The purpose of these bits is for a driver to fiddle with them to select the input source. Similar on imx7 it's already used for e.g. the phy refclk in the pci controller: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/pci/controller/dwc/pci-imx6.c#n638 The GPRs are not about pad configuration but gather all sorts of things (section 8.2.4 of the imx8mq reference manual): pcie setup, dsi related bits so I don't think this should be done via a pinctrl driver. Should we handle that differently than on imx6/7? Cheers, -- Guido