summaryrefslogtreecommitdiff
path: root/network/wlan/WIFICX/drivercode/adapter.cpp
diff options
context:
space:
mode:
authorYang You (UU) <[email protected]>2025-11-16 12:38:39 -0800
committerYang You (UU) <[email protected]>2025-11-16 12:38:39 -0800
commit90a7fc175216f84a11cda994958cd1634341783f (patch)
treeb6dfba03bcc44b190ff18b5264adeac7f60f5926 /network/wlan/WIFICX/drivercode/adapter.cpp
parentc9aa1b84b884282ea161c528cb00d1417c0cdb50 (diff)
have the wifiHAL living with the wdfdevice addtional context memory
Diffstat (limited to 'network/wlan/WIFICX/drivercode/adapter.cpp')
-rw-r--r--network/wlan/WIFICX/drivercode/adapter.cpp18
1 files changed, 17 insertions, 1 deletions
diff --git a/network/wlan/WIFICX/drivercode/adapter.cpp b/network/wlan/WIFICX/drivercode/adapter.cpp
index e0ea86e6..f532ae02 100644
--- a/network/wlan/WIFICX/drivercode/adapter.cpp
+++ b/network/wlan/WIFICX/drivercode/adapter.cpp
@@ -7,7 +7,23 @@
#include "adapter.tmh"
_Use_decl_annotations_
-NTSTATUS WifiCxTestAdapterStart(NETADAPTER netAdapter)
+NTSTATUS WifiIhvInitAdapterContext(_In_ WDFDEVICE Device, _In_ NETADAPTER NetAdapter)
+{
+ PWIFI_IHV_DEVICE_CONTEXT deviceContext = WifiGetIhvDeviceContext(Device);
+ PWIFI_IHV_NETADAPTER_CONTEXT netAdapterContext = WifiGetIhvNetAdapterContext(NetAdapter);
+
+ if (deviceContext->primaryStaAdapter == WDF_NO_HANDLE)
+ {
+ deviceContext->primaryStaAdapter = NetAdapter;
+ }
+
+ netAdapterContext->WifiDeviceContext = deviceContext;
+
+ return STATUS_SUCCESS;
+}
+
+_Use_decl_annotations_
+NTSTATUS WifiIhvAdapterStart(NETADAPTER netAdapter)
{
TraceEntry();