Macros | Functions | Variables
vdd.c File Reference

VDD for accessing the driver from DOS. More...

#include <windows.h>
#include <vddsvc.h>
#include <opencbm.h>
#include "debug.h"
#include "vdd.h"
#include <stdlib.h>

Go to the source code of this file.


#define DBG_DLL
#define DBG_IS_DEBUG_C
#define EXTERN   __declspec(dllexport)


EXTERN BOOL VDDInitialize (IN HANDLE Module, IN DWORD Reason, IN LPVOID Reserved)
 VDD initialization und unloading. More...
 RegisterModule processing. More...
 RegisterModule processing. More...


HANDLE vdd_handle

Detailed Description

VDD for accessing the driver from DOS.

Spiro Trikaliotis

Definition in file vdd.c.

Macro Definition Documentation

#define DBG_DLL

Mark: We are building a DLL

Definition at line 29 of file vdd.c.

#define DBG_IS_DEBUG_C

This file is "like" debug.c, that is, define some variables

Definition at line 35 of file vdd.c.


The name of the executable

Definition at line 32 of file vdd.c.


Mark: We are in user-space (for debug.h)

Definition at line 26 of file vdd.c.

#define EXTERN   __declspec(dllexport)

we are exporting the functions

Definition at line 46 of file vdd.c.

Function Documentation

VOID VDDDispatch ( VOID  )
BOOL VDDInitialize ( IN HANDLE  Module,
IN DWORD  Reason,
IN LPVOID  Reserved 

VDD initialization und unloading.

This function is called whenever the VDD is loaded or unloaded. It ensures that the driver is loaded to be able to call its functions.

ModuleHandle of the module; this is not used.
ReasonDLL_PROCESS_ATTACH if the DLL is loaded, DLL_PROCESS_DETACH if it is unloaded.
ReservedNot used.
Returns TRUE on success, else FALSE.

Definition at line 94 of file vdd.c.

References DBG_ASSERT, DBG_PREFIX, DBG_PRINT, FUNC_ENTER, FUNC_LEAVE_BOOL, vdd_cbmfile_closeall(), vdd_handle, and vdd_uninstall_iohook_internal().

VOID VDDRegisterInit ( VOID  )

RegisterModule processing.

This function is called when the DOS portion calls the REGISTERMODULE function.

Definition at line 132 of file vdd.c.

References FUNC_ENTER, and FUNC_LEAVE.

Variable Documentation

HANDLE vdd_handle

The handle of the vdd (for being accessed by the I/O hook install functions

Definition at line 54 of file vdd.c.

Referenced by vdd_install_iohook(), vdd_uninstall_iohook_internal(), and VDDInitialize().