class SimDataPath
Defined at line 37 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.h
Implements the tx/rx data path for the sim driver using the network device protocol,
and manages the shared memory regions that are used by the protocol.
Note that currently this class does not allow users to transmit or receive in batches.
Frames must be transmitted one at a time.
Public Members
static const uint64_t kMaxFrameSize
Public Methods
void SimDataPath (SimDevice & sim_device)
Defined at line 42 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.h
void ~SimDataPath ()
Defined at line 55 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
const std::vector<fuchsia_hardware_network_driver::wire::TxResult> & TxResults ()
Returns all the tx results received since this class was constructed.
Note that there is currently no way to clear the tx results during the lifetime of this class.
Defined at line 60 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.h
const std::vector<std::vector<uint8_t>> & RxData ()
Returns all the received frames since this class was constructed as vectors of bytes.
There is currently no way to clear the rx results during the lifetime of this class.
Defined at line 66 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.h
void Init (fidl::UnownedClientEnd<fuchsia_io::Directory> outgoing_dir_client, fit::callback<void (zx_status_t)> && on_complete)
Initializes and starts the network device.
Defined at line 70 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
void TxEthernet (uint16_t id, common::MacAddr dst, common::MacAddr src, uint16_t type, cpp20::span<const uint8_t> body)
Transmit a single ethernet frame. This will internally construct the ethernet header.
The `id` is used to identify the transmitted frame. Tests can keep track of the ids that are
sent and use it to verify that the expected frames were transmitted.
Defined at line 199 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
void TxRaw (uint16_t id, const std::vector<uint8_t> & body)
Transmit raw bytes contained in a body.
Defined at line 213 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
void OnTxComplete (cpp20::span<fuchsia_hardware_network_driver::wire::TxResult> tx)
NetworkDeviceIfc callbacks
Defined at line 223 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
void OnRxComplete (cpp20::span<fuchsia_hardware_network_driver::wire::RxBuffer> rx)
Defined at line 235 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
void OnAddPort (uint8_t id, fdf::ClientEnd<fuchsia_hardware_network_driver::NetworkPort> && port)
Defined at line 253 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc
void OnRemovePort (uint8_t id)
Defined at line 260 of file ../../src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/sim_data_path.cc