Lines Matching refs:g_TcFunctions

146 TC_FUNCTIONS g_TcFunctions =  variable
172 TC_FUNCTIONS g_TcFunctions = variable
320 …currentStatus = InterlockedCompareExchange((LONG*)&g_TcFunctions.LoadStatus, TC_API_LOADING, TC_AP… in LoadTcFunctions()
324 …currentStatus = InterlockedCompareExchange((LONG*)&g_TcFunctions.LoadStatus, TC_API_LOADING, TC_AP… in LoadTcFunctions()
344 g_TcFunctions.hTcApiDllHandle = LoadLibrarySafe("TcApi.dll"); in LoadTcFunctions()
345 if (g_TcFunctions.hTcApiDllHandle == NULL) break; in LoadTcFunctions()
347g_TcFunctions.QueryPortList = (TcFcnQueryPortList) GetProcAddress(g_TcFunctions.hTcApiDllHan… in LoadTcFunctions()
348g_TcFunctions.FreePortList = (TcFcnFreePortList) GetProcAddress(g_TcFunctions.hTcApiDllHandl… in LoadTcFunctions()
350g_TcFunctions.StatusGetString = (TcFcnStatusGetString) GetProcAddress(g_TcFunctions.hTcApiDllH… in LoadTcFunctions()
352g_TcFunctions.PortGetName = (TcFcnPortGetName) GetProcAddress(g_TcFunctions.hTcApiDllHandle,… in LoadTcFunctions()
353g_TcFunctions.PortGetDescription = (TcFcnPortGetDescription) GetProcAddress(g_TcFunctions.hTcAp… in LoadTcFunctions()
355g_TcFunctions.InstanceOpenByName = (TcFcnInstanceOpenByName) GetProcAddress(g_TcFunctions.hTcAp… in LoadTcFunctions()
356g_TcFunctions.InstanceClose = (TcFcnInstanceClose) GetProcAddress(g_TcFunctions.hTcApiDllHan… in LoadTcFunctions()
357g_TcFunctions.InstanceSetFeature = (TcFcnInstanceSetFeature) GetProcAddress(g_TcFunctions.hTcAp… in LoadTcFunctions()
358g_TcFunctions.InstanceQueryFeature = (TcFcnInstanceQueryFeature) GetProcAddress(g_TcFunctions.hT… in LoadTcFunctions()
359g_TcFunctions.InstanceReceivePackets = (TcFcnInstanceReceivePackets) GetProcAddress(g_TcFunctions in LoadTcFunctions()
360g_TcFunctions.InstanceGetReceiveWaitHandle = (TcFcnInstanceGetReceiveWaitHandle)GetProcAddress(g_T… in LoadTcFunctions()
361g_TcFunctions.InstanceTransmitPackets = (TcFcnInstanceTransmitPackets)GetProcAddress(g_TcFunction… in LoadTcFunctions()
362g_TcFunctions.InstanceQueryStatistics = (TcFcnInstanceQueryStatistics)GetProcAddress(g_TcFunction… in LoadTcFunctions()
364g_TcFunctions.PacketsBufferCreate = (TcFcnPacketsBufferCreate) GetProcAddress(g_TcFunctions.hTcA… in LoadTcFunctions()
365g_TcFunctions.PacketsBufferDestroy = (TcFcnPacketsBufferDestroy) GetProcAddress(g_TcFunctions.hT… in LoadTcFunctions()
366g_TcFunctions.PacketsBufferQueryNextPacket = (TcFcnPacketsBufferQueryNextPacket)GetProcAddress(g_T… in LoadTcFunctions()
367g_TcFunctions.PacketsBufferCommitNextPacket = (TcFcnPacketsBufferCommitNextPacket)GetProcAddress(g… in LoadTcFunctions()
369g_TcFunctions.StatisticsDestroy = (TcFcnStatisticsDestroy) GetProcAddress(g_TcFunctions.hTcApi… in LoadTcFunctions()
370g_TcFunctions.StatisticsUpdate = (TcFcnStatisticsUpdate) GetProcAddress(g_TcFunctions.hTcApiDl… in LoadTcFunctions()
371g_TcFunctions.StatisticsQueryValue = (TcFcnStatisticsQueryValue) GetProcAddress(g_TcFunctions.hT… in LoadTcFunctions()
373 if ( g_TcFunctions.QueryPortList == NULL in LoadTcFunctions()
374 || g_TcFunctions.FreePortList == NULL in LoadTcFunctions()
375 || g_TcFunctions.StatusGetString == NULL in LoadTcFunctions()
376 || g_TcFunctions.PortGetName == NULL in LoadTcFunctions()
377 || g_TcFunctions.PortGetDescription == NULL in LoadTcFunctions()
378 || g_TcFunctions.InstanceOpenByName == NULL in LoadTcFunctions()
379 || g_TcFunctions.InstanceClose == NULL in LoadTcFunctions()
380 || g_TcFunctions.InstanceSetFeature == NULL in LoadTcFunctions()
381 || g_TcFunctions.InstanceQueryFeature == NULL in LoadTcFunctions()
382 || g_TcFunctions.InstanceReceivePackets == NULL in LoadTcFunctions()
383 || g_TcFunctions.InstanceGetReceiveWaitHandle == NULL in LoadTcFunctions()
384 || g_TcFunctions.InstanceTransmitPackets == NULL in LoadTcFunctions()
385 || g_TcFunctions.InstanceQueryStatistics == NULL in LoadTcFunctions()
386 || g_TcFunctions.PacketsBufferCreate == NULL in LoadTcFunctions()
387 || g_TcFunctions.PacketsBufferDestroy == NULL in LoadTcFunctions()
388 || g_TcFunctions.PacketsBufferQueryNextPacket == NULL in LoadTcFunctions()
389 || g_TcFunctions.PacketsBufferCommitNextPacket == NULL in LoadTcFunctions()
390 || g_TcFunctions.StatisticsDestroy == NULL in LoadTcFunctions()
391 || g_TcFunctions.StatisticsUpdate == NULL in LoadTcFunctions()
392 || g_TcFunctions.StatisticsQueryValue == NULL in LoadTcFunctions()
406 if (g_TcFunctions.hTcApiDllHandle != NULL) in LoadTcFunctions()
408 FreeLibrary(g_TcFunctions.hTcApiDllHandle); in LoadTcFunctions()
409 g_TcFunctions.hTcApiDllHandle = NULL; in LoadTcFunctions()
413 InterlockedExchange((LONG*)&g_TcFunctions.LoadStatus, currentStatus); in LoadTcFunctions()
459 status = g_TcFunctions.QueryPortList(&pPorts, &numPorts); in TcFindAllDevs()
498 status = g_TcFunctions.FreePortList(pPorts); in TcFindAllDevs()
520 name = g_TcFunctions.PortGetName(port); in TcCreatePcapIfFromPort()
521 description = g_TcFunctions.PortGetDescription(port); in TcCreatePcapIfFromPort()
600 status = g_TcFunctions.InstanceOpenByName(p->opt.device, &pt->TcInstance); in TcActivate()
605 …pcap_snprintf(p->errbuf, PCAP_ERRBUF_SIZE, "Error opening TurboCap adapter: %s", g_TcFunctions.Sta… in TcActivate()
633 status = g_TcFunctions.InstanceSetFeature(pt->TcInstance, TC_INST_FT_RX_STATUS, 1); in TcActivate()
637 …AP_ERRBUF_SIZE,"Error enabling reception on a TurboCap instance: %s", g_TcFunctions.StatusGetStrin… in TcActivate()
644 status = g_TcFunctions.InstanceSetFeature(pt->TcInstance, TC_INST_FT_TX_STATUS, 1); in TcActivate()
672 status = g_TcFunctions.InstanceSetFeature(pt->TcInstance, TC_INST_FT_READ_TIMEOUT, timeout); in TcActivate()
676 …ERRBUF_SIZE,"Error setting the read timeout a TurboCap instance: %s", g_TcFunctions.StatusGetStrin… in TcActivate()
735 status = g_TcFunctions.QueryPortList(&pPorts, &numPorts); in TcCreate()
750 if (strcmp(g_TcFunctions.PortGetName(pPorts[i]), device) == 0) in TcCreate()
762 (void)g_TcFunctions.FreePortList(pPorts); in TcCreate()
827 g_TcFunctions.PacketsBufferDestroy(pt->TcPacketsBuffer); in TcCleanup()
835 g_TcFunctions.InstanceClose(pt->TcInstance); in TcCleanup()
862 …status = g_TcFunctions.PacketsBufferCreate(sizeof(TC_PACKET_HEADER) + TC_ALIGN_USHORT_TO_64BIT((US… in TcInject()
866 …_ERRBUF_SIZE, "send error: TcPacketsBufferCreate failure: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcInject()
878 status = g_TcFunctions.PacketsBufferCommitNextPacket(buffer, &header, (PVOID)buf); in TcInject()
882 status = g_TcFunctions.InstanceTransmitPackets(pt->TcInstance, buffer); in TcInject()
886 …BUF_SIZE, "send error: TcInstanceTransmitPackets failure: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcInject()
891 …ZE, "send error: TcPacketsBufferCommitNextPacket failure: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcInject()
894 g_TcFunctions.PacketsBufferDestroy(buffer); in TcInject()
928 status = g_TcFunctions.InstanceReceivePackets(pt->TcInstance, &pt->TcPacketsBuffer); in TcRead()
931 …RBUF_SIZE, "read error, TcInstanceReceivePackets failure: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcRead()
970 status = g_TcFunctions.PacketsBufferQueryNextPacket(pt->TcPacketsBuffer, &tcHeader, &data); in TcRead()
974 g_TcFunctions.PacketsBufferDestroy(pt->TcPacketsBuffer); in TcRead()
981 …IZE, "read error, TcPacketsBufferQueryNextPacket failure: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcRead()
1067 status = g_TcFunctions.InstanceQueryStatistics(pt->TcInstance, &statistics); in TcStats()
1071 …RRBUF_SIZE, "TurboCap error in TcInstanceQueryStatistics: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcStats()
1077 …status = g_TcFunctions.StatisticsQueryValue(statistics, TC_COUNTER_INSTANCE_TOTAL_RX_PACKETS, &cou… in TcStats()
1080 …P_ERRBUF_SIZE, "TurboCap error in TcStatisticsQueryValue: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcStats()
1092 …status = g_TcFunctions.StatisticsQueryValue(statistics, TC_COUNTER_INSTANCE_RX_DROPPED_PACKETS, &c… in TcStats()
1095 …P_ERRBUF_SIZE, "TurboCap error in TcStatisticsQueryValue: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcStats()
1150 status = g_TcFunctions.InstanceQueryStatistics(pt->TcInstance, &statistics); in TcStatsEx()
1154 …RRBUF_SIZE, "TurboCap error in TcInstanceQueryStatistics: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcStatsEx()
1160 …status = g_TcFunctions.StatisticsQueryValue(statistics, TC_COUNTER_INSTANCE_TOTAL_RX_PACKETS, &cou… in TcStatsEx()
1163 …P_ERRBUF_SIZE, "TurboCap error in TcStatisticsQueryValue: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcStatsEx()
1175 …status = g_TcFunctions.StatisticsQueryValue(statistics, TC_COUNTER_INSTANCE_RX_DROPPED_PACKETS, &c… in TcStatsEx()
1178 …P_ERRBUF_SIZE, "TurboCap error in TcStatisticsQueryValue: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcStatsEx()
1235 status = g_TcFunctions.InstanceSetFeature(pt->TcInstance, TC_INST_FT_MINTOCOPY, (ULONG)size); in TcSetMinToCopy()
1239 … PCAP_ERRBUF_SIZE, "TurboCap error setting the mintocopy: %s (%08x)", g_TcFunctions.StatusGetStrin… in TcSetMinToCopy()
1250 return g_TcFunctions.InstanceGetReceiveWaitHandle(pt->TcInstance); in TcGetReceiveWaitHandle()