Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp5542140imu; Mon, 26 Nov 2018 01:50:25 -0800 (PST) X-Google-Smtp-Source: AFSGD/WcbYip85NlruJu/wIQq7aMC84V4Q3vKqbjmIbJhdxISsSM+yYaWVNZ2U4qtVPwS6onMdnV X-Received: by 2002:a63:c00b:: with SMTP id h11mr24613395pgg.429.1543225825445; Mon, 26 Nov 2018 01:50:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543225825; cv=none; d=google.com; s=arc-20160816; b=Tgbw4jR8vPr+HVCjMbqJ8cXK7nVBGlicVBdWXVeh3mQA5ABGk3BPABSJyPcOpJnmGm UzdoWDEgMY8TDmL7bV7Bryzmdeprr3bcGc6Qh4bncyPVWelO8/dRbQtvVj3GD/+Q4nxR 4G/yLCWgUvA0IgcyTR1pyCp0v74+8p9NjXRADR+lEaNLL6T5yEv7ZPk9XSIUsCaRzYo4 UErFaybWFT+bU8QIJv2TjSRiqhTtmDR/GFeotBXeriZpjr/K4Ff9n7lD/+COPvwCimst L20CXGxw6Jr0M7MyKtPwMEAeXNo7Kj7f+pS1BbyM4LruAwZ4xCb7pYB5dm/MHocoSfLo M/ZQ== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=u76TlQpPsm+1e7kgGekCZ9xvT0awBuq6MaFcju4bxPk=; b=HxmcCjTaHt0c2ALG7CCke9gZtyYKcmRdjd1uW9PA55AGhClYEFZEFTaCVt+Fv4R7En 0eZtFv3N1a6rJrYypC2jsnFeLMr1tfpJa5FBx5D9PsYiyHLvZMtyl61+uDuLslYzFA2w rz4aTCAJkYzRTrhVDaHmommqbLfHSEa+CgCHjGf210lV5hkJg7EGz0FYO2YF5O50syca PvaC0ZyOL9h7ZKa3tQ1nOT1deMXpQGLxqNjQKx9dWfmz2TScFgEWq6JDkqwliErHQMMz T5affiHgHPBsja7YnsSGDMOD1HOI8xX9djJPf/vuRGo2oqdz2Z5tpi8m4rgh27/ZyqQQ +Oiw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=t4cIGTr0; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u5si34352408plj.129.2018.11.26.01.50.10; Mon, 26 Nov 2018 01:50:25 -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=@ti.com header.s=ti-com-17Q1 header.b=t4cIGTr0; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726259AbeKZUnB (ORCPT + 99 others); Mon, 26 Nov 2018 15:43:01 -0500 Received: from lelv0142.ext.ti.com ([198.47.23.249]:43072 "EHLO lelv0142.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726176AbeKZUnA (ORCPT ); Mon, 26 Nov 2018 15:43:00 -0500 Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id wAQ9nJPo021384; Mon, 26 Nov 2018 03:49:19 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1543225759; bh=u76TlQpPsm+1e7kgGekCZ9xvT0awBuq6MaFcju4bxPk=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=t4cIGTr02ImJ1csOVMMTRSxndFCfOFQyjLPwYyzqQC2TTFKnAG8b2lSBrdvm6xqPK 53M44hWRFZfZK0MYS6uEWKI++V80Yr4UtYV/nJBOXhLkXk/VZ3pPD2AOuGVESc1/wn C7Vcg09XVZN68ttREfVKXw3VMulJCfgZ/UJ1887M= Received: from DFLE105.ent.ti.com (dfle105.ent.ti.com [10.64.6.26]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id wAQ9nJCr053359 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 26 Nov 2018 03:49:19 -0600 Received: from DFLE107.ent.ti.com (10.64.6.28) by DFLE105.ent.ti.com (10.64.6.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10; Mon, 26 Nov 2018 03:49:19 -0600 Received: from dlep33.itg.ti.com (157.170.170.75) by DFLE107.ent.ti.com (10.64.6.28) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1591.10 via Frontend Transport; Mon, 26 Nov 2018 03:49:19 -0600 Received: from [172.22.5.0] (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep33.itg.ti.com (8.14.3/8.13.8) with ESMTP id wAQ9nEfC024156; Mon, 26 Nov 2018 03:49:15 -0600 Subject: Re: omap5 fixing palmas IRQ_TYPE_NONE warning leads to gpadc timeouts To: Thierry Reding , Tony Lindgren CC: Jon Hunter , Belisko Marek , LKML , , "Dr. H. Nikolaus Schaller" , Laxman Dewangan References: <20180703084516.GT112168@atomide.com> <20181113180656.GE53235@atomide.com> <46d271b2-35d3-6353-c530-3292cdac53ab@ti.com> <20181119161906.GP53235@atomide.com> <20181119171406.GQ53235@atomide.com> <725df8e7-4aff-3751-d0b0-809b89e882e5@nvidia.com> <20181123164827.GE53235@atomide.com> <20181126093625.GA10878@ulmo> From: Peter Ujfalusi Message-ID: Date: Mon, 26 Nov 2018 11:49:54 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.1 MIME-Version: 1.0 In-Reply-To: <20181126093625.GA10878@ulmo> Content-Type: text/plain; charset="windows-1252" Content-Language: en-US Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thierry, On 11/26/18 11:36 AM, Thierry Reding wrote: > On Fri, Nov 23, 2018 at 08:48:27AM -0800, Tony Lindgren wrote: >> * Jon Hunter [181120 11:14]: >>> On 19/11/2018 17:14, Tony Lindgren wrote: >>>> Well so commit 7e9d474954f4 ("ARM: tegra: Correct polarity for >>>> Tegra114 PMIC interrupt") states that tegra114 inverts the >>>> polarity of the PMIC interrupt. So adding Jon and Thierry to Cc. >>> >>> Yes Tegra can invert the polarity of the PMIC interrupt. >> >> So is there some IP on Tegra called "Tegra PMC" that is >> inverting the interrupt? Or is the "Tegra PMC" that commit >> 7e9d474954f4 mentions just the palmas configuration for >> inverting the interrupt? > > Yes, there's indeed an IP called PMC (Power-Management Controller) on > Tegra. It has a special input that is usually wired up to the PMIC > interrupt and a bit in the control register that configures the polarity > of that interrupt. If the PMIC generates a low-active interrupt we > usually set that bit to make sure it is properly sampled by the PMC. > > The symptoms of this being incorrectly configured is usually an > interrupt storm on the PMIC interrupt, which I think typically results > in the system not booting at all, or taking a very long time to boot > because of that storm. > >> The problem I'm having is With omap5 where I can only get the >> PMIC interrupts working with IRQ_TYPE_LEVEL_HIGH if >> PALMAS_POLARITY_CTRL_INT_POLARITY is not set unlike for >> Tegra. > > Does somebody have access to the Palmas documentation? That should > pretty clearly state what the default polarity is and what it changes to > if you set the interrupt polarity bit. The register map documentation I have states the following: bit7 INT_POLARITY Select the polarity of the INT output line 0: Interrupt line (INT) is low when interrupt is pending (default) RW 1: Interrupt line (INT) is high when interrupt is pending By default the Palmas irq is active low. > From what you're saying it sounds like either the logic is the wrong way > around in the Palmas MFD driver (and we correct it by switching it back > to the correct polarity in the PMC) or that you'd need to find some way > of inverting in on OMAP5. > > Thierry > - Peter Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki