/drivers/vdpa/mlx5/core/ |
D | mr.c | 29 static void mlx5_set_access_mode(void *mkc, int mode) in mlx5_set_access_mode() argument 31 MLX5_SET(mkc, mkc, access_mode_1_0, mode & 0x3); in mlx5_set_access_mode() 32 MLX5_SET(mkc, mkc, access_mode_4_2, mode >> 2); in mlx5_set_access_mode() 55 void *mkc; in create_direct_mr() local 65 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in create_direct_mr() 66 MLX5_SET(mkc, mkc, lw, !!(mr->perm & VHOST_MAP_WO)); in create_direct_mr() 67 MLX5_SET(mkc, mkc, lr, !!(mr->perm & VHOST_MAP_RO)); in create_direct_mr() 68 mlx5_set_access_mode(mkc, MLX5_MKC_ACCESS_MODE_MTT); in create_direct_mr() 69 MLX5_SET(mkc, mkc, qpn, 0xffffff); in create_direct_mr() 70 MLX5_SET(mkc, mkc, pd, mvdev->res.pdn); in create_direct_mr() [all …]
|
D | resources.c | 206 void *mkc; in mlx5_vdpa_create_mkey() local 216 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5_vdpa_create_mkey() 218 mkey->iova = MLX5_GET64(mkc, mkc, start_addr); in mlx5_vdpa_create_mkey() 219 mkey->size = MLX5_GET64(mkc, mkc, len); in mlx5_vdpa_create_mkey() 221 mkey->pd = MLX5_GET(mkc, mkc, pd); in mlx5_vdpa_create_mkey()
|
/drivers/net/ethernet/mellanox/mlx5/core/ |
D | en_common.c | 39 void mlx5e_mkey_set_relaxed_ordering(struct mlx5_core_dev *mdev, void *mkc) in mlx5e_mkey_set_relaxed_ordering() argument 45 MLX5_SET(mkc, mkc, relaxed_ordering_read, ro_pci_enable && ro_read); in mlx5e_mkey_set_relaxed_ordering() 46 MLX5_SET(mkc, mkc, relaxed_ordering_write, ro_pci_enable && ro_write); in mlx5e_mkey_set_relaxed_ordering() 53 void *mkc; in mlx5e_create_mkey() local 61 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5e_create_mkey() 62 MLX5_SET(mkc, mkc, access_mode_1_0, MLX5_MKC_ACCESS_MODE_PA); in mlx5e_create_mkey() 63 MLX5_SET(mkc, mkc, lw, 1); in mlx5e_create_mkey() 64 MLX5_SET(mkc, mkc, lr, 1); in mlx5e_create_mkey() 65 mlx5e_mkey_set_relaxed_ordering(mdev, mkc); in mlx5e_create_mkey() 66 MLX5_SET(mkc, mkc, pd, pdn); in mlx5e_create_mkey() [all …]
|
D | mr.c | 44 void *mkc; in mlx5_core_create_mkey() local 53 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5_core_create_mkey() 55 mkey->iova = MLX5_GET64(mkc, mkc, start_addr); in mlx5_core_create_mkey() 56 mkey->size = MLX5_GET64(mkc, mkc, len); in mlx5_core_create_mkey() 58 mkey->pd = MLX5_GET(mkc, mkc, pd); in mlx5_core_create_mkey()
|
D | en_main.c | 243 void *mkc; in mlx5e_create_umr_mkey() local 254 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5e_create_umr_mkey() 256 MLX5_SET(mkc, mkc, free, 1); in mlx5e_create_umr_mkey() 257 MLX5_SET(mkc, mkc, umr_en, 1); in mlx5e_create_umr_mkey() 258 MLX5_SET(mkc, mkc, lw, 1); in mlx5e_create_umr_mkey() 259 MLX5_SET(mkc, mkc, lr, 1); in mlx5e_create_umr_mkey() 260 MLX5_SET(mkc, mkc, access_mode_1_0, MLX5_MKC_ACCESS_MODE_MTT); in mlx5e_create_umr_mkey() 261 mlx5e_mkey_set_relaxed_ordering(mdev, mkc); in mlx5e_create_umr_mkey() 262 MLX5_SET(mkc, mkc, qpn, 0xffffff); in mlx5e_create_umr_mkey() 263 MLX5_SET(mkc, mkc, pd, mdev->mlx5e_res.hw_objs.pdn); in mlx5e_create_umr_mkey() [all …]
|
D | en.h | 219 struct mlx5_mkey_seg mkc; member 1043 void mlx5e_mkey_set_relaxed_ordering(struct mlx5_core_dev *mdev, void *mkc);
|
/drivers/infiniband/hw/mlx5/ |
D | mr.c | 67 static void set_mkc_access_pd_addr_fields(void *mkc, int acc, u64 start_addr, in set_mkc_access_pd_addr_fields() argument 73 MLX5_SET(mkc, mkc, a, !!(acc & IB_ACCESS_REMOTE_ATOMIC)); in set_mkc_access_pd_addr_fields() 74 MLX5_SET(mkc, mkc, rw, !!(acc & IB_ACCESS_REMOTE_WRITE)); in set_mkc_access_pd_addr_fields() 75 MLX5_SET(mkc, mkc, rr, !!(acc & IB_ACCESS_REMOTE_READ)); in set_mkc_access_pd_addr_fields() 76 MLX5_SET(mkc, mkc, lw, !!(acc & IB_ACCESS_LOCAL_WRITE)); in set_mkc_access_pd_addr_fields() 77 MLX5_SET(mkc, mkc, lr, 1); in set_mkc_access_pd_addr_fields() 80 MLX5_SET(mkc, mkc, relaxed_ordering_write, in set_mkc_access_pd_addr_fields() 83 MLX5_SET(mkc, mkc, relaxed_ordering_read, in set_mkc_access_pd_addr_fields() 86 MLX5_SET(mkc, mkc, pd, to_mpd(pd)->pdn); in set_mkc_access_pd_addr_fields() 87 MLX5_SET(mkc, mkc, qpn, 0xffffff); in set_mkc_access_pd_addr_fields() [all …]
|
D | wr.c | 409 MLX5_SET(mkc, seg, free, 1); in set_reg_mkey_segment() 411 MLX5_SET(mkc, seg, a, in set_reg_mkey_segment() 413 MLX5_SET(mkc, seg, rw, in set_reg_mkey_segment() 415 MLX5_SET(mkc, seg, rr, !!(umrwr->access_flags & IB_ACCESS_REMOTE_READ)); in set_reg_mkey_segment() 416 MLX5_SET(mkc, seg, lw, !!(umrwr->access_flags & IB_ACCESS_LOCAL_WRITE)); in set_reg_mkey_segment() 417 MLX5_SET(mkc, seg, lr, 1); in set_reg_mkey_segment() 419 MLX5_SET(mkc, seg, relaxed_ordering_write, in set_reg_mkey_segment() 422 MLX5_SET(mkc, seg, relaxed_ordering_read, in set_reg_mkey_segment() 426 MLX5_SET(mkc, seg, pd, to_mpd(umrwr->pd)->pdn); in set_reg_mkey_segment() 429 MLX5_SET(mkc, seg, length64, 1); in set_reg_mkey_segment() [all …]
|
D | devx.c | 1311 void *mkc; in devx_handle_mkey_indirect() local 1315 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in devx_handle_mkey_indirect() 1316 key = MLX5_GET(mkc, mkc, mkey_7_0); in devx_handle_mkey_indirect() 1320 mkey->iova = MLX5_GET64(mkc, mkc, start_addr); in devx_handle_mkey_indirect() 1321 mkey->size = MLX5_GET64(mkc, mkc, len); in devx_handle_mkey_indirect() 1322 mkey->pd = MLX5_GET(mkc, mkc, pd); in devx_handle_mkey_indirect() 1323 devx_mr->ndescs = MLX5_GET(mkc, mkc, translations_octword_size); in devx_handle_mkey_indirect() 1336 void *mkc; in devx_handle_mkey_create() local 1342 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in devx_handle_mkey_create() 1344 access_mode = MLX5_GET(mkc, mkc, access_mode_1_0); in devx_handle_mkey_create() [all …]
|
D | odp.c | 707 page_size = mlx5_umem_find_best_pgsz(&umem_dmabuf->umem, mkc, in pagefault_dmabuf_mr()
|
/drivers/net/ethernet/mellanox/mlx5/core/steering/ |
D | dr_icm_pool.c | 39 void *mkc; in dr_icm_create_dm_mkey() local 41 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in dr_icm_create_dm_mkey() 43 MLX5_SET(mkc, mkc, access_mode_1_0, mode); in dr_icm_create_dm_mkey() 44 MLX5_SET(mkc, mkc, access_mode_4_2, (mode >> 2) & 0x7); in dr_icm_create_dm_mkey() 45 MLX5_SET(mkc, mkc, lw, 1); in dr_icm_create_dm_mkey() 46 MLX5_SET(mkc, mkc, lr, 1); in dr_icm_create_dm_mkey() 48 MLX5_SET(mkc, mkc, rw, 1); in dr_icm_create_dm_mkey() 49 MLX5_SET(mkc, mkc, rr, 1); in dr_icm_create_dm_mkey() 52 MLX5_SET64(mkc, mkc, len, length); in dr_icm_create_dm_mkey() 53 MLX5_SET(mkc, mkc, pd, pd); in dr_icm_create_dm_mkey() [all …]
|
D | dr_send.c | 855 void *mkc; in dr_create_mkey() local 857 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in dr_create_mkey() 858 MLX5_SET(mkc, mkc, access_mode_1_0, MLX5_MKC_ACCESS_MODE_PA); in dr_create_mkey() 859 MLX5_SET(mkc, mkc, a, 1); in dr_create_mkey() 860 MLX5_SET(mkc, mkc, rw, 1); in dr_create_mkey() 861 MLX5_SET(mkc, mkc, rr, 1); in dr_create_mkey() 862 MLX5_SET(mkc, mkc, lw, 1); in dr_create_mkey() 863 MLX5_SET(mkc, mkc, lr, 1); in dr_create_mkey() 865 MLX5_SET(mkc, mkc, pd, pdn); in dr_create_mkey() 866 MLX5_SET(mkc, mkc, length64, 1); in dr_create_mkey() [all …]
|
/drivers/net/ethernet/mellanox/mlx5/core/diag/ |
D | rsc_dump.c | 227 void *mkc; in mlx5_rsc_dump_create_mkey() local 235 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5_rsc_dump_create_mkey() 236 MLX5_SET(mkc, mkc, access_mode_1_0, MLX5_MKC_ACCESS_MODE_PA); in mlx5_rsc_dump_create_mkey() 237 MLX5_SET(mkc, mkc, lw, 1); in mlx5_rsc_dump_create_mkey() 238 MLX5_SET(mkc, mkc, lr, 1); in mlx5_rsc_dump_create_mkey() 240 MLX5_SET(mkc, mkc, pd, pdn); in mlx5_rsc_dump_create_mkey() 241 MLX5_SET(mkc, mkc, length64, 1); in mlx5_rsc_dump_create_mkey() 242 MLX5_SET(mkc, mkc, qpn, 0xffffff); in mlx5_rsc_dump_create_mkey()
|
D | fw_tracer.c | 182 void *mkc; in mlx5_fw_tracer_create_mkey() local 198 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5_fw_tracer_create_mkey() 199 MLX5_SET(mkc, mkc, access_mode_1_0, MLX5_MKC_ACCESS_MODE_MTT); in mlx5_fw_tracer_create_mkey() 200 MLX5_SET(mkc, mkc, lr, 1); in mlx5_fw_tracer_create_mkey() 201 MLX5_SET(mkc, mkc, lw, 1); in mlx5_fw_tracer_create_mkey() 202 MLX5_SET(mkc, mkc, pd, tracer->buff.pdn); in mlx5_fw_tracer_create_mkey() 203 MLX5_SET(mkc, mkc, bsf_octword_size, 0); in mlx5_fw_tracer_create_mkey() 204 MLX5_SET(mkc, mkc, qpn, 0xffffff); in mlx5_fw_tracer_create_mkey() 205 MLX5_SET(mkc, mkc, log_page_size, PAGE_SHIFT); in mlx5_fw_tracer_create_mkey() 206 MLX5_SET(mkc, mkc, translations_octword_size, in mlx5_fw_tracer_create_mkey() [all …]
|
/drivers/net/ethernet/mellanox/mlx5/core/fpga/ |
D | conn.c | 227 void *mkc; in mlx5_fpga_conn_create_mkey() local 235 mkc = MLX5_ADDR_OF(create_mkey_in, in, memory_key_mkey_entry); in mlx5_fpga_conn_create_mkey() 236 MLX5_SET(mkc, mkc, access_mode_1_0, MLX5_MKC_ACCESS_MODE_PA); in mlx5_fpga_conn_create_mkey() 237 MLX5_SET(mkc, mkc, lw, 1); in mlx5_fpga_conn_create_mkey() 238 MLX5_SET(mkc, mkc, lr, 1); in mlx5_fpga_conn_create_mkey() 240 MLX5_SET(mkc, mkc, pd, pdn); in mlx5_fpga_conn_create_mkey() 241 MLX5_SET(mkc, mkc, length64, 1); in mlx5_fpga_conn_create_mkey() 242 MLX5_SET(mkc, mkc, qpn, 0xffffff); in mlx5_fpga_conn_create_mkey()
|
/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ |
D | ktls_utils.h | 34 struct mlx5_mkey_seg mkc; member
|