vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Bijoy Thomas <bijoyjth@bluebottle.com> writes: > Hi all, > > I am trying to learn the flow of packets through the TCP/IP stack > and figured the implementation in the OpenBSD kernel would be a nice > place to look around > software interrupts. ether_input() does a schednetisr() that I > believe schedules ipintr(). What will happen if while ipintr() is > executing, another network interrupt occurs? Won't that schedule > another ipintr? Are these software interrupts stacked? Or will this > software interrupt just be ignored as the initial ipintr() is > running at splnet()? I guess I would like some general information > on how software interrupts are scheduled/managed in OpenBSD. Any > links/documentation would be appreciated. An interrupt does something like this: s = splfoo(); while (is_there_something_to_do()) { do_something(); } ack_the_interrupt(); splx(s); splfoo() blocks this interrupt from happening again. splx(s) restores the old interrupt level and checks for pending interrupts. if another interrupt was scheduled between the "ack_the_interrupt()" and "splx" the interrupt handler will run again. You really don't need to understand all the details under the hood, even though it's an interesting read if you have the patience to follow the code. //art |