IB/mlx4: Add support for memory management extensions and local DMA L_Key

Add support for the following operations to mlx4 when device firmware
supports them:

 - Send with invalidate and local invalidate send queue work requests;
 - Allocate/free fast register MRs;
 - Allocate/free fast register MR page lists;
 - Fast register MR send queue work requests;
 - Local DMA L_Key.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
This commit is contained in:
Roland Dreier 2008-07-23 08:12:26 -07:00
parent e4044cfc49
commit 95d04f0735
11 changed files with 221 additions and 22 deletions

View file

@ -233,6 +233,14 @@ struct mlx4_wqe_bind_seg {
__be64 length;
};
enum {
MLX4_WQE_FMR_PERM_LOCAL_READ = 1 << 27,
MLX4_WQE_FMR_PERM_LOCAL_WRITE = 1 << 28,
MLX4_WQE_FMR_PERM_REMOTE_READ = 1 << 29,
MLX4_WQE_FMR_PERM_REMOTE_WRITE = 1 << 30,
MLX4_WQE_FMR_PERM_ATOMIC = 1 << 31
};
struct mlx4_wqe_fmr_seg {
__be32 flags;
__be32 mem_key;
@ -255,11 +263,11 @@ struct mlx4_wqe_fmr_ext_seg {
};
struct mlx4_wqe_local_inval_seg {
u8 flags;
u8 reserved1[3];
__be32 flags;
u32 reserved1;
__be32 mem_key;
u8 reserved2[3];
u8 guest_id;
u32 reserved2[2];
__be32 guest_id;
__be64 pa;
};