From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753079AbcIIIXu (ORCPT ); Fri, 9 Sep 2016 04:23:50 -0400 Received: from mail-pf0-f174.google.com ([209.85.192.174]:35611 "EHLO mail-pf0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752500AbcIIIXp (ORCPT ); Fri, 9 Sep 2016 04:23:45 -0400 Date: Fri, 9 Sep 2016 16:23:58 +0800 From: Phidias Chiang To: Mika Westerberg Cc: Anisse Astier , Linus Walleij , Heikki Krogerus , Yu C Chen , "linux-gpio@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] pinctrl: cherryview: Do not mask all interrupts on probe Message-ID: <20160909082358.GA23895@ktx> References: <20160817081344.GM30827@lahna.fi.intel.com> <20160818121328.GE30827@lahna.fi.intel.com> <20160818135813.GJ30827@lahna.fi.intel.com> <20160908101303.GA22716@ktx> <20160908102402.GC15313@lahna.fi.intel.com> <20160908162843.GB22716@ktx> <20160909061834.GG15313@lahna.fi.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20160909061834.GG15313@lahna.fi.intel.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 09, 2016 at 09:18:34AM +0300, Mika Westerberg wrote: > On Fri, Sep 09, 2016 at 12:28:43AM +0800, Phidias Chiang wrote: > > Hmm, how can that happen? The patch removes clearing of INTMASK and only > other place where it is cleared temporarily is on resume. Can you add > dev_info() calls like: > > /* Clear all interrupts */ > chv_writel(0xffff, pctrl->regs + CHV_INTSTAT); > dev_info(pctrl->dev, "INTMASK0: 0x%08x\n", readl(pctrl->regs + CHV_INTMASK)); > > ... > > gpiochip_set_chained_irqchip(chip, &chv_gpio_irqchip, irq, > chv_gpio_irq_handler); > dev_info(pctrl->dev, "INTMASK1: 0x%08x\n", readl(pctrl->regs + CHV_INTMASK)); > return 0; > > It should print the same values both time. > > Also which interrupt does not work and can you send me output of > /proc/interrupts? Output in dmesg: [ 2.054475] cherryview-pinctrl INT33FF:00: INTMASK0: 0x00000006 [ 2.055247] cherryview-pinctrl INT33FF:00: INTMASK1: 0x00000000 [ 2.055375] cherryview-pinctrl INT33FF:01: INTMASK0: 0x00004000 [ 2.056931] cherryview-pinctrl INT33FF:01: INTMASK1: 0x00000000 [ 2.057036] cherryview-pinctrl INT33FF:02: INTMASK0: 0x00000000 [ 2.057367] cherryview-pinctrl INT33FF:02: INTMASK1: 0x00000000 [ 2.057489] cherryview-pinctrl INT33FF:03: INTMASK0: 0x00000000 [ 2.058337] cherryview-pinctrl INT33FF:03: INTMASK1: 0x00000000 So it's somehow got cleared in the process after. And the following link is the complete /proc/interrupts: http://pastebin.com/qwamyKZb THe interrupt doesn't work is 9, when I made it work it responsed to pressing hotkeys.