openbmc/build/tmp/deploy/sdk/witherspoon-2019-08-08/sysroots/armv6-openbmc-linux-gnueabi/usr/src/debug/libnl/1_3.4.0-r0/libnl-3.4.0/lib/route/link/sit.c
int rtnl_link_sit_add(struct nl_sock* sk, const char* name)
{
    struct rtnl_link* link;
    int err;

    link = rtnl_link_sit_alloc();
    if (!link)
        return -NLE_NOMEM;

    if (name)
        rtnl_link_set_name(link, name);

    err = rtnl_link_add(sk, link, NLM_F_CREATE);
    rtnl_link_put(link);

    return err;
}
/**
 * Create a new sit tunnel device
 * @arg sock            netlink socket
 * @arg name            name of the tunnel device
 *
 * Creates a new sit tunnel device in the kernel
 * @return 0 on success or a negative error code
 */
Create a new sit tunnel device
@arg sock            netlink socket
@arg name            name of the tunnel device

Creates a new sit tunnel device in the kernel
@return 0 on success or a negative error code
Create a new sit tunnel device @arg sock netlink socket @arg name name of the tunnel device Creates a new sit tunnel device in the kernel @return 0 on success or a negative error code
int rtnl_link_sit_add(struct nl_sock* sk, const char* name)
{
    struct rtnl_link* link;
    int err;
    link = rtnl_link_sit_alloc();
    if (!link)
        return -NLE_NOMEM;
    if (name)
        rtnl_link_set_name(link, name);
    err = rtnl_link_add(sk, link, NLM_F_CREATE);
    rtnl_link_put(link);
    return err;
}
int rtnl_link_sit_add ( struct nl_sock * sk , const char * name ) { struct rtnl_link * link ; int err ; link = rtnl_link_sit_alloc ( ) ; if ( ! link ) return - NLE_NOMEM ; if ( name ) rtnl_link_set_name ( link , name ) ; err = rtnl_link_add ( sk , link , NLM_F_CREATE ) ; rtnl_link_put ( link ) ; return err ; }
Create a new sit tunnel device
 @arg sock            netlink socket
 @arg name            name of the tunnel device
Create a new sit tunnel device @arg sock netlink socket @arg name name of the tunnel device