[ofa-general] [PATCH] libmlx4: Fix the value of the pkey_index in the completion
Dotan Barak
dotanb at dev.mellanox.co.il
Mon Jan 7 22:47:13 PST 2008
Roland Dreier wrote:
> > - wc->pkey_index = ntohl(cqe->immed_rss_invalid) >> 16;
> > + wc->pkey_index = (uint16_t)(ntohl(cqe->immed_rss_invalid) & 0x7f);
>
> This is pretty silly. We don't allow userspace to create QP1 anyway,
> so is there any point setting the pkey_index field here at all?
>
>
You are absolutely right - QP1 is being used only in kernel level but i
wanted to be consistent
with the kernel level, so i fixed this line too.
I checked this issue and every (user) low level driver library, until today,
filled the value of the pkey_index and i didn't want that libmlx4 will
be different ...
Do you think that this code should be removed from all of the user level
libraries?
Dotan
More information about the general
mailing list