View the Most Wanted LQ Wiki articles.
Go Back > Forums > > Member Intro
User Name
Password Member Intro New to Been a long time member but never made a post? Introduce yourself here.


  Search this Thread
Old 06-11-2009, 08:12 AM   #1
LQ Newbie
Registered: Jun 2009
Posts: 1

Rep: Reputation: 0
control is not going to interrupt handler when interrupt hits

Hi all,

Please help me to solve the issue in interrupt handler module for linux.

I am able to register the IRQ successfully. But my interrupt handler is not responding properly when I get a hardware interrupt.

Interrupt Status registers are responding properly when external interrupt occurs. But the following message"LOS interrupt has been occured " is not displaying in the kernel prompt.

Please have a look at the following code :

static int irq_handler(int irq, void *dev_id)

printk("LOS interrupt has been occured\n");

static int __init ofalc_init(void)

retval= request_irq(0x14,irq_handler,SA_SAMPLE_RANDOM,"ofalc",NULL);
if(retval == -EINVAL)
printk("invalid IRQ\n");
else if(retval == -EBUSY){
printk("IRQ already assigned\n");

printk("ret_value = %u : IRQ request has been succeeded\n",retval);
return 0;


Last edited by remyasj; 06-11-2009 at 08:24 AM. Reason: to change title
Old 11-12-2009, 12:56 AM   #2
Senior Member
Registered: Dec 2008
Posts: 4,667
Blog Entries: 29

Rep: Reputation: 916Reputation: 916Reputation: 916Reputation: 916Reputation: 916Reputation: 916Reputation: 916Reputation: 916
First of all you should not post such questions in introduction forums. It would have been better if you would have posted it here

Anyways, can you tell me for which device you are writing the interrupt handler?
I am asking you this question coz i've already written an interrupt handler for the "keyboard" and the "serial port". You can refer to the code in this link. You'll get a general idea where you are going wrong.

Kindly read the 3rd post of the following thread:

Last edited by TheIndependentAquarius; 04-20-2012 at 12:47 AM. Reason: corrected u


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Where interrupt handler should be written? Felicia23 Linux - Kernel 2 02-03-2009 01:16 AM
control is not going to interrupt handler when interrupt comes in serial driver sateeshalla Linux - Kernel 1 05-04-2006 09:43 AM
Linux Interrupt Handler lucky6969b Linux - Software 1 12-01-2005 11:55 AM
printk in the interrupt handler lordofring Programming 3 08-23-2005 08:00 PM
<0>Kernel panic: Aiee, killing interrupt handler! In interrupt handler - not syncing mrb Linux - Newbie 2 01-09-2005 09:47 AM

All times are GMT -5. The time now is 04:49 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration