On 9/8/23 3:58 PM, Stanislav Fomichev wrote:
@@ -12,15 +13,24 @@ static int netdev_nl_dev_fill(struct net_device *netdev, struct sk_buff *rsp, const struct genl_info *info) { + u64 xdp_rx_meta = 0; void *hdr;hdr = genlmsg_iput(rsp, info);if (!hdr) return -EMSGSIZE;+#define XDP_METADATA_KFUNC(_, flag, __, xmo) \+ if (netdev->xdp_metadata_ops->xmo) \
A NULL check is needed for netdev->xdp_metadata_ops.
+ xdp_rx_meta |= flag; +XDP_METADATA_KFUNC_xxx +#undef XDP_METADATA_KFUNC +