Example #1
0
int SpiInit(struct DibBridgeContext *pContext)
{
#if (DIBCOM_TEST_MODE == TEST_MODE_HOOK)
  HookInit(pContext,DIBBRIDGE_MODE_SDIO,pContext->BoardHdl);
  HookSpiBusInit(pContext);
#endif
  return DIBSTATUS_SUCCESS;
}
Example #2
0
/****************************************************************************
* SramInit
****************************************************************************/
void SramInit(struct DibBridgeContext *pContext)
{
   /** Sram Controller Initialization code ***/

#if (DIBCOM_TEST_MODE == TEST_MODE_HOOK)
   HookInit(pContext,DIBBRIDGE_MODE_SRAM,pContext->BoardHdl);
   if(pContext->DibChip == DIB_FIREFLY)
     DibBridgeWriteReg16(pContext, 1817, 3);
#endif
}
Example #3
0
//
//	KIP Library initialization routine. Sets all required hooks.
//	Can be called early at the system startup when there are no debugger present and no kernel API avaliable.
//
NTSTATUS	KipInitialize(VOID)
{
    NTSTATUS	ntStatus = STATUS_SUCCESS;

    // Initializing hooking engine
    HookInit();

    // set ndis library hooks
    ntStatus = NdisSetHooks();

    return(ntStatus);
}
Example #4
0
void RegisterWindowClasses(void)
{
	WNDCLASS wndclass;
	WNDCLASSEX wndclassex;

	// Load app name
	szAppName = strdup(GetString(hInst, IDS_APPNAME));

	/* Main window class */
	wndclassex.cbSize        = sizeof(WNDCLASSEX);
	wndclassex.style         = CS_HREDRAW | CS_VREDRAW | CS_DBLCLKS | CS_OWNDC;
	wndclassex.lpfnWndProc   = WndProc;
	wndclassex.cbClsExtra    = 0;
	wndclassex.cbWndExtra    = 0;
	wndclassex.hInstance     = hInst;
	wndclassex.hIcon         = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ICON));
	wndclassex.hIconSm       = (HICON) LoadImage(hInst, MAKEINTRESOURCE(IDI_ICON), IMAGE_ICON, 16, 16, 0);
	wndclassex.hCursor       = LoadCursor(NULL, IDC_ARROW);
	wndclassex.hbrBackground = NULL;
	wndclassex.lpszMenuName  = MAKEINTRESOURCE(IDR_MAINMENU);
	wndclassex.lpszClassName = szAppName;
	RegisterClassEx(&wndclassex);

	/* Class for "offer" modeless dialogs */
	wndclass.style         = CS_HREDRAW | CS_VREDRAW | CS_OWNDC;
	wndclass.lpfnWndProc   = DefDlgProc;
	wndclass.cbClsExtra    = 0;
	wndclass.cbWndExtra    = DLGWINDOWEXTRA;
	wndclass.hInstance     = hInst;
	wndclass.hIcon         = LoadIcon(hInst, MAKEINTRESOURCE(IDI_OFFER));
	wndclass.hCursor       = LoadCursor(NULL, IDC_ARROW);
	wndclass.hbrBackground = NULL;
	wndclass.lpszMenuName  = NULL;
	wndclass.lpszClassName = "Offer";
	RegisterClass (&wndclass);

	GraphCtlRegister(hInst);

	HookInit(hInst);
}