Re: [BISECTED] v4.4-rc1 GPIO regression on OMAP1
Hi, On Thu, Nov 19, 2015 at 01:57:37PM +0200, Grygorii Strashko wrote: > On 11/18/2015 08:31 PM, Aaro Koskinen wrote: > > On Wed, Nov 18, 2015 at 02:58:38PM +0200, Grygorii Strashko wrote: > >> On 11/17/2015 11:42 PM, Aaro Koskinen wrote: > >>> Amstrad E3 computer (OMAP1) boot crashes early with v4.4-rc1. Bisected to: > >>> > >>> 450fa54cfd66e3dda6eda26256637ee8928af12a is the first bad commit > >>> commit 450fa54cfd66e3dda6eda26256637ee8928af12a > >>> Author: Grygorii Strashko> >>> Date: Fri Sep 25 12:28:03 2015 -0700 > >>> > >>> gpio: omap: convert to use generic irq handler > >> > >> Could you check pls if below change will solve this issue, pls? > >> > >> iff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c > >> index 56d2d02..2905e0d 100644 > >> --- a/drivers/gpio/gpio-omap.c > >> +++ b/drivers/gpio/gpio-omap.c > >> @@ -1129,7 +1129,7 @@ static int omap_gpio_chip_init(struct gpio_bank > >> *bank, > >> struct irq_chip *irqc) > >> } > >> > >> ret = gpiochip_irqchip_add(>chip, irqc, > >> - irq_base, handle_bad_irq, > >> + irq_base, handle_simple_irq, > >> IRQ_TYPE_NONE); > > > > Thanks for testing it. But I'd like to ask you for more help here if possible > :) > Above change is expected to fix the OMAP1 boot, but looking at the OMAP GPIO > code > I think that MPUIO IRQ are not working :( and this functionality has been > broken > long time ago - commit "gpio: omap: convert to use generic irq handler" has > just > made hidden issue visible. > (I've found only one OMAP1 board which uses MPUIO GPIO as IRQ (board-osk.c)). > > So, could I ask you to test another change instead of previous one? > > --- a/drivers/gpio/gpio-omap.c > +++ b/drivers/gpio/gpio-omap.c > @@ -1122,8 +1122,6 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, > struct irq_chip *irqc) > /* MPUIO is a bit different, reading IRQ status clears it */ > if (bank->is_mpuio) { > irqc->irq_ack = dummy_irq_chip.irq_ack; > - irqc->irq_mask = irq_gc_mask_set_bit; > - irqc->irq_unmask = irq_gc_mask_clr_bit; > if (!bank->regs->wkup_en) > irqc->irq_set_wake = NULL; > } This fixes the boot crash issue as well... > In my opinion real test will be > - request(any MPUIO GPIO IRQ, IRQF_TRIGGER_LOW/HIGH), > - trigger MPUIO GPIO IRQ > - free(MPUIO GPIO IRQ) ...but I don't think I can cover that with my boards (E3/770)? Anyone willing to donate a 5912 OSK? A. -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [BISECTED] v4.4-rc1 GPIO regression on OMAP1
On 11/18/2015 08:31 PM, Aaro Koskinen wrote: > Hi, > > On Wed, Nov 18, 2015 at 02:58:38PM +0200, Grygorii Strashko wrote: >> On 11/17/2015 11:42 PM, Aaro Koskinen wrote: >>> Amstrad E3 computer (OMAP1) boot crashes early with v4.4-rc1. Bisected to: >>> >>> 450fa54cfd66e3dda6eda26256637ee8928af12a is the first bad commit >>> commit 450fa54cfd66e3dda6eda26256637ee8928af12a >>> Author: Grygorii Strashko>>> Date: Fri Sep 25 12:28:03 2015 -0700 >>> >>> gpio: omap: convert to use generic irq handler >> >> Could you check pls if below change will solve this issue, pls? >> >> iff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c >> index 56d2d02..2905e0d 100644 >> --- a/drivers/gpio/gpio-omap.c >> +++ b/drivers/gpio/gpio-omap.c >> @@ -1129,7 +1129,7 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, >> struct irq_chip *irqc) >> } >> >> ret = gpiochip_irqchip_add(>chip, irqc, >> - irq_base, handle_bad_irq, >> + irq_base, handle_simple_irq, >> IRQ_TYPE_NONE); > Thanks for testing it. But I'd like to ask you for more help here if possible :) Above change is expected to fix the OMAP1 boot, but looking at the OMAP GPIO code I think that MPUIO IRQ are not working :( and this functionality has been broken long time ago - commit "gpio: omap: convert to use generic irq handler" has just made hidden issue visible. (I've found only one OMAP1 board which uses MPUIO GPIO as IRQ (board-osk.c)). So, could I ask you to test another change instead of previous one? --- a/drivers/gpio/gpio-omap.c +++ b/drivers/gpio/gpio-omap.c @@ -1122,8 +1122,6 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, struct irq_chip *irqc) /* MPUIO is a bit different, reading IRQ status clears it */ if (bank->is_mpuio) { irqc->irq_ack = dummy_irq_chip.irq_ack; - irqc->irq_mask = irq_gc_mask_set_bit; - irqc->irq_unmask = irq_gc_mask_clr_bit; if (!bank->regs->wkup_en) irqc->irq_set_wake = NULL; } In my opinion real test will be - request(any MPUIO GPIO IRQ, IRQF_TRIGGER_LOW/HIGH), - trigger MPUIO GPIO IRQ - free(MPUIO GPIO IRQ) -- regards, -grygorii -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [BISECTED] v4.4-rc1 GPIO regression on OMAP1
Hi, On Wed, Nov 18, 2015 at 02:58:38PM +0200, Grygorii Strashko wrote: > On 11/17/2015 11:42 PM, Aaro Koskinen wrote: > >Amstrad E3 computer (OMAP1) boot crashes early with v4.4-rc1. Bisected to: > > > > 450fa54cfd66e3dda6eda26256637ee8928af12a is the first bad commit > > commit 450fa54cfd66e3dda6eda26256637ee8928af12a > > Author: Grygorii Strashko> > Date: Fri Sep 25 12:28:03 2015 -0700 > > > > gpio: omap: convert to use generic irq handler > > Could you check pls if below change will solve this issue, pls? > > iff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c > index 56d2d02..2905e0d 100644 > --- a/drivers/gpio/gpio-omap.c > +++ b/drivers/gpio/gpio-omap.c > @@ -1129,7 +1129,7 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, > struct irq_chip *irqc) > } > > ret = gpiochip_irqchip_add(>chip, irqc, > - irq_base, handle_bad_irq, > + irq_base, handle_simple_irq, >IRQ_TYPE_NONE); This works! A. -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [BISECTED] v4.4-rc1 GPIO regression on OMAP1
Hi Aaro, On 11/17/2015 11:42 PM, Aaro Koskinen wrote: Amstrad E3 computer (OMAP1) boot crashes early with v4.4-rc1. Bisected to: 450fa54cfd66e3dda6eda26256637ee8928af12a is the first bad commit commit 450fa54cfd66e3dda6eda26256637ee8928af12a Author: Grygorii StrashkoDate: Fri Sep 25 12:28:03 2015 -0700 gpio: omap: convert to use generic irq handler Reverting the commit works (as a quick workaround at least). The crash log: [0.253612] Unable to handle kernel NULL pointer dereference at virtual address [0.262613] pgd = c0004000 [0.265754] [] *pgd= [0.269862] Internal error: Oops: 75 [#1] ARM [0.274734] Modules linked in: [0.278313] CPU: 0 PID: 1 Comm: swapper Not tainted 4.4.0-rc1-e3-los_afe0c+-2-g25379c0-dirty #1 [0.288246] Hardware name: Amstrad E3 (Delta) [0.293146] task: c1836000 ti: c1838000 task.ti: c1838000 [0.299155] PC is at irq_gc_mask_set_bit+0x1c/0x60 [0.304525] LR is at __irq_do_set_handler+0x118/0x15c [0.310165] pc : []lr : []psr: 60d3 [0.310165] sp : c1839c90 ip : c1862c64 fp : c1839c9c [0.322740] r10: r9 : c0411950 r8 : c0411bbc [0.328533] r7 : r6 : c185c310 r5 : c00444e8 r4 : c185c300 [0.335687] r3 : c1854b50 r2 : r1 : r0 : c185c310 [0.342858] Flags: nZCv IRQs off FIQs off Mode SVC_32 ISA ARM Segment kernel [0.351153] Control: 317f Table: 10004000 DAC: 0057 [0.357494] Process swapper (pid: 1, stack limit = 0xc1838190) [0.363917] Stack: (0xc1839c90 to 0xc183a000) [0.368837] 9c80: c1839cc4 c1839ca0 c0047d4c c0048480 [0.377916] 9ca0: 0050 c185c300 c00444e8 c1839cec c1839cc8 [0.386989] 9cc0: c0047dd4 c0047c44 c0046f40 a053 0050 c00444e8 0050 [0.396064] 9ce0: c1839d0c c1839cf0 c0047e1c c0047da0 c1862c64 0050 0050 [0.405139] 9d00: c1839d24 c1839d10 c01b345c c0047dfc c185cb00 c185c310 c1839d54 c1839d28 [0.414214] 9d20: c0049670 c01b3430 c0075888 c0043440 c1854b50 0001 0010 0050 [0.423293] 9d40: c185cb00 c0411bbc c1839d7c c1839d58 c0049894 c0049604 c1862c64 [0.432375] 9d60: c1854b50 c1862c64 c0419280 c1862c64 c1839d9c c1839d80 c01b3328 c004980c [0.441456] 9d80: c1862c64 c1862c64 c1862c10 c1854b50 c1839ddc c1839da0 c01b79f4 c01b32d4 [0.450530] 9da0: c0411958 c0419294 c0411950 c0419294 c0411984 [0.459605] 9dc0: c0419294 c03e45e8 c1839df4 c1839de0 c01fcf58 c01b7708 [0.468684] 9de0: c0411950 c045ce30 c1839e1c c1839df8 c01fb668 c01fcf3c c0411950 c0419294 [0.477759] 9e00: c0411984 c03e45e8 c1839e3c c1839e20 c01fb844 c01fb518 [0.486836] 9e20: c0419294 c01fb7a4 c1839e64 c1839e40 c01f9a90 c01fb7b4 [0.495913] 9e40: c185434c c185b450 c185b514 c0419294 c185b4e0 c041d9c8 c1839e74 c1839e68 [0.504991] 9e60: c01fb078 c01f9a28 c1839e9c c1839e78 c01facf8 c01fb068 c03931d0 c1839e88 [0.514069] 9e80: c0419294 c040bb80 c1804960 c03f5a08 c1839eb4 c1839ea0 c01fbdb0 c01fab7c [0.523150] 9ea0: c040bb80 c040bb80 c1839ec4 c1839eb8 c01fcf18 c01fbd40 c1839ed4 c1839ec8 [0.532227] 9ec0: c03f5a20 c01fcef0 c1839f4c c1839ed8 c000966c c03f5a18 c1839efc c1839ee8 [0.541304] 9ee0: c03e4604 c019b3b4 c03e2700 c1ffcd34 c1839f4c c1839f00 c00314ec c03e45f8 [0.550384] 9f00: 0002 0002 c03e2024 c038f2fc [0.559465] 9f20: c1839f4c 0002 c03ff81c 0002 c03ff820 005e c042ba80 c042ba80 [0.568543] 9f40: c1839f94 c1839f50 c03e4e14 c00095f0 0002 0002 c03e45e8 [0.577625] 9f60: 9b7bd08b c0406660 ad19cf47 c0305764 [0.586701] 9f80: c1839fac c1839f98 c0305774 c03e4d18 c0305764 [0.595775] 9fa0: c1839fb0 c000a440 c0305774 [0.604845] 9fc0: [0.613916] 9fe0: 0013 faef8a80 f438707c [0.622908] Backtrace: [0.625894] [] (irq_gc_mask_set_bit) from [] (__irq_do_set_handler+0x118/0x15c) [0.635897] [] (__irq_do_set_handler) from [] (__irq_set_handler+0x44/0x5c) [0.645458] r6: r5:c00444e8 r4:c185c300 [0.650746] [] (__irq_set_handler) from [] (irq_set_chip_and_handler_name+0x30/0x34) [0.661128] r7:0050 r6: r5:c00444e8 r4:0050 [0.667559] [] (irq_set_chip_and_handler_name) from [] (gpiochip_irq_map+0x3c/0x8c) [0.677869] r7:0050 r6: r5:0050 r4:c1862c64 [0.684300] [] (gpiochip_irq_map) from [] (irq_domain_associate+0x7c/0x1c4) [0.693885] r5:c185c310 r4:c185cb00 [0.698072] []