Lines Matching refs:msg
160 static int __tipc_nl_add_net(struct net *net, struct tipc_nl_msg *msg)
168 hdr = genlmsg_put(msg->skb, msg->portid, msg->seq, &tipc_genl_family,
173 attrs = nla_nest_start_noflag(msg->skb, TIPC_NLA_NET);
177 if (nla_put_u32(msg->skb, TIPC_NLA_NET_ID, tn->net_id))
179 if (nla_put_u64_64bit(msg->skb, TIPC_NLA_NET_NODEID, *w0, 0))
181 if (nla_put_u64_64bit(msg->skb, TIPC_NLA_NET_NODEID_W1, *w1, 0))
183 nla_nest_end(msg->skb, attrs);
184 genlmsg_end(msg->skb, hdr);
189 nla_nest_cancel(msg->skb, attrs);
191 genlmsg_cancel(msg->skb, hdr);
201 struct tipc_nl_msg msg;
206 msg.skb = skb;
207 msg.portid = NETLINK_CB(cb->skb).portid;
208 msg.seq = cb->nlh->nlmsg_seq;
210 err = __tipc_nl_add_net(net, &msg);
287 static int __tipc_nl_addr_legacy_get(struct net *net, struct tipc_nl_msg *msg)
293 hdr = genlmsg_put(msg->skb, msg->portid, msg->seq, &tipc_genl_family,
298 attrs = nla_nest_start(msg->skb, TIPC_NLA_NET);
303 if (nla_put_flag(msg->skb, TIPC_NLA_NET_ADDR_LEGACY))
306 nla_nest_end(msg->skb, attrs);
307 genlmsg_end(msg->skb, hdr);
312 nla_nest_cancel(msg->skb, attrs);
314 genlmsg_cancel(msg->skb, hdr);
322 struct tipc_nl_msg msg;
330 msg.skb = rep;
331 msg.portid = info->snd_portid;
332 msg.seq = info->snd_seq;
334 err = __tipc_nl_addr_legacy_get(net, &msg);
336 nlmsg_free(msg.skb);
340 return genlmsg_reply(msg.skb, info);