On Thu, Jul 30, 2015 at 11:06:25AM +0300, Sagi Grimberg wrote:
> /**
> + * struct iser_device - Memory registration operations
> + * per-device registration schemes
> + *
> + * @alloc_reg_res: Allocate registration resources
> + * @free_reg_res: Free registration resources
> + * @reg_rdma_mem: Register memory buffers
> + * @unreg_rdma_mem: Un-register memory buffers
> + */
> +struct iser_reg_ops {
> + int (*alloc_reg_res)(struct ib_conn *ib_conn,
> + unsigned cmds_max);
> + void (*free_reg_res)(struct ib_conn *ib_conn);
> + int (*reg_rdma_mem)(struct iscsi_iser_task *iser_task,
> + enum iser_data_dir cmd_dir);
> + void (*unreg_rdma_mem)(struct iscsi_iser_task *iser_task,
> + enum iser_data_dir cmd_dir);
> +};
It sucks we need every ULP to have function pointer swap outs just to
support MRs.. NFS has the same...
>
> if (iser_task->dir[ISER_DIR_IN]) {
> - device->iser_unreg_rdma_mem(iser_task, ISER_DIR_IN);
> + device->reg_ops->unreg_rdma_mem(iser_task, ISER_DIR_IN);
> if (is_rdma_data_aligned)
> iser_dma_unmap_task_data(iser_task,
> &iser_task->data[ISER_DIR_IN],
Is this the same wrong ordering that NFS had?
DMA unmap (and CPU access) for ACCESS_REMOTE_WRITE rkeys should happen
after invalidate completes, not before.
Jason
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html