On Thu, Jan 11, 2018 at 07:50:21PM +0000, Bart Van Assche wrote: > On Thu, 2018-01-11 at 17:31 +0200, Leon Romanovsky wrote: > > --- a/include/rdma/ib_verbs.h > > +++ b/include/rdma/ib_verbs.h > > @@ -1141,6 +1141,12 @@ struct ib_qp_init_attr { > > u8 port_num; > > struct ib_rwq_ind_table *rwq_ind_tbl; > > u32 source_qpn; > > + > > + /* > > + * Name of entity which created this QP, empty string means that > > + * it will be taken automatically from task_struct. > > + */ > > + char comm[TASK_COMM_LEN]; > > }; > > Why is "comm" a char array instead of a const char pointer or dynamically > allocated memory (kstrdup())? Can we get rid of the strncpy() calls in code > that fills in this data structure? Yes, we can, initially, I didn't want to bother with corner cases of failure in allocations, but in last version of code it is already easy to deal, so I'll replace. > > Thanks, > > Bart. >
Attachment:
signature.asc
Description: PGP signature