Hi,
I am trying to port a device driver from Linux kernel version 2.6.22 to kernel version 3.14.15 for i:MX27 based platform.
I am stuck with a problem :smileysad: the "request_irq" for gpio irq controller (irq number 24 in 3.14) returns an invalid value error
code. Although the call to request_irq returns successful when called for other gpio irq number such as irq 228.
Here is the code snippet:
"The device tree node where irq is configured"
gpio_irq_hack {
compatible = "atlas,gpio_irq_hack";
interrupt-parent = <&aitc>;
interrupts = <8>;
interrupt-names = "irq_hack";
status = "okay";
};
"The driver code to register irq"
irq = platform_get_irq_byname (pdev, "irq_hack");
if (irq < 0) {
dev_err(&pdev->dev, "Couldn't register given IRQ\n");
return -EINVAL;
}
printk(KERN_DEBUG "gpio_irq_hack: registering IRQ %d\n", irq);
int ret = request_irq(irq, &gpio_irq_hack_handler, IRQF_TRIGGER_FALLING, "gpio_irq_hack", NULL);
if (ret) {
printk(KERN_ERR "gpio_irq_hack: cannot register IRQ %d ret:%d\n", irq, ret);
return -EIO;
}
Any suggestion how can it be fixed.
Hi Anees
these new kernels may be supported on community,
suggest to post this on meta-fsl-arm mailing list, so that someone
familiar with them could try to assist you. Latest official FSL release is 2.6.22 from
i.MX27 Product Development Kit|Freescale
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------