Lines Matching refs:attrs
643 struct nlattr *attrs; in __tipc_nl_add_bearer() local
651 attrs = nla_nest_start(msg->skb, TIPC_NLA_BEARER); in __tipc_nl_add_bearer()
652 if (!attrs) in __tipc_nl_add_bearer()
669 nla_nest_end(msg->skb, attrs); in __tipc_nl_add_bearer()
677 nla_nest_cancel(msg->skb, attrs); in __tipc_nl_add_bearer()
723 struct nlattr *attrs[TIPC_NLA_BEARER_MAX + 1]; in tipc_nl_bearer_get() local
726 if (!info->attrs[TIPC_NLA_BEARER]) in tipc_nl_bearer_get()
729 err = nla_parse_nested(attrs, TIPC_NLA_BEARER_MAX, in tipc_nl_bearer_get()
730 info->attrs[TIPC_NLA_BEARER], in tipc_nl_bearer_get()
735 if (!attrs[TIPC_NLA_BEARER_NAME]) in tipc_nl_bearer_get()
737 name = nla_data(attrs[TIPC_NLA_BEARER_NAME]); in tipc_nl_bearer_get()
772 struct nlattr *attrs[TIPC_NLA_BEARER_MAX + 1]; in tipc_nl_bearer_disable() local
775 if (!info->attrs[TIPC_NLA_BEARER]) in tipc_nl_bearer_disable()
778 err = nla_parse_nested(attrs, TIPC_NLA_BEARER_MAX, in tipc_nl_bearer_disable()
779 info->attrs[TIPC_NLA_BEARER], in tipc_nl_bearer_disable()
784 if (!attrs[TIPC_NLA_BEARER_NAME]) in tipc_nl_bearer_disable()
787 name = nla_data(attrs[TIPC_NLA_BEARER_NAME]); in tipc_nl_bearer_disable()
806 struct nlattr *attrs[TIPC_NLA_BEARER_MAX + 1]; in tipc_nl_bearer_enable() local
815 if (!info->attrs[TIPC_NLA_BEARER]) in tipc_nl_bearer_enable()
818 err = nla_parse_nested(attrs, TIPC_NLA_BEARER_MAX, in tipc_nl_bearer_enable()
819 info->attrs[TIPC_NLA_BEARER], in tipc_nl_bearer_enable()
824 if (!attrs[TIPC_NLA_BEARER_NAME]) in tipc_nl_bearer_enable()
827 bearer = nla_data(attrs[TIPC_NLA_BEARER_NAME]); in tipc_nl_bearer_enable()
829 if (attrs[TIPC_NLA_BEARER_DOMAIN]) in tipc_nl_bearer_enable()
830 domain = nla_get_u32(attrs[TIPC_NLA_BEARER_DOMAIN]); in tipc_nl_bearer_enable()
832 if (attrs[TIPC_NLA_BEARER_PROP]) { in tipc_nl_bearer_enable()
835 err = tipc_nl_parse_link_prop(attrs[TIPC_NLA_BEARER_PROP], in tipc_nl_bearer_enable()
845 err = tipc_enable_bearer(net, bearer, domain, prio, attrs); in tipc_nl_bearer_enable()
860 struct nlattr *attrs[TIPC_NLA_BEARER_MAX + 1]; in tipc_nl_bearer_set() local
863 if (!info->attrs[TIPC_NLA_BEARER]) in tipc_nl_bearer_set()
866 err = nla_parse_nested(attrs, TIPC_NLA_BEARER_MAX, in tipc_nl_bearer_set()
867 info->attrs[TIPC_NLA_BEARER], in tipc_nl_bearer_set()
872 if (!attrs[TIPC_NLA_BEARER_NAME]) in tipc_nl_bearer_set()
874 name = nla_data(attrs[TIPC_NLA_BEARER_NAME]); in tipc_nl_bearer_set()
883 if (attrs[TIPC_NLA_BEARER_PROP]) { in tipc_nl_bearer_set()
886 err = tipc_nl_parse_link_prop(attrs[TIPC_NLA_BEARER_PROP], in tipc_nl_bearer_set()
909 struct nlattr *attrs; in __tipc_nl_add_media() local
917 attrs = nla_nest_start(msg->skb, TIPC_NLA_MEDIA); in __tipc_nl_add_media()
918 if (!attrs) in __tipc_nl_add_media()
935 nla_nest_end(msg->skb, attrs); in __tipc_nl_add_media()
943 nla_nest_cancel(msg->skb, attrs); in __tipc_nl_add_media()
983 struct nlattr *attrs[TIPC_NLA_BEARER_MAX + 1]; in tipc_nl_media_get() local
985 if (!info->attrs[TIPC_NLA_MEDIA]) in tipc_nl_media_get()
988 err = nla_parse_nested(attrs, TIPC_NLA_MEDIA_MAX, in tipc_nl_media_get()
989 info->attrs[TIPC_NLA_MEDIA], in tipc_nl_media_get()
994 if (!attrs[TIPC_NLA_MEDIA_NAME]) in tipc_nl_media_get()
996 name = nla_data(attrs[TIPC_NLA_MEDIA_NAME]); in tipc_nl_media_get()
1031 struct nlattr *attrs[TIPC_NLA_BEARER_MAX + 1]; in tipc_nl_media_set() local
1033 if (!info->attrs[TIPC_NLA_MEDIA]) in tipc_nl_media_set()
1036 err = nla_parse_nested(attrs, TIPC_NLA_MEDIA_MAX, in tipc_nl_media_set()
1037 info->attrs[TIPC_NLA_MEDIA], in tipc_nl_media_set()
1040 if (!attrs[TIPC_NLA_MEDIA_NAME]) in tipc_nl_media_set()
1042 name = nla_data(attrs[TIPC_NLA_MEDIA_NAME]); in tipc_nl_media_set()
1051 if (attrs[TIPC_NLA_MEDIA_PROP]) { in tipc_nl_media_set()
1054 err = tipc_nl_parse_link_prop(attrs[TIPC_NLA_MEDIA_PROP], in tipc_nl_media_set()