[openib-general] [PATCH 4/7] IB/ipath - performance improvements via mmap of queues

Roland Dreier rdreier at cisco.com
Mon Aug 14 12:37:25 PDT 2006


    ralphc> This doesn't break compatibility.  uverbs_cmd.c
    ralphc> ib_uverbs_resize_cq() allocates a struct
    ralphc> ib_uverbs_resize_cq_resp on the stack but only reads the
    ralphc> first element in.  The structure change isn't really
    ralphc> needed at all since the INIT_UDATA() macro gets the start
    ralphc> of driver_data from the struct ib_uverbs_resize_cq.  The
    ralphc> change to ib_uverbs_resize_cq_resp just matches the
    ralphc> structure change used by libipathverbs to initialize
    ralphc> ib_uverbs_resize_cq.response.

Am I missing something?  Think about the case of old libibverbs, new
kernel.  libibverbs allocates a 4-byte response structure and passes
the pointer to that to the kernel.  The kernel allocates an 8-byte
response structure and copies it back to userspace.  And the 4 bytes
after the userspace response structure get zeroed.

 - R.




More information about the general mailing list