Lines Matching refs:msg
742 static int __tipc_nl_add_bearer(struct tipc_nl_msg *msg, in __tipc_nl_add_bearer() argument
749 hdr = genlmsg_put(msg->skb, msg->portid, msg->seq, &tipc_genl_family, in __tipc_nl_add_bearer()
754 attrs = nla_nest_start_noflag(msg->skb, TIPC_NLA_BEARER); in __tipc_nl_add_bearer()
758 if (nla_put_string(msg->skb, TIPC_NLA_BEARER_NAME, bearer->name)) in __tipc_nl_add_bearer()
761 prop = nla_nest_start_noflag(msg->skb, TIPC_NLA_BEARER_PROP); in __tipc_nl_add_bearer()
764 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_PRIO, bearer->priority)) in __tipc_nl_add_bearer()
766 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_TOL, bearer->tolerance)) in __tipc_nl_add_bearer()
768 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_WIN, bearer->window)) in __tipc_nl_add_bearer()
771 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_MTU, bearer->mtu)) in __tipc_nl_add_bearer()
774 nla_nest_end(msg->skb, prop); in __tipc_nl_add_bearer()
778 if (tipc_udp_nl_add_bearer_data(msg, bearer)) in __tipc_nl_add_bearer()
783 nla_nest_end(msg->skb, attrs); in __tipc_nl_add_bearer()
784 genlmsg_end(msg->skb, hdr); in __tipc_nl_add_bearer()
789 nla_nest_cancel(msg->skb, prop); in __tipc_nl_add_bearer()
791 nla_nest_cancel(msg->skb, attrs); in __tipc_nl_add_bearer()
793 genlmsg_cancel(msg->skb, hdr); in __tipc_nl_add_bearer()
803 struct tipc_nl_msg msg; in tipc_nl_bearer_dump() local
810 msg.skb = skb; in tipc_nl_bearer_dump()
811 msg.portid = NETLINK_CB(cb->skb).portid; in tipc_nl_bearer_dump()
812 msg.seq = cb->nlh->nlmsg_seq; in tipc_nl_bearer_dump()
820 err = __tipc_nl_add_bearer(&msg, bearer, NLM_F_MULTI); in tipc_nl_bearer_dump()
836 struct tipc_nl_msg msg; in tipc_nl_bearer_get() local
857 msg.skb = rep; in tipc_nl_bearer_get()
858 msg.portid = info->snd_portid; in tipc_nl_bearer_get()
859 msg.seq = info->snd_seq; in tipc_nl_bearer_get()
868 err = __tipc_nl_add_bearer(&msg, bearer, 0); in tipc_nl_bearer_get()
1088 static int __tipc_nl_add_media(struct tipc_nl_msg *msg, in __tipc_nl_add_media() argument
1095 hdr = genlmsg_put(msg->skb, msg->portid, msg->seq, &tipc_genl_family, in __tipc_nl_add_media()
1100 attrs = nla_nest_start_noflag(msg->skb, TIPC_NLA_MEDIA); in __tipc_nl_add_media()
1104 if (nla_put_string(msg->skb, TIPC_NLA_MEDIA_NAME, media->name)) in __tipc_nl_add_media()
1107 prop = nla_nest_start_noflag(msg->skb, TIPC_NLA_MEDIA_PROP); in __tipc_nl_add_media()
1110 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_PRIO, media->priority)) in __tipc_nl_add_media()
1112 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_TOL, media->tolerance)) in __tipc_nl_add_media()
1114 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_WIN, media->window)) in __tipc_nl_add_media()
1117 if (nla_put_u32(msg->skb, TIPC_NLA_PROP_MTU, media->mtu)) in __tipc_nl_add_media()
1120 nla_nest_end(msg->skb, prop); in __tipc_nl_add_media()
1121 nla_nest_end(msg->skb, attrs); in __tipc_nl_add_media()
1122 genlmsg_end(msg->skb, hdr); in __tipc_nl_add_media()
1127 nla_nest_cancel(msg->skb, prop); in __tipc_nl_add_media()
1129 nla_nest_cancel(msg->skb, attrs); in __tipc_nl_add_media()
1131 genlmsg_cancel(msg->skb, hdr); in __tipc_nl_add_media()
1140 struct tipc_nl_msg msg; in tipc_nl_media_dump() local
1145 msg.skb = skb; in tipc_nl_media_dump()
1146 msg.portid = NETLINK_CB(cb->skb).portid; in tipc_nl_media_dump()
1147 msg.seq = cb->nlh->nlmsg_seq; in tipc_nl_media_dump()
1151 err = __tipc_nl_add_media(&msg, media_info_array[i], in tipc_nl_media_dump()
1166 struct tipc_nl_msg msg; in tipc_nl_media_get() local
1188 msg.skb = rep; in tipc_nl_media_get()
1189 msg.portid = info->snd_portid; in tipc_nl_media_get()
1190 msg.seq = info->snd_seq; in tipc_nl_media_get()
1199 err = __tipc_nl_add_media(&msg, media, 0); in tipc_nl_media_get()