Showing changes from revision #1 to #2:
Added | Removed | Changed
Entry | |
---|---|
R1 | 120 (&78) |
Exit | |
---|---|
R1-R3 | Preserved to pass on, else |
R1 | 0 (claimed) |
R3 | Pointer to block (20 bytes in size) |
This service is issued when a PDriver module is about to open Resources:$.Resources.PDrivers.Messages
.
If another PDriver module has already opened this file, it should claim the service and return the block pointed to by R3.
If a PDriver module issues this service and it goes unclaimed, it should allocate 20 bytes with OS_Module 6, pass the block to MessageTrans_OpenFile, and set the last word (usage count) to 1.
If the service is claimed, then the PDriver module should increase the usage count in the block by 1.
Either way, when the PDriver module is finished with the file, it should decrease the usage count in the block by 1. If this reduces the count to 0, it should call MessageTrans_CloseFile and then OS_Module 7 to free the block.