From the course: Linux Device Drivers: Reading, Writing, and Debugging

Unlock this course with a free trial

Join today to access over 25,500 courses taught by industry experts.

Network driver interrupt handling

Network driver interrupt handling

- [Instructor] Looking at interrupt handling in network drivers is a pretty good overview of how interrupt handling can be done, and it's particularly interesting in network devices. So we'll look at a lot of the fundamentals: registering the handler, configuring the NIC, the interrupt handler itself, deferring work, polling. So we'll look at the e1000e, a fairly well-known ethernet card. And it has a function, e1000_request_irq. And the function in the kernel to register an interrupt handler is request_irq. So the handler function is the e1000 interrupt, and it's saying for which interrupt, which IRQ, and it's saying it's shared. And it'll try to register with the MSI-X, which is faster, but it'll go back to the old way if that's not possible. So there's a function to configure for the MSI-X, and ya got to set some registers and so forth in the device. So these writels, alright, that's the way to write to memory on the device. So that's how you're configuring things. And the handler,…

Contents