Home | History | Annotate | Download | only in rdma
      1 /****************************************************************************
      2  ****************************************************************************
      3  ***
      4  ***   This header was automatically generated from a Linux kernel header
      5  ***   of the same name, to make information necessary for userspace to
      6  ***   call into the kernel available to libc.  It contains only constants,
      7  ***   structures, and macros generated from the original header, and thus,
      8  ***   contains no copyrightable information.
      9  ***
     10  ***   To edit the content of this header, modify the corresponding
     11  ***   source file (e.g. under external/kernel-headers/original/) then
     12  ***   run bionic/libc/kernel/tools/update_all.py
     13  ***
     14  ***   Any manual change here will be lost the next time this script will
     15  ***   be run. You've been warned!
     16  ***
     17  ****************************************************************************
     18  ****************************************************************************/
     19 #ifndef RDMA_USER_IOCTL_CMDS_H
     20 #define RDMA_USER_IOCTL_CMDS_H
     21 #include <linux/types.h>
     22 #include <linux/ioctl.h>
     23 #define RDMA_IOCTL_MAGIC 0x1b
     24 #define RDMA_VERBS_IOCTL _IOWR(RDMA_IOCTL_MAGIC, 1, struct ib_uverbs_ioctl_hdr)
     25 enum {
     26   UVERBS_ATTR_F_MANDATORY = 1U << 0,
     27   UVERBS_ATTR_F_VALID_OUTPUT = 1U << 1,
     28 };
     29 struct ib_uverbs_attr {
     30   __u16 attr_id;
     31   __u16 len;
     32   __u16 flags;
     33   union {
     34     struct {
     35       __u8 elem_id;
     36       __u8 reserved;
     37     } enum_data;
     38     __u16 reserved;
     39   } attr_data;
     40   union {
     41     __aligned_u64 data;
     42     __s64 data_s64;
     43   };
     44 };
     45 struct ib_uverbs_ioctl_hdr {
     46   __u16 length;
     47   __u16 object_id;
     48   __u16 method_id;
     49   __u16 num_attrs;
     50   __aligned_u64 reserved1;
     51   __u32 driver_id;
     52   __u32 reserved2;
     53   struct ib_uverbs_attr attrs[0];
     54 };
     55 enum rdma_driver_id {
     56   RDMA_DRIVER_UNKNOWN,
     57   RDMA_DRIVER_MLX5,
     58   RDMA_DRIVER_MLX4,
     59   RDMA_DRIVER_CXGB3,
     60   RDMA_DRIVER_CXGB4,
     61   RDMA_DRIVER_MTHCA,
     62   RDMA_DRIVER_BNXT_RE,
     63   RDMA_DRIVER_OCRDMA,
     64   RDMA_DRIVER_NES,
     65   RDMA_DRIVER_I40IW,
     66   RDMA_DRIVER_VMW_PVRDMA,
     67   RDMA_DRIVER_QEDR,
     68   RDMA_DRIVER_HNS,
     69   RDMA_DRIVER_USNIC,
     70   RDMA_DRIVER_RXE,
     71   RDMA_DRIVER_HFI1,
     72   RDMA_DRIVER_QIB,
     73 };
     74 #endif
     75