blob: afe0f80a6dc5761f46af70618bc92d99dfe28569 [file] [log] [blame]
Elliott Hughes180edef2023-11-02 00:08:05 +00001/*
2 * This file is auto-generated. Modifications will be lost.
3 *
4 * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/
5 * for more information.
6 */
Christopher Ferris48af7cb2017-02-21 12:35:09 -08007#ifndef HNS_ABI_USER_H
8#define HNS_ABI_USER_H
9#include <linux/types.h>
10struct hns_roce_ib_create_cq {
Christopher Ferris76a1d452018-06-27 14:12:29 -070011 __aligned_u64 buf_addr;
12 __aligned_u64 db_addr;
Christopher Ferris32ff3f82020-12-14 13:10:04 -080013 __u32 cqe_size;
14 __u32 reserved;
Christopher Ferris76a1d452018-06-27 14:12:29 -070015};
Christopher Ferris05667cd2021-02-16 16:01:34 -080016enum hns_roce_cq_cap_flags {
17 HNS_ROCE_CQ_FLAG_RECORD_DB = 1 << 0,
18};
Christopher Ferris76a1d452018-06-27 14:12:29 -070019struct hns_roce_ib_create_cq_resp {
20 __aligned_u64 cqn;
21 __aligned_u64 cap_flags;
Christopher Ferris48af7cb2017-02-21 12:35:09 -080022};
Christopher Ferrisd842e432019-03-07 10:21:59 -080023struct hns_roce_ib_create_srq {
24 __aligned_u64 buf_addr;
25 __aligned_u64 db_addr;
26 __aligned_u64 que_addr;
27};
28struct hns_roce_ib_create_srq_resp {
29 __u32 srqn;
30 __u32 reserved;
31};
Christopher Ferris48af7cb2017-02-21 12:35:09 -080032struct hns_roce_ib_create_qp {
Christopher Ferris76a1d452018-06-27 14:12:29 -070033 __aligned_u64 buf_addr;
34 __aligned_u64 db_addr;
Christopher Ferris48af7cb2017-02-21 12:35:09 -080035 __u8 log_sq_bb_count;
36 __u8 log_sq_stride;
37 __u8 sq_no_prefetch;
Christopher Ferris48af7cb2017-02-21 12:35:09 -080038 __u8 reserved[5];
Christopher Ferris9ce28842018-10-25 12:11:39 -070039 __aligned_u64 sdb_addr;
Christopher Ferris48af7cb2017-02-21 12:35:09 -080040};
Christopher Ferris05667cd2021-02-16 16:01:34 -080041enum hns_roce_qp_cap_flags {
42 HNS_ROCE_QP_CAP_RQ_RECORD_DB = 1 << 0,
43 HNS_ROCE_QP_CAP_SQ_RECORD_DB = 1 << 1,
44 HNS_ROCE_QP_CAP_OWNER_DB = 1 << 2,
Christopher Ferris1ed55342022-03-22 16:06:25 -070045 HNS_ROCE_QP_CAP_DIRECT_WQE = 1 << 5,
Christopher Ferris05667cd2021-02-16 16:01:34 -080046};
Christopher Ferris76a1d452018-06-27 14:12:29 -070047struct hns_roce_ib_create_qp_resp {
48 __aligned_u64 cap_flags;
Christopher Ferris1ed55342022-03-22 16:06:25 -070049 __aligned_u64 dwqe_mmap_key;
Christopher Ferris76a1d452018-06-27 14:12:29 -070050};
Christopher Ferris8b7fdc92023-02-21 13:36:32 -080051enum {
52 HNS_ROCE_EXSGE_FLAGS = 1 << 0,
Christopher Ferrisb7cef6d2023-05-09 19:04:15 +000053 HNS_ROCE_RQ_INLINE_FLAGS = 1 << 1,
54 HNS_ROCE_CQE_INLINE_FLAGS = 1 << 2,
Christopher Ferris8b7fdc92023-02-21 13:36:32 -080055};
56enum {
57 HNS_ROCE_RSP_EXSGE_FLAGS = 1 << 0,
Christopher Ferrisb7cef6d2023-05-09 19:04:15 +000058 HNS_ROCE_RSP_RQ_INLINE_FLAGS = 1 << 1,
59 HNS_ROCE_RSP_CQE_INLINE_FLAGS = 1 << 2,
Christopher Ferris8b7fdc92023-02-21 13:36:32 -080060};
Christopher Ferris48af7cb2017-02-21 12:35:09 -080061struct hns_roce_ib_alloc_ucontext_resp {
62 __u32 qp_tab_size;
Christopher Ferris32ff3f82020-12-14 13:10:04 -080063 __u32 cqe_size;
Christopher Ferrisfcc3b4f2021-07-01 01:30:21 +000064 __u32 srq_tab_size;
65 __u32 reserved;
Christopher Ferris8b7fdc92023-02-21 13:36:32 -080066 __u32 config;
67 __u32 max_inline_data;
68};
69struct hns_roce_ib_alloc_ucontext {
70 __u32 config;
71 __u32 reserved;
Christopher Ferris76a1d452018-06-27 14:12:29 -070072};
73struct hns_roce_ib_alloc_pd_resp {
74 __u32 pdn;
Christopher Ferris48af7cb2017-02-21 12:35:09 -080075};
76#endif