Yoni Levin wrote:
> Yes, I removed the flag (0) and nothing change in both cases the request_irq
> return 0 which is good.
> Then I added enable_irq and I recived :
> 
> Unbalanced enable for IRQ 74

Yeah, sorry, I misremembered what IRQF_DISABLED does.  As Domen pointed 
out, you need to pass myirq, not 74, to request_irq().

> void CreateGPIOHandler()
> {
> 
>       unsigned int myirq=irq_create_mapping(NULL,74);
>       enable_irq(74);
>       printk("myirq is : %d \n",myirq);
>       int ret;
> 
>       ret=- request_irq(74, GPIOinterrupt_handler,0, "GPIO", NULL);
>       printk("ret is : %d \n",ret);
>       
> 
> }

Even if IRQF_DISABLED did do what I thought it did (I was thinking of 
IRQ_NOAUTOEN, which is apparently an ARM-only thing), you should never 
call enable_irq() before request_irq(), or without previously disabling 
it (either explicitly or via IRQ_NOAUTOEN).

-Scott
_______________________________________________
Linuxppc-embedded mailing list
[email protected]
https://ozlabs.org/mailman/listinfo/linuxppc-embedded

Reply via email to