Lines Matching refs:nlmsg
231 struct nl_msg *nlmsg = nlmsg_alloc(); in get_multicast_id() local
233 if (!nlmsg) { in get_multicast_id()
237 genlmsg_put(nlmsg, 0, 0, ctx->nlctrl_familyid, 0, 0, in get_multicast_id()
239 nla_put_string(nlmsg, CTRL_ATTR_FAMILY_NAME, "cld80211"); in get_multicast_id()
242 cld80211_send_recv_msg(ctx, nlmsg, family_handler, &res); in get_multicast_id()
246 nlmsg_free(nlmsg); in get_multicast_id()
301 struct nl_msg *nlmsg; in cld80211_msg_alloc() local
308 nlmsg = nlmsg_alloc(); in cld80211_msg_alloc()
309 if (nlmsg == NULL) { in cld80211_msg_alloc()
314 genlmsg_put(nlmsg, pid, /* seq = */ 0, ctx->netlink_familyid, in cld80211_msg_alloc()
317 *nla_data = nla_nest_start(nlmsg, CLD80211_ATTR_VENDOR_DATA); in cld80211_msg_alloc()
321 return nlmsg; in cld80211_msg_alloc()
324 if (nlmsg) in cld80211_msg_alloc()
325 nlmsg_free(nlmsg); in cld80211_msg_alloc()
330 int cld80211_send_msg(struct cld80211_ctx *ctx, struct nl_msg *nlmsg) in cld80211_send_msg() argument
334 if (!ctx || !ctx->sock || !nlmsg) { in cld80211_send_msg()
339 err = nl_send_auto_complete(ctx->sock, nlmsg); /* send message */ in cld80211_send_msg()
349 int cld80211_send_recv_msg(struct cld80211_ctx *ctx, struct nl_msg *nlmsg, in cld80211_send_recv_msg() argument
355 if (!ctx || !ctx->sock || !nlmsg) { in cld80211_send_recv_msg()
364 err = nl_send_auto_complete(ctx->sock, nlmsg); /* send message */ in cld80211_send_recv_msg()