LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 06-11-2010, 04:13 AM   #1
chxooi
LQ Newbie
 
Registered: May 2010
Posts: 24

Rep: Reputation: 0
UNIQ IRQ and Shared IRQ...I want to make Shared IRQ routin


before making some source code,
I am wondering about interrupt and polling also thread...

my question is....


if I use unique irq number, I could use ..

Code:
int irq_unique=UNIQIRQ;
ret = request_irq(irq_uniqe, unique_interrupt,
irq_flags, "unique", i);

static irqreturn_t unique_interrupt(int irq, void *dev_id)
{

do { iir = inb(up, IIR);)} 
 printk("interrupt\n");
 msleep(1000);
} while (1);

In my opinion , in this case, Do I use do -while structure ?
I think, if I use unique irq, it is almost same "not use do-while". right?

Code:
int irq_unique=UNIQIRQ;
ret = request_irq(irq_uniqe, unique_interrupt,
static irqreturn_t unique_interrupt(int irq, void *dev_id)
{
 printk("interrupt UNIQ\n");

irq_flags, "unique", i);
}

It is same.whenver UNIQIRQ happen, Could I see the "interrupt UNIQ" message? Am I right?


Q2)
If then.
HOWEVER, In case of SHARED-IRQ,
Do I have to make interrupt function using "double-linked list" like 8250.c??

If I use same function like "unique irq thing...above function..." , what happen ?, Can I even see the printk message ? or not ?

Actually, I don't know how I make the double-linked list.....

and also, why do I need to use {do-while} structure......

I think do -while is not a interrupt......

Can Somebody explain this structure or urls for this ?

by the way, I'm sorry about my stupid english, English is not mothers languge..forgive me...

But, I want to understand this whole mechanism.....

also, between "do-while" and "thread" or polling

do-while ....looks like thread or polling......

I don't understand.....do-while structure in the shared interrupt...

I have to make some device driver using "Shared IRQ -UART1"

please..if somebody understand what I'm saying.let me know..."




"

Last edited by chxooi; 06-11-2010 at 05:08 AM.
 
Old 06-12-2010, 07:30 AM   #2
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,927
Blog Entries: 45

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Hi,

Welcome to LQ!

You should look at 'The Great IRQ Debate in the Linux kernel' to get some insight and potential references that may lead you in another direction. Sure the article is dated. But the premise is still valid that there are potential gotcha traps.


The above links and others can be found at 'Slackware-Links'. More than just SlackwareŽ links!
 
  


Reply



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
Wondering what "do_IRQ: .176 No Irq handler for vector (irq -1)" means 4restg Linux - Newbie 1 10-27-2009 02:41 AM
ndiswrapper, windows driver, and IRQ 233 make Fedora Core 6 hang desperado Linux - Newbie 8 03-08-2008 11:26 PM
SCSI Errors when IRQ Shared - How do I not share IRQ MQMan Linux - Hardware 2 01-08-2006 11:42 PM
Shared IRQ 9 luigi Linux - Laptop and Netbook 1 12-15-2003 12:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 07:47 PM.

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