[ofa-general] [RFC] OpenSM vendor layer

Sasha Khapyorsky sashak at voltaire.com
Sat Feb 7 04:33:55 PST 2009


On 14:12 Fri 06 Feb     , Hal Rosenstock wrote:
> 
> I'm looking at adding pkey support into the OpenSM vendor layer. The
> pkey table is a per port structure and is part of ib_port_attr_t. That
> structure also include num_pkeys. There is only related API:
> osm_vendor_get_all_port_attr which takes several pointers, the second
> one is a pointer to a preallocated array of port attributes (memory
> allocation for that is done by the client). ib_port_attr_t includes a
> pointer to the pkey table. So the only way this can work is if that
> allocation is also done by the client which makes that a valid
> parameter on input (as well as output).

This could be a client choice: if pkey table pointer is initialized as
NULL osm_vendor_get_all_port_attr() allocates memory and initialize the
table and its size, otherwise it fills up only provided by client pkey
table entries.

Sasha



More information about the general mailing list