Lines Matching refs:nl_sk
111 int netlink_set_kernel_only(struct nl_sock *nl_sk) { in netlink_set_kernel_only() argument
114 if (!nl_sk) { in netlink_set_kernel_only()
118 int sockfd = nl_socket_get_fd(nl_sk); in netlink_set_kernel_only()
128 struct nl_sock *nl_sk; in send_netlink_msg() local
130 nl_sk = nl_socket_alloc(); in send_netlink_msg()
131 if(!nl_sk) in send_netlink_msg()
134 if(nl_connect(nl_sk, NETLINK_ROUTE) != 0) in send_netlink_msg()
137 if(nl_send_auto_complete(nl_sk, msg) < 0) in send_netlink_msg()
140 if(netlink_set_kernel_only(nl_sk) < 0) in send_netlink_msg()
143 nl_recvmsgs(nl_sk, callbacks); in send_netlink_msg()
146 if(nl_sk) in send_netlink_msg()
147 nl_socket_free(nl_sk); in send_netlink_msg()