Share your knowledge at the LQ Wiki.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 12-06-2012, 05:06 AM   #1
LQ Newbie
Registered: Mar 2010
Posts: 11

Rep: Reputation: 0
Registering two handler for one intrrupt

hi all,

I am using C language and wanted to know whether it is possible to register two different handlers for the same intrrupt. If yes, than what we will be the system behavior.

Old 12-06-2012, 06:48 AM   #2
Registered: Sep 2012
Posts: 48

Rep: Reputation: Disabled
Can I ask you why you need 2 handlers for same interrupt?
Old 12-07-2012, 12:02 AM   #3
LQ Newbie
Registered: Mar 2010
Posts: 11

Original Poster
Rep: Reputation: 0

Actually we are trying to port 'Udhcpc' to our embedded linux application. But in source code of Udhcp, we've found that it has registered some interrupts with its handlers, which was already been registered by our application. Thus i had doubt about such scenerios.
Old 12-07-2012, 04:09 AM   #4
Registered: Sep 2012
Posts: 48

Rep: Reputation: Disabled
I don't think it's possible. Just add you code to existent handler.
Old 12-07-2012, 08:18 AM   #5
Senior Member
Registered: Dec 2004
Location: Marburg, Germany
Distribution: openSUSE 13.1
Posts: 1,320

Rep: Reputation: 252Reputation: 252Reputation: 252
Are you speaking here of hardware interrupts or signals?
Old 12-07-2012, 08:42 AM   #6
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 5,742

Rep: Reputation: 1299Reputation: 1299Reputation: 1299Reputation: 1299Reputation: 1299Reputation: 1299Reputation: 1299Reputation: 1299Reputation: 1299
The first-level interrupt handler can launch more than one second-level response to it, depending on the situation and architecture. Most commonly the second level response is a chain of subroutine-calls.


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
How to replace the default handler with user defined handler in Linux kernel ? vl chowdary Linux - Kernel 4 04-27-2011 02:09 PM
SIGSEGV handler (segmentation fauld handler) myp Programming 8 03-08-2011 02:17 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 01:11 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