ADC Home > Reference Library > Technical Q&As > Legacy Documents > Hardware & Drivers >

Legacy Documentclose button

Important: This document is part of the Legacy section of the ADC Reference Library. This information should not be used for new development.

Current information on this Reference Library topic can be found here:

FWSendSoftwareInterrupt vs. SendSoftwareInterrupt


Q: What is the difference between SendSoftwareInterrupt and FWSendSoftwareInterrupt?

A: A: SendSoftwareInterrupt in DriverServicesLib doesn't actually do anything except immediately call the associated interrupt handler.

FWSendSoftwareInterrupt depends on a patch to WaitNextEvent for it's behavior. In general when you call FWSendSoftwareInterrupt, the handler installed using FWCreateSoftwareInterrupt gets run the next time WaitNextEvent is called. When you call FWCreateSoftwareInterrupt one of the parameters is a TaskID. FWSendSoftwareInterrupt tries to make sure that the TaskID of the software interrupt matches the TaskID of the current process according to the Process Manager. If you don't care what the current process is when you get called (as would likely be the case for a driver) pass in kInvalidID instead of FWCurrentTaskID when you call FWCreateSoftwareInterrupt. This way the software interrupt will get called the next time WaitNextEvent gets called after you call FWSendSoftwareInterrupt.


[Feb 13 2002]


Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.