Jump to content

MFSH LOCK: Difference between revisions

From EDM2
No edit summary
Ak120 (talk | contribs)
mNo edit summary
Line 6: Line 6:


==Parameters==
==Parameters==
; usSel: is the selector of the segment to be locked.  
;usSel: is the selector of the segment to be locked.
; pulHandle: is a pointer to a double word which is filled in by the helper with the lock handle.  
;pulHandle: is a pointer to a double word which is filled in by the helper with the lock handle.


==Returns==
==Returns==
If no error is detected, a zero error code is returned. If an error is detected, one of the following error codes is returned:  
If no error is detected, a zero error code is returned. If an error is detected, one of the following error codes is returned:
 
;ERROR_PROTECTION_VIOLATION: the supplied address or selector is invalid.
; ERROR_PROTECTION_VIOLATION : the supplied address or selector is invalid.  


==Sample==
==Sample==
Line 22: Line 21:
==Remarks==
==Remarks==
This helper is for use by a mini-FSD with an imbedded device driver. It is the same as the standard device driver LOCK helper with the following assumptions: The lock is defined to be short term and will block until the segment is loaded.
This helper is for use by a mini-FSD with an imbedded device driver. It is the same as the standard device driver LOCK helper with the following assumptions: The lock is defined to be short term and will block until the segment is loaded.
[[Category:IFS]]

Revision as of 17:13, 21 May 2019

Lock a segment in place in physical memory.

Syntax

int far pascal MFSH_LOCK(usSel, pulHandle)

Parameters

usSel
is the selector of the segment to be locked.
pulHandle
is a pointer to a double word which is filled in by the helper with the lock handle.

Returns

If no error is detected, a zero error code is returned. If an error is detected, one of the following error codes is returned:

ERROR_PROTECTION_VIOLATION
the supplied address or selector is invalid.

Sample

unsigned short usSel;
unsigned long far * pulHandle;

int far pascal MFSH_LOCK(usSel, pulHandle)

Remarks

This helper is for use by a mini-FSD with an imbedded device driver. It is the same as the standard device driver LOCK helper with the following assumptions: The lock is defined to be short term and will block until the segment is loaded.