at v5.6-rc1 28 lines 1.3 kB view raw
1/* SPDX-License-Identifier: GPL-2.0-only */ 2 3#ifndef _NET_ETHTOOL_BITSET_H 4#define _NET_ETHTOOL_BITSET_H 5 6typedef const char (*const ethnl_string_array_t)[ETH_GSTRING_LEN]; 7 8int ethnl_bitset_is_compact(const struct nlattr *bitset, bool *compact); 9int ethnl_bitset_size(const unsigned long *val, const unsigned long *mask, 10 unsigned int nbits, ethnl_string_array_t names, 11 bool compact); 12int ethnl_bitset32_size(const u32 *val, const u32 *mask, unsigned int nbits, 13 ethnl_string_array_t names, bool compact); 14int ethnl_put_bitset(struct sk_buff *skb, int attrtype, 15 const unsigned long *val, const unsigned long *mask, 16 unsigned int nbits, ethnl_string_array_t names, 17 bool compact); 18int ethnl_put_bitset32(struct sk_buff *skb, int attrtype, const u32 *val, 19 const u32 *mask, unsigned int nbits, 20 ethnl_string_array_t names, bool compact); 21int ethnl_update_bitset(unsigned long *bitmap, unsigned int nbits, 22 const struct nlattr *attr, ethnl_string_array_t names, 23 struct netlink_ext_ack *extack, bool *mod); 24int ethnl_update_bitset32(u32 *bitmap, unsigned int nbits, 25 const struct nlattr *attr, ethnl_string_array_t names, 26 struct netlink_ext_ack *extack, bool *mod); 27 28#endif /* _NET_ETHTOOL_BITSET_H */