Questions tagged [irq]

An interrupt request is a hardware signal sent to the processor that temporarily stops a running program and allows to handle a hardware event.

In an IBM PC compatible personal computer, an interrupt request (or IRQ) is a hardware signal sent to the processor that temporarily stops a running program and allows a special program, an interrupt handler, to run instead. Interrupts are used to handle such events as data receipt from a modem or network, or a key press or mouse movement. The interrupt request level (IRQL) is the priority of an interrupt request.

Related tags:

193 questions
22
votes
3 answers

How to prevent g++ from optimizing out a loop controlled by a variable that can be changed by an IRQ?

Consider the following piece of code: unsigned global; while(global); global is modified in a function which is invoked by an IRQ. However, g++ removes the "is-not-zero" test and translates the while loop into an endless loop. Disabling the…
0xbadf00d
  • 14,584
  • 15
  • 60
  • 93
11
votes
2 answers

What happens when two interrupts occur at the same time in linux kernel

What happens when two interrupts occur at the same time in the Linux kernel..? If that processor has more than one CPU can the interrupts run on different cpu cores at the same time.
Adi
  • 699
  • 1
  • 6
  • 12
10
votes
2 answers

How CPU finds ISR and distinguishes between devices

I should first share all what I know - and that is complete chaos. There are several different questions on the topic, so please don't get irritated :). 1) To find an ISR, CPU is provided with a interrupt number. In x86 machines (286/386 and above)…
ultimate cause
  • 2,081
  • 4
  • 22
  • 38
8
votes
1 answer

Keyboard IRQ within an x86 kernel

I'm trying to program a very simple kernel for learning purposes. After reading a bunch of articles about the PIC and IRQs in the x86 architecture, I've figured out that IRQ1 is the keyboard handler. I'm using the following code to print the keys…
Delights
  • 341
  • 4
  • 10
8
votes
2 answers

what is chained irq in linux, when are they need to used?

What is chained IRQ ? What does chained_irq_enter and chained_irq_exit do, because after an interrupt is arised the IRQ line is disabled, but chained_irq_enter is calling functions related to masking interrupts. If the line is already disabled why…
valmiki
  • 631
  • 9
  • 20
8
votes
2 answers

Setting up IRQ mapping

I'm following several tutorials and references trying to get my kernel set up. I've come across some unfamiliar code in a tutorial that isn't explaining it at all. It's code that I'm told maps the 16 IRQs (0-15) to ISR locations 32-47: void…
Nicholas Flynt
  • 6,608
  • 12
  • 47
  • 69
7
votes
1 answer

For a shared interrupt line how do I find which interrupt handler to use?

For a shared interrupt line,I can have several interrupt handlers. The kernel will sequentially invoke all the handlers for that particular shared line. As far as I know, each handler, when invoked informs the kernel whether it was the correct…
hit.at.ro
  • 190
  • 2
  • 11
6
votes
2 answers

request_threaded_irq() is used in the driver why not request_irq()? What are the differences between two?

I posted this is the thread which discussed about request_threaded_irq but I did not get any reply. So I am posting it freshly. I am working on a touchscreen driver for capacitive touchscree. It used request_threaded_irq() call instead of…
iSegFault
  • 907
  • 2
  • 9
  • 17
6
votes
2 answers

Difference between request_irq and __interrupt

From what I read both are used to register interrupt handlers. I saw lots of request_irq calls in kernel code but not even one __interrupt call. Is __interrupt some way to register a handler from user space?
montezuma
  • 61
  • 1
  • 2
6
votes
1 answer

IRQ Handling from User Space Linux

I'm writting a driver for a synthesized device in an FPGA. The device has several IRQs and have requested them on my driver: irq = platform_get_resource(pdev, IORESOURCE_IRQ, 0); rc = request_irq(irq, &Custom_driver_handler,IRQF_TRIGGER_RISING ,…
eps_712
  • 115
  • 1
  • 8
6
votes
2 answers

Why are MSI interrupts not shared?

Can any body tell why MSI interrupts are not shareable in linux. PIN based interrupts can be shared by devices, but MSI interrupts are not shared by devices, each device gets its own MSI IRQ number. Why can't MSI interrupts be shared ?
valmiki
  • 631
  • 9
  • 20
6
votes
2 answers

ixgbe: setting the number of RX/TX queues

I want to set the number of RX/TX queues used by an Intel 10G NIC. Let me explain why: I am using an Intel 10G NIC of type X520, on a Dell R720 system. I am using ixgbe version 3.6.7-k. The kernel in Ubuntu 3.2.0-59. I am running my network…
Ofir Hermesh
  • 105
  • 1
  • 1
  • 6
6
votes
2 answers

Linux PCI Device Driver - Bus v. Kernel IRQ

I am writing a device driver for a PCIe card in Linux. I am trying to use interrupts in my driver. Reading the "IRQ Line" section of the PCI configuration register (offset 0x3C) reports that the assigned IRQ line for the device is 11. lspci -b -vv…
s.brookes
  • 169
  • 1
  • 10
6
votes
4 answers

How does linux kernel wake idle processor up when new task created?

I'm newbie on Linux Kernel. Currently, I looked into idle codes and had a quesition. When processor doesn't have any taks in their own runqueue then it may go into idle mode, specific WFI(wating for interrupt). (All I mentioned is about ARM…
Michael Lee
  • 61
  • 1
  • 3
5
votes
2 answers

GPIO IRQ on ARM based Embedded Linux

I'm trying to program an GPIO IRQ on AT91SAM9M10-EKES evaluation board. I successfully registered the IRQ, and the IRQ is working. However, some interrupts are missed. I'm sending 26, and I get only 22. The code: static irqreturn_t…
stdcall
  • 23,764
  • 14
  • 73
  • 118
1
2 3
12 13