Re: [PATCH v6 09/25] rtrs: server: private header with server structs and functions

Jinpu Wang
2020-01-08T16:33:39Z

On Thu, Jan 2, 2020 at 10:24 PM Bart Van Assche <bvanassche@acm.org> wrote:
>
> On 12/30/19 2:29 AM, Jack Wang wrote:
> > +struct rtrs_stats_wc_comp {
> > + atomic64_t calls;
> > + atomic64_t total_wc_cnt;
> > +};
>
> Please document the meaning of the members of this data structure.
will do.
>
> > +struct rtrs_srv_stats_rdma_stats {
> > + struct {
> > + atomic64_t cnt;
> > + atomic64_t size_total;
> > + } dir[2];
> > +};
>
> Please document the meaning of the members of this data structure and
> also which index (0, 1) corresponds to which direction (read, write).
yes, will do.
>
> > +struct rtrs_srv_op {
> > + struct rtrs_srv_con *con;
> > + u32 msg_id;
> > + u8 dir;
> > + struct rtrs_msg_rdma_read *rd_msg;
> > + struct ib_rdma_wr *tx_wr;
> > + struct ib_sge *tx_sg;
> > +};
>
> Please document the role of this data structure.
ok.
>
> > +struct rtrs_srv_mr {
> > + struct ib_mr *mr;
> > + struct sg_table sgt;
> > + struct ib_cqe inv_cqe; /* only for always_invalidate=true */
> > + u32 msg_id; /* only for always_invalidate=true */
> > + u32 msg_off; /* only for always_invalidate=true */
> > + struct rtrs_iu *iu; /* send buffer for new rkey msg */
> > +};
>
> Please document the role of this data structure.
ok
>
> > +extern struct class *rtrs_dev_class;
>
> Please make sure that the static 'rtrs_dev_class' variable in rtrs-clt.c
> and in this header file have different names.
ok
>
> Thanks,
>
> Bart.
Thanks