1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linu 1 2 /* 3 * vdpa device management interface 4 * Copyright (c) 2020 Mellanox Technologies Lt 5 */ 6 7 #ifndef _UAPI_LINUX_VDPA_H_ 8 #define _UAPI_LINUX_VDPA_H_ 9 10 #define VDPA_GENL_NAME "vdpa" 11 #define VDPA_GENL_VERSION 0x1 12 13 enum vdpa_command { 14 VDPA_CMD_UNSPEC, 15 VDPA_CMD_MGMTDEV_NEW, 16 VDPA_CMD_MGMTDEV_GET, /* can 17 VDPA_CMD_DEV_NEW, 18 VDPA_CMD_DEV_DEL, 19 VDPA_CMD_DEV_GET, /* can 20 VDPA_CMD_DEV_CONFIG_GET, /* can 21 VDPA_CMD_DEV_VSTATS_GET, 22 VDPA_CMD_DEV_ATTR_SET, 23 }; 24 25 enum vdpa_attr { 26 VDPA_ATTR_UNSPEC, 27 28 /* Pad attribute for 64b alignment */ 29 VDPA_ATTR_PAD = VDPA_ATTR_UNSPEC, 30 31 /* bus name (optional) + dev name toge 32 VDPA_ATTR_MGMTDEV_BUS_NAME, 33 VDPA_ATTR_MGMTDEV_DEV_NAME, 34 VDPA_ATTR_MGMTDEV_SUPPORTED_CLASSES, 35 36 VDPA_ATTR_DEV_NAME, 37 VDPA_ATTR_DEV_ID, 38 VDPA_ATTR_DEV_VENDOR_ID, 39 VDPA_ATTR_DEV_MAX_VQS, 40 VDPA_ATTR_DEV_MAX_VQ_SIZE, 41 VDPA_ATTR_DEV_MIN_VQ_SIZE, 42 43 VDPA_ATTR_DEV_NET_CFG_MACADDR, 44 VDPA_ATTR_DEV_NET_STATUS, 45 VDPA_ATTR_DEV_NET_CFG_MAX_VQP, 46 VDPA_ATTR_DEV_NET_CFG_MTU, 47 48 VDPA_ATTR_DEV_NEGOTIATED_FEATURES, 49 VDPA_ATTR_DEV_MGMTDEV_MAX_VQS, 50 /* virtio features that are supported 51 VDPA_ATTR_DEV_SUPPORTED_FEATURES, 52 53 VDPA_ATTR_DEV_QUEUE_INDEX, 54 VDPA_ATTR_DEV_VENDOR_ATTR_NAME, 55 VDPA_ATTR_DEV_VENDOR_ATTR_VALUE, 56 57 /* virtio features that are provisione 58 VDPA_ATTR_DEV_FEATURES, 59 60 VDPA_ATTR_DEV_BLK_CFG_CAPACITY, 61 VDPA_ATTR_DEV_BLK_CFG_SIZE_MAX, 62 VDPA_ATTR_DEV_BLK_CFG_BLK_SIZE, 63 VDPA_ATTR_DEV_BLK_CFG_SEG_MAX, 64 VDPA_ATTR_DEV_BLK_CFG_NUM_QUEUES, 65 VDPA_ATTR_DEV_BLK_CFG_PHY_BLK_EXP, 66 VDPA_ATTR_DEV_BLK_CFG_ALIGN_OFFSET, 67 VDPA_ATTR_DEV_BLK_CFG_MIN_IO_SIZE, 68 VDPA_ATTR_DEV_BLK_CFG_OPT_IO_SIZE, 69 VDPA_ATTR_DEV_BLK_CFG_MAX_DISCARD_SEC, 70 VDPA_ATTR_DEV_BLK_CFG_MAX_DISCARD_SEG, 71 VDPA_ATTR_DEV_BLK_CFG_DISCARD_SEC_ALIG 72 VDPA_ATTR_DEV_BLK_CFG_MAX_WRITE_ZEROES 73 VDPA_ATTR_DEV_BLK_CFG_MAX_WRITE_ZEROES 74 VDPA_ATTR_DEV_BLK_READ_ONLY, 75 VDPA_ATTR_DEV_BLK_FLUSH, 76 77 /* new attributes must be added above 78 VDPA_ATTR_MAX, 79 }; 80 81 #endif 82
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.