Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3171115imu; Fri, 23 Nov 2018 23:14:55 -0800 (PST) X-Google-Smtp-Source: AFSGD/UTNJOira6KnzOlh1Qbz+Vh4UrdxYMtvPpWniNVDfjY+ffoXiRDem6GO26SVK1eLlaOhbXs X-Received: by 2002:a65:41c2:: with SMTP id b2mr16759579pgq.67.1543043695224; Fri, 23 Nov 2018 23:14:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543043695; cv=none; d=google.com; s=arc-20160816; b=PHhwS8P92B6B4LgQ68cUetHj/uaH3uH2D4wGlZHzhxG/h/Nkxq9l8hgvkoJqaGjPEM pasbWu/bkXvsypMZQzKFxyZ+2FrS6n6R1oTmNwd0KxUAm3D1nUjWYoRVHsysMqkZRAo5 chPWbuBmkoVat/9g+46igQ5pOQ+Yk+HPKPnbMsNa5jO4nYwqvqO1CoX5ZQtCXzp+NkWB yXVrMgTke+D383FLaA//1x0265GxkPQkBLqW57h/TeO85FbVgEP4wEEBUaQSYP6TvK39 hcr9YoOnabR3k+g4su+XJs7E8Q513+mHZNVe463B2JMDU1s9nvxw8A+hrt+RdTi5P0oQ luYA== 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=d+DLraxmdchbGvjYyhCxoE1WKprIFlWjlKTCW48CXaM=; b=ymhCqm9+HWcVnRyOQYgsEvclD4r1HDUlbMBHKVj8+YFnd+fVjWlP5u0a1CUWFEjHoE bBvjv72nxoW4b6ZHT+zcv2WXJ5tVi3BQzU6eUZWZaVMKDEbQVmY0G6nKnz3yZkud17sq D/dqfXEE3l0pdmjKCspkzyUYA9rM85kNGVCGDjrfZdhBgir3bXuZHTqkwMT1Rh/I42r7 Q+UCWXv7GfC7dayeUTKuk+Dv+j0pINT/1b0DEr5er2CtySw4WudbW0ldfv8ielPu4oOF 5RHsbGyhs3RDehd43YNGA6F+56BuVAVemq2H8XC6iDqdbcPGUFqR4BX7fQ0Vyd9hTC4A 3gBw== 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 p14si31947579pfi.12.2018.11.23.23.14.40; Fri, 23 Nov 2018 23:14:55 -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; 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 S2404578AbeKWFoM (ORCPT + 99 others); Fri, 23 Nov 2018 00:44:12 -0500 Received: from metis.ext.pengutronix.de ([85.220.165.71]:56241 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728584AbeKWFoM (ORCPT ); Fri, 23 Nov 2018 00:44:12 -0500 Received: from ptx.hi.pengutronix.de ([2001:67c:670:100:1d::c0]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1gPuG3-0007Ml-Sv; Thu, 22 Nov 2018 20:03:23 +0100 Received: from ukl by ptx.hi.pengutronix.de with local (Exim 4.89) (envelope-from ) id 1gPuG2-00028E-04; Thu, 22 Nov 2018 20:03:22 +0100 Date: Thu, 22 Nov 2018 20:03:21 +0100 From: Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= To: =?utf-8?B?Vm9rw6HEjQ==?= Michal Cc: Lothar =?iso-8859-1?Q?Wa=DFmann?= , Thierry Reding , Mark Rutland , "devicetree@vger.kernel.org" , "linux-pwm@vger.kernel.org" , Lukasz Majewski , "linux-kernel@vger.kernel.org" , Rob Herring , "kernel@pengutronix.de" , Fabio Estevam , Linus Walleij , viresh kumar Subject: Re: [RCF PATCH,v2,2/2] pwm: imx: Configure output to GPIO in disabled state Message-ID: <20181122190321.ktqegs7kpvhcemvi@pengutronix.de> References: <20181109165555.vqbiwh4hlcnozdna@pengutronix.de> <20181114113449.GB2620@ulmo> <20181114215120.vddykljqyavm64wj@pengutronix.de> <20181115152545.GA8611@ulmo> <20181115203733.qvonika6yhn2bsnb@pengutronix.de> <20181116083430.7f1d8452@ipc1.ka-ro> <20181116082557.l2ljgu3hsu7tvdci@pengutronix.de> <91640f9b-d219-553e-043a-c6151f2f68d7@ysoft.com> <20181122162359.ufngpgxkenlmgqni@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c0 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Michal, On Thu, Nov 22, 2018 at 04:46:39PM +0000, Vokáč Michal wrote: > On 22.11.2018 17:23, Uwe Kleine-König wrote: > > On Thu, Nov 22, 2018 at 03:42:14PM +0000, Vokáč Michal wrote: > >> On 16.11.2018 09:25, Uwe Kleine-König wrote: > >>> On Fri, Nov 16, 2018 at 08:34:30AM +0100, Lothar Waßmann wrote: > >>>> No. You can disable the output driver via pinctrl, so that only the > >>>> selected pull-up/down is relevant. The pin function and GPIO register > >>>> settings don't matter at all in this case. > >> > >> Lothar, please can you be more specific how would you do that? IFAIK the > >> pull-up/down internal resistors have effect only if the pin is configured > >> as GPIO *input* (on i.MX6 at least). See the TRM, 29.4.2.2 Output driver: > >> > >> "Internal pull-up, pull-down resistors, and pad keeper are disabled in > >> output mode." This would mean you'd have to rely on an external pull up for your use case. I wouldn't be surprised however if DSE=0 wouldn't count as "output mode". Given the reliability of NXP documentation I wouldn't bet neither on one nor the other possibility. > > So I'd expect this to really work on i.MX6 but not the earlier SoCs > > without a gpio specifier. > > Maybe you would expect it to work but I already tested and measured > that weeks ago ;) It did not work. Which pin/gpio do we talk about? Which i.MX6 variant did you test this on? (Assuming i.MX6D or i.MX6Q and PAD_DISP0_DATA09, did you try setting IOMUXC_SW_MUX_CTL_PAD_DISP0_DATA09 (0x020E0194) = 0x00000005 IOMUXC_SW_PAD_CTL_PAD_DISP0_DATA09 (0x020E04A8) = 0x0000b080 and then play with GPIO 4.30 direction and output value?) Best regards Uwe -- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | http://www.pengutronix.de/ |