ULONG
IoGetFunctionCodeFromCtlCode(
IN ULONG ControlCode
);
IoGetFunctionCodeFromCtlCode returns the value of the Function in a given IOCTL_XXX control code.
IoGetFunctionCodeFromCtlCode returns the value of the Function field (bits 2 through 13, inclusive) in the IOCTL_XXX.
See Part II of this manual for more information about the layout of IOCTL_XXX codes and using the CTL_CODE macro.
File system drivers also can call this routine to extract FSCTL_XXX function codes on receipt of an IRP_MJ_FILE_SYSTEM_CONTROL request.
Callers of IoGetFunctionCodeFromCtlCode must be running at IRQL <= DISPATCH_LEVEL.