netfilter
firewalling, NAT, and packet mangling for linux
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
rtnl_link_info_ops Struct Reference

Link info operations. More...

#include <info-api.h>

Collaboration diagram for rtnl_link_info_ops:

Data Fields

char * io_name
 Name of operations, must match name on kernel side. More...
 
int io_refcnt
 Reference count (internal, do not use) More...
 
int(* io_alloc )(struct rtnl_link *)
 Called to assign an info type to a link. More...
 
int(* io_parse )(struct rtnl_link *, struct nlattr *, struct nlattr *)
 Called to parse the link info attribute. More...
 
void(* io_dump [NL_DUMP_MAX+1])(struct rtnl_link *, struct nl_dump_params *)
 Called when the link object is dumped. More...
 
int(* io_clone )(struct rtnl_link *, struct rtnl_link *)
 Called when a link object is cloned. More...
 
int(* io_put_attrs )(struct nl_msg *, struct rtnl_link *)
 Called when construction a link netlink message. More...
 
void(* io_free )(struct rtnl_link *)
 Called to release all resources previously allocated in either io_alloc() or io_parse(). More...
 
struct rtnl_link_info_opsio_next
 

Detailed Description

Link info operations.

Field Documentation

int(* rtnl_link_info_ops::io_alloc)(struct rtnl_link *)

Called to assign an info type to a link.

Has to allocate enough resources to hold attributes. Can use link->l_info to store a pointer.

Referenced by rtnl_link_set_info_type().

int(* rtnl_link_info_ops::io_clone)(struct rtnl_link *, struct rtnl_link *)

Called when a link object is cloned.

Must clone all info type specific attributes.

void(* rtnl_link_info_ops::io_dump[NL_DUMP_MAX+1])(struct rtnl_link *, struct nl_dump_params *)

Called when the link object is dumped.

Must dump the info type specific attributes.

void(* rtnl_link_info_ops::io_free)(struct rtnl_link *)

Called to release all resources previously allocated in either io_alloc() or io_parse().

char* rtnl_link_info_ops::io_name
int(* rtnl_link_info_ops::io_parse)(struct rtnl_link *, struct nlattr *, struct nlattr *)

Called to parse the link info attribute.

Must parse the attribute and assign all values to the link.

int(* rtnl_link_info_ops::io_put_attrs)(struct nl_msg *, struct rtnl_link *)

Called when construction a link netlink message.

Must append all info type specific attributes to the message.

Referenced by rtnl_link_build_change_request().

int rtnl_link_info_ops::io_refcnt

Reference count (internal, do not use)

Referenced by rtnl_link_unregister_info().


The documentation for this struct was generated from the following file: