# harshavardhanp1/rdk-wifi-hal architecture

> Architecture diagram of the GitHub repository harshavardhanp1/rdk-wifi-hal, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/harshavardhanp1/rdk-wifi-hal
- Repository: https://github.com/harshavardhanp1/rdk-wifi-hal

## Overview

rdk-wifi-hal is a C Wi-Fi abstraction layer for RDK platforms, with radio/VAP management and 802.11 packet and event handling; the README specifically highlights EasyConnect and Passpoint processing. The main flow is a caller using HAL operations, which dispatch to platform-specific implementations and interact with hostapd/nl80211, while receive paths process management, data, and feature-specific traffic. HAL IPC provides a separate server-side API bridge. Some subsystem links are documented only at a high level; unsampled implementation details are not assumed.

Main entry points: [`src/wifi_hal.c`](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal.c) (HAL Operations), [`src/wifi_hal_rdk_framework.h`](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_rdk_framework.h) (RDK Framework), [`src/ieee80211.h`](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/ieee80211.h) (802.11 Definitions), [`src/wifi_hal_mgmt_rx.c`](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_mgmt_rx.c) (Management RX)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["HAL API and IPC"]
  node_halapi["HAL Operations<br/>[wifi_hal.c]"]
  node_ipcserver["IPC Server<br/>[server_hal_ipc.c]"]
  node_ipccore["IPC Dispatch<br/>[hal_ipc.c]"]
  node_processors["IPC Processors"]
  node_wrappers["Wi-Fi Wrappers"]
end

subgraph group_radio["Radio Platforms"]
  node_platform["Platform Operations<br/>[platform.c]"]
  node_intel["Intel Backend<br/>[platform.c]"]
  node_qualcomm["Qualcomm Backend<br/>[platform_xer5.c]"]
end

subgraph group_runtime["Wi-Fi Runtime"]
  node_hostapd["Hostapd Integration<br/>[wifi_hal_hostapd.c]"]
  node_nlutils["nl80211 Utilities"]
  node_nlevents["nl80211 Events"]
end

subgraph group_packets["Packet Features"]
  node_mgmtrx["Management RX<br/>[wifi_hal_mgmt_rx.c]"]
  node_onemgmtrx["OneWiFi Management RX"]
  node_datarx["Data RX<br/>[wifi_hal_data_rx.c]"]
  node_dpp["EasyConnect DPP<br/>[wifi_hal_dpp.c]"]
  node_anqp["Passpoint ANQP<br/>[wifi_hal_anqp.c]"]
  node_wnm["WNM and RRM<br/>[wifi_hal_wnm_rrm.c]"]
end

subgraph group_support["Shared Support"]
  node_frame["802.11 Definitions<br/>[ieee80211.h]"]
  node_priv["HAL Runtime State<br/>[wifi_hal_priv.h]"]
  node_rdk["RDK Framework"]
  node_rdkapi["RDK HAL Types<br/>[wifi_hal_rdk.h]"]
  node_collections["Collections<br/>[collection.c]"]
  node_tlv["TLV Encoding<br/>[wifi_tlv.c]"]
  node_crypto["AES-SIV<br/>[aes_siv.c]"]
end

node_caller(("HAL Caller"))

node_caller -->|"calls"| node_halapi
node_halapi -.->|"dispatches"| node_platform
node_halapi -.->|"configures"| node_hostapd
node_ipcserver -->|"initializes"| node_ipccore
node_ipccore -->|"dispatches"| node_processors
node_processors -->|"calls"| node_halapi
node_wrappers -.->|"wraps"| node_halapi
node_halapi -.->|"dispatches"| node_intel
node_halapi -.->|"dispatches"| node_qualcomm
node_nlevents -.->|"uses"| node_nlutils
node_mgmtrx -->|"parses"| node_frame
node_onemgmtrx -->|"parses"| node_frame
node_datarx -->|"parses"| node_frame
node_mgmtrx -->|"uses"| node_rdk
node_onemgmtrx -->|"uses"| node_priv
node_datarx -->|"uses"| node_rdk
node_rdk -->|"includes"| node_rdkapi
node_priv -->|"uses"| node_collections
node_halapi -.->|"processes"| node_dpp
node_halapi -.->|"processes"| node_anqp
node_halapi -.->|"supports"| node_wnm
node_rdkapi -->|"provides types"| node_tlv
node_crypto -.->|"supports"| node_dpp

click node_halapi "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal.c"
click node_ipcserver "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/server_hal_ipc.c"
click node_ipccore "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/hal_ipc.c"
click node_processors "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/hal_ipc_processors.c"
click node_wrappers "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/hal_ipc_wifi_wrappers.c"
click node_platform "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/platform/broadcom/platform.c"
click node_intel "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/platform/intel/platform.c"
click node_qualcomm "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/platform/qualcomm/platform_xer5.c"
click node_hostapd "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_hostapd.c"
click node_nlutils "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_nl80211_utils.c"
click node_nlevents "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_nl80211_events.c"
click node_mgmtrx "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_mgmt_rx.c"
click node_onemgmtrx "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_mgmt_rx_one_wifi.c"
click node_datarx "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_data_rx.c"
click node_dpp "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_dpp.c"
click node_anqp "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_anqp.c"
click node_wnm "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_wnm_rrm.c"
click node_frame "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/ieee80211.h"
click node_priv "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_priv.h"
click node_rdk "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_rdk_framework.h"
click node_rdkapi "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_rdk.h"
click node_collections "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/collection.c"
click node_tlv "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_tlv.c"
click node_crypto "https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/util_crypto/aes_siv.c"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_halapi,node_ipcserver,node_ipccore,node_processors,node_wrappers toneBlue
class node_platform,node_intel,node_qualcomm toneAmber
class node_hostapd,node_nlutils,node_nlevents toneMint
class node_mgmtrx,node_onemgmtrx,node_datarx,node_dpp,node_anqp,node_wnm toneRose
class node_frame,node_priv,node_rdk,node_rdkapi,node_collections,node_tlv,node_crypto,node_caller toneIndigo
```

## Components

### HAL API and IPC

- [HAL Operations](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal.c): `src/wifi_hal.c`
- [IPC Server](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/server_hal_ipc.c): `hal_ipc/server/server_hal_ipc.c`
- [IPC Dispatch](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/hal_ipc.c): `hal_ipc/server/hal_ipc.c`
- [IPC Processors](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/hal_ipc_processors.c): `hal_ipc/server/hal_ipc_processors.c`
- [Wi-Fi Wrappers](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/hal_ipc/server/hal_ipc_wifi_wrappers.c): `hal_ipc/server/hal_ipc_wifi_wrappers.c`

### Radio Platforms

- [Platform Operations](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/platform/broadcom/platform.c): `platform/broadcom/platform.c`
- [Intel Backend](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/platform/intel/platform.c): `platform/intel/platform.c`
- [Qualcomm Backend](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/platform/qualcomm/platform_xer5.c): `platform/qualcomm/platform_xer5.c`

### Wi-Fi Runtime

- [Hostapd Integration](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_hostapd.c): `src/wifi_hal_hostapd.c`
- [nl80211 Utilities](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_nl80211_utils.c): `src/wifi_hal_nl80211_utils.c`
- [nl80211 Events](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_nl80211_events.c): `src/wifi_hal_nl80211_events.c`

### Packet Features

- [Management RX](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_mgmt_rx.c): `src/wifi_hal_mgmt_rx.c`
- [OneWiFi Management RX](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_mgmt_rx_one_wifi.c): `src/wifi_hal_mgmt_rx_one_wifi.c`
- [Data RX](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_data_rx.c): `src/wifi_hal_data_rx.c`
- [EasyConnect DPP](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_dpp.c): `src/wifi_hal_dpp.c`
- [Passpoint ANQP](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_anqp.c): `src/wifi_hal_anqp.c`
- [WNM and RRM](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_wnm_rrm.c): `src/wifi_hal_wnm_rrm.c`

### Shared Support

- [802.11 Definitions](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/ieee80211.h): `src/ieee80211.h`
- [HAL Runtime State](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_priv.h): `src/wifi_hal_priv.h`
- [RDK Framework](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_rdk_framework.h): `src/wifi_hal_rdk_framework.h`
- [RDK HAL Types](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_hal_rdk.h): `src/wifi_hal_rdk.h`
- [Collections](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/collection.c): `src/collection.c`
- [TLV Encoding](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/src/wifi_tlv.c): `src/wifi_tlv.c`
- [AES-SIV](https://github.com/harshavardhanp1/rdk-wifi-hal/blob/develop/util_crypto/aes_siv.c): `util_crypto/aes_siv.c`

### Other components

- **HAL Caller**

## Connections

- HAL Caller → HAL Operations: calls
- HAL Operations → Platform Operations: dispatches
- HAL Operations → Hostapd Integration: configures
- IPC Server → IPC Dispatch: initializes (evidence: `hal_ipc/server/server_hal_ipc.c`)
- IPC Dispatch → IPC Processors: dispatches (evidence: `hal_ipc/server/hal_ipc.c`)
- IPC Processors → HAL Operations: calls (evidence: `hal_ipc/server/hal_ipc_processors.c`)
- Wi-Fi Wrappers → HAL Operations: wraps
- HAL Operations → Intel Backend: dispatches
- HAL Operations → Qualcomm Backend: dispatches
- nl80211 Events → nl80211 Utilities: uses
- Management RX → 802.11 Definitions: parses (evidence: `src/wifi_hal_mgmt_rx.c`)
- OneWiFi Management RX → 802.11 Definitions: parses (evidence: `src/wifi_hal_mgmt_rx_one_wifi.c`)
- Data RX → 802.11 Definitions: parses (evidence: `src/wifi_hal_data_rx.c`)
- Management RX → RDK Framework: uses (evidence: `src/wifi_hal_mgmt_rx.c`)
- OneWiFi Management RX → HAL Runtime State: uses (evidence: `src/wifi_hal_mgmt_rx_one_wifi.c`)
- Data RX → RDK Framework: uses (evidence: `src/wifi_hal_data_rx.c`)
- RDK Framework → RDK HAL Types: includes (evidence: `src/wifi_hal_rdk_framework.h`)
- HAL Runtime State → Collections: uses (evidence: `src/wifi_hal_priv.h`)
- HAL Operations → EasyConnect DPP: processes
- HAL Operations → Passpoint ANQP: processes
- HAL Operations → WNM and RRM: supports
- RDK HAL Types → TLV Encoding: provides types (evidence: `src/wifi_tlv.c`)
- AES-SIV → EasyConnect DPP: supports
