17c2aad20Sopenharmony_ci/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
27c2aad20Sopenharmony_ci/* Do not edit directly, auto-generated from: */
37c2aad20Sopenharmony_ci/*	Documentation/netlink/specs/netdev.yaml */
47c2aad20Sopenharmony_ci/* YNL-GEN uapi header */
57c2aad20Sopenharmony_ci
67c2aad20Sopenharmony_ci#ifndef _UAPI_LINUX_NETDEV_H
77c2aad20Sopenharmony_ci#define _UAPI_LINUX_NETDEV_H
87c2aad20Sopenharmony_ci
97c2aad20Sopenharmony_ci#define NETDEV_FAMILY_NAME	"netdev"
107c2aad20Sopenharmony_ci#define NETDEV_FAMILY_VERSION	1
117c2aad20Sopenharmony_ci
127c2aad20Sopenharmony_ci/**
137c2aad20Sopenharmony_ci * enum netdev_xdp_act
147c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_BASIC: XDP features set supported by all drivers
157c2aad20Sopenharmony_ci *   (XDP_ABORTED, XDP_DROP, XDP_PASS, XDP_TX)
167c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_REDIRECT: The netdev supports XDP_REDIRECT
177c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_NDO_XMIT: This feature informs if netdev implements
187c2aad20Sopenharmony_ci *   ndo_xdp_xmit callback.
197c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_XSK_ZEROCOPY: This feature informs if netdev supports AF_XDP
207c2aad20Sopenharmony_ci *   in zero copy mode.
217c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_HW_OFFLOAD: This feature informs if netdev supports XDP hw
227c2aad20Sopenharmony_ci *   offloading.
237c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_RX_SG: This feature informs if netdev implements non-linear
247c2aad20Sopenharmony_ci *   XDP buffer support in the driver napi callback.
257c2aad20Sopenharmony_ci * @NETDEV_XDP_ACT_NDO_XMIT_SG: This feature informs if netdev implements
267c2aad20Sopenharmony_ci *   non-linear XDP buffer support in ndo_xdp_xmit callback.
277c2aad20Sopenharmony_ci */
287c2aad20Sopenharmony_cienum netdev_xdp_act {
297c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_BASIC = 1,
307c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_REDIRECT = 2,
317c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_NDO_XMIT = 4,
327c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_XSK_ZEROCOPY = 8,
337c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_HW_OFFLOAD = 16,
347c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_RX_SG = 32,
357c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_NDO_XMIT_SG = 64,
367c2aad20Sopenharmony_ci
377c2aad20Sopenharmony_ci	/* private: */
387c2aad20Sopenharmony_ci	NETDEV_XDP_ACT_MASK = 127,
397c2aad20Sopenharmony_ci};
407c2aad20Sopenharmony_ci
417c2aad20Sopenharmony_ci/**
427c2aad20Sopenharmony_ci * enum netdev_xdp_rx_metadata
437c2aad20Sopenharmony_ci * @NETDEV_XDP_RX_METADATA_TIMESTAMP: Device is capable of exposing receive HW
447c2aad20Sopenharmony_ci *   timestamp via bpf_xdp_metadata_rx_timestamp().
457c2aad20Sopenharmony_ci * @NETDEV_XDP_RX_METADATA_HASH: Device is capable of exposing receive packet
467c2aad20Sopenharmony_ci *   hash via bpf_xdp_metadata_rx_hash().
477c2aad20Sopenharmony_ci */
487c2aad20Sopenharmony_cienum netdev_xdp_rx_metadata {
497c2aad20Sopenharmony_ci	NETDEV_XDP_RX_METADATA_TIMESTAMP = 1,
507c2aad20Sopenharmony_ci	NETDEV_XDP_RX_METADATA_HASH = 2,
517c2aad20Sopenharmony_ci
527c2aad20Sopenharmony_ci	/* private: */
537c2aad20Sopenharmony_ci	NETDEV_XDP_RX_METADATA_MASK = 3,
547c2aad20Sopenharmony_ci};
557c2aad20Sopenharmony_ci
567c2aad20Sopenharmony_cienum {
577c2aad20Sopenharmony_ci	NETDEV_A_DEV_IFINDEX = 1,
587c2aad20Sopenharmony_ci	NETDEV_A_DEV_PAD,
597c2aad20Sopenharmony_ci	NETDEV_A_DEV_XDP_FEATURES,
607c2aad20Sopenharmony_ci	NETDEV_A_DEV_XDP_ZC_MAX_SEGS,
617c2aad20Sopenharmony_ci	NETDEV_A_DEV_XDP_RX_METADATA_FEATURES,
627c2aad20Sopenharmony_ci
637c2aad20Sopenharmony_ci	__NETDEV_A_DEV_MAX,
647c2aad20Sopenharmony_ci	NETDEV_A_DEV_MAX = (__NETDEV_A_DEV_MAX - 1)
657c2aad20Sopenharmony_ci};
667c2aad20Sopenharmony_ci
677c2aad20Sopenharmony_cienum {
687c2aad20Sopenharmony_ci	NETDEV_CMD_DEV_GET = 1,
697c2aad20Sopenharmony_ci	NETDEV_CMD_DEV_ADD_NTF,
707c2aad20Sopenharmony_ci	NETDEV_CMD_DEV_DEL_NTF,
717c2aad20Sopenharmony_ci	NETDEV_CMD_DEV_CHANGE_NTF,
727c2aad20Sopenharmony_ci
737c2aad20Sopenharmony_ci	__NETDEV_CMD_MAX,
747c2aad20Sopenharmony_ci	NETDEV_CMD_MAX = (__NETDEV_CMD_MAX - 1)
757c2aad20Sopenharmony_ci};
767c2aad20Sopenharmony_ci
777c2aad20Sopenharmony_ci#define NETDEV_MCGRP_MGMT	"mgmt"
787c2aad20Sopenharmony_ci
797c2aad20Sopenharmony_ci#endif /* _UAPI_LINUX_NETDEV_H */
80