Skip to content

Commit f5995fe

Browse files
hz-chengjgunthorpe
authored andcommitted
RDMA/erdma: Add the ABI definitions
Add erdma ABI definitions which will be shared between kernel and userspace. This commit also fix compile issues reported by lkp. Link: https://lore.kernel.org/r/[email protected] Reported-by: kernel test robot <[email protected]> Signed-off-by: Cheng Xu <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
1 parent d55e6fb commit f5995fe

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed

include/uapi/rdma/erdma-abi.h

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
/* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */
2+
/*
3+
* Copyright (c) 2020-2022, Alibaba Group.
4+
*/
5+
6+
#ifndef __ERDMA_USER_H__
7+
#define __ERDMA_USER_H__
8+
9+
#include <linux/types.h>
10+
11+
#define ERDMA_ABI_VERSION 1
12+
13+
struct erdma_ureq_create_cq {
14+
__aligned_u64 db_record_va;
15+
__aligned_u64 qbuf_va;
16+
__u32 qbuf_len;
17+
__u32 rsvd0;
18+
};
19+
20+
struct erdma_uresp_create_cq {
21+
__u32 cq_id;
22+
__u32 num_cqe;
23+
};
24+
25+
struct erdma_ureq_create_qp {
26+
__aligned_u64 db_record_va;
27+
__aligned_u64 qbuf_va;
28+
__u32 qbuf_len;
29+
__u32 rsvd0;
30+
};
31+
32+
struct erdma_uresp_create_qp {
33+
__u32 qp_id;
34+
__u32 num_sqe;
35+
__u32 num_rqe;
36+
__u32 rq_offset;
37+
};
38+
39+
struct erdma_uresp_alloc_ctx {
40+
__u32 dev_id;
41+
__u32 pad;
42+
__u32 sdb_type;
43+
__u32 sdb_offset;
44+
__aligned_u64 sdb;
45+
__aligned_u64 rdb;
46+
__aligned_u64 cdb;
47+
};
48+
49+
#endif

0 commit comments

Comments
 (0)