From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934001AbcHJUvX (ORCPT ); Wed, 10 Aug 2016 16:51:23 -0400 Received: from hqemgate15.nvidia.com ([216.228.121.64]:11834 "EHLO hqemgate15.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933095AbcHJSLk (ORCPT ); Wed, 10 Aug 2016 14:11:40 -0400 X-PGP-Universal: processed; by hqnvupgp07.nvidia.com on Wed, 10 Aug 2016 07:09:08 -0700 Subject: Re: [Regression] "irqdomain: Don't set type when mapping an IRQ" breaks nexus7 gpio buttons To: Linus Walleij References: <566aa781-6364-07ba-054a-2fcce0f4331b@nvidia.com> <773ccdb0-a225-f2d0-eb5d-3c27243ee76b@nvidia.com> <57AAF6B7.7030902@arm.com> CC: Marc Zyngier , John Stultz , Thomas Gleixner , lkml , Bjorn Andersson From: Jon Hunter Message-ID: Date: Wed, 10 Aug 2016 15:12:21 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: X-Originating-IP: [10.26.11.242] X-ClientProxiedBy: UKMAIL101.nvidia.com (10.26.138.13) To UKMAIL101.nvidia.com (10.26.138.13) Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/08/16 14:58, Linus Walleij wrote: > On Wed, Aug 10, 2016 at 11:56 AM, Jon Hunter wrote: >> Hi Marc, Linus, >> On 10/08/16 10:41, Marc Zyngier wrote: >>> On 10/08/16 00:03, Linus Walleij wrote: >>>> On Tue, Aug 9, 2016 at 3:20 PM, Jon Hunter wrote: >>>> >>>>> If that works, then does the following also work (without the above) ... >>>>> >>>>> diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c >>>>> index b4c1bc7c9ca2..e111b72e3162 100644 >>>>> --- a/kernel/irq/chip.c >>>>> +++ b/kernel/irq/chip.c >>>>> @@ -824,6 +824,7 @@ __irq_do_set_handler(struct irq_desc *desc, irq_flow_handler_t handle, >>>>> irq_settings_set_norequest(desc); >>>>> irq_settings_set_nothread(desc); >>>>> desc->action = &chained_action; >>>>> + __irq_set_trigger(desc, irqd_get_trigger_type(&desc->irq_data)); >>>>> irq_startup(desc, true); >>>>> } >>>>> } > (...) >>>> I tried this on my problematic platform and then this happens: >>>> >>>> preparing networking... >>>> [ 2.628246] ------------[ cut here ]------------ >>>> [ 2.628303] WARNING: CPU: 0 PID: 92 at ../kernel/irq/chip.c:26 >>>> bad_chained_irq+0x44/0x4c > (...) >> Just to confirm is that with or without the proposed change? > > This is with: > + __irq_set_trigger(desc, irqd_get_trigger_type(&desc->irq_data)); > > No other changes. > > Before the change it boots, but the IRQs don't work. > > After the change it boots and crashes like that. OK. >> Linus, I have been trying to find out which qcom board has this smsc911x >> but I was unable to find any, so more info on the platform would be great! > > It has nothing to do with the SMSC911x per se. The problem pertains > to *all* IRQs from the PMIC. > > This is the original APQ8060 Dragonboard from BSquare. > https://dflund.se/~triad/krad/dragonboard/ Where can I see the DT source for this board? There is a arch/arm/boot/dts/qcom-apq8060-dragonboard.dts but this does not appear to be the same (does not have smsc911x). Cheers Jon -- nvpublic