Zephyr Project API 4.4.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches

DHCPv6 server. More...

Data Structures

struct  net_dhcpv6_server_params
 DHCPv6 server configuration parameters. More...

Typedefs

typedef void(* net_dhcpv6_server_lease_cb_t) (struct net_if *iface, struct net_dhcpv6_server_lease *lease, void *user_data)
 Callback used while iterating over DHCPv6 server leases.

Functions

int net_dhcpv6_server_start (struct net_if *iface, struct net_dhcpv6_server_params *params)
 Start the DHCPv6 server on the given interface.
int net_dhcpv6_server_stop (struct net_if *iface)
 Stop the DHCPv6 server on the given interface.
int net_dhcpv6_server_foreach_lease (struct net_if *iface, net_dhcpv6_server_lease_cb_t cb, void *user_data)
 Iterate over all DHCPv6 server leases and call cb for each.

Detailed Description

DHCPv6 server.

Since
4.5
Version
0.1.0

Typedef Documentation

◆ net_dhcpv6_server_lease_cb_t

typedef void(* net_dhcpv6_server_lease_cb_t) (struct net_if *iface, struct net_dhcpv6_server_lease *lease, void *user_data)

#include <dhcpv6_server.h>

Callback used while iterating over DHCPv6 server leases.

Parameters
ifacePointer to the network interface the lease belongs to
leasePointer to the DHCPv6 server lease
user_dataA valid pointer to user data or NULL

Function Documentation

◆ net_dhcpv6_server_foreach_lease()

int net_dhcpv6_server_foreach_lease ( struct net_if * iface,
net_dhcpv6_server_lease_cb_t cb,
void * user_data )

#include <dhcpv6_server.h>

Iterate over all DHCPv6 server leases and call cb for each.

If iface is NULL, iterate over the lease of any running server instance, otherwise only over the server running on iface.

Parameters
ifacePointer to the network interface, can be NULL
cbUser-supplied callback function to call
user_dataUser specified data
Returns
0 on success, -ENOENT if no server is running on iface, negative errno otherwise.

◆ net_dhcpv6_server_start()

int net_dhcpv6_server_start ( struct net_if * iface,
struct net_dhcpv6_server_params * params )

#include <dhcpv6_server.h>

Start the DHCPv6 server on the given interface.

Parameters
ifaceA valid pointer to a network interface
paramsServer configuration parameters (copied)
Returns
0 on success, negative errno otherwise.

◆ net_dhcpv6_server_stop()

int net_dhcpv6_server_stop ( struct net_if * iface)

#include <dhcpv6_server.h>

Stop the DHCPv6 server on the given interface.

Parameters
ifaceA valid pointer to a network interface
Returns
0 on success, negative errno otherwise.