Mistake on this page?
Report an issue in GitHub or email us
Data Fields
whd_netif_funcs Struct Reference

Contains functions which allows WHD to pass received data to the network stack, to send an ethernet frame to WHD, etc. More...

#include <whd_network_types.h>

Data Fields

void(* whd_network_process_ethernet_data )(whd_interface_t ifp, whd_buffer_t buffer)
 Called by WHD to pass received data to the network stack. More...
 

Detailed Description

Contains functions which allows WHD to pass received data to the network stack, to send an ethernet frame to WHD, etc.

Definition at line 173 of file whd_network_types.h.

Field Documentation

void(* whd_network_process_ethernet_data) (whd_interface_t ifp, whd_buffer_t buffer)

Called by WHD to pass received data to the network stack.

Packets received from the Wi-Fi network by WHD are forwarded to by calling function ptr which must be implemented in the network interface. Ethernet headers are present at the start of these packet buffers.

This function is called asynchronously in the context of the WHD thread whenever new data has arrived. Packet buffers are allocated within WHD, and ownership is transferred to the network stack. The network stack or application is thus responsible for releasing the packet buffers. Most packet buffering systems have a pointer to the 'current point' within the packet buffer. When this function is called, the pointer points to the start of the Ethernet header. There is other inconsequential data before the Ethernet header.

It is preferable that the (whd_network_process_ethernet_data)() function simply puts the received packet on a queue for processing by another thread. This avoids the WHD thread being unnecessarily tied up which would delay other packets being transmitted or received.

Parameters
interfaceThe interface on which the packet was received.
bufferHandle of the packet which has just been received. Responsibility for releasing this buffer is transferred from WHD at this point.

Definition at line 202 of file whd_network_types.h.

Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.