cancel
Showing results for 
Search instead for 
Did you mean: 

sw_trigger questions

Jonathan W Edwards
Occasional Contributor

sw_trigger questions

The Driver Development Guide says "The sw_trigger() routine checks to see if the structure to which intloc points is already on the trigger queue. If it is, the kernel throws this request away, thus permitting only one pending request per sw_intloc structure."

Two questions:

1) How is the equality comparison performed? Is it by address (i.e., a given sw_intloc structure at a particular address cannot be added to the trigger queue a second time, even if its contents have been changed since it was first added) or by content (i.e., a new sw_intloc structure cannot be added to the trigger queue if its contents are identical to a structure already on the queue)?

2) At what point is the sw_intloc structure removed from the queue, thereby allowing it to be added again? Does this happen before the function the software trigger invokes is called, or after it returns?