[ofw] Problem in building opensm with the 6001 compiler
Tzachi Dar
tzachid at mellanox.co.il
Thu Sep 2 09:12:27 PDT 2010
Replacing the code with uintptr_t indeed seems to make better progress.
I'll check this on all compilers and send a patch if this works.
Thanks
Tzachi
> -----Original Message-----
> From: ofw-bounces at lists.openfabrics.org [mailto:ofw-
> bounces at lists.openfabrics.org] On Behalf Of Hefty, Sean
> Sent: Thursday, September 02, 2010 7:03 PM
> To: Hal Rosenstock; Tzachi Dar
> Cc: ofw at lists.openfabrics.org
> Subject: Re: [ofw] Problem in building opensm with the 6001 compiler
>
> > A pointer to the actual context of the request (a copy of the
> oriignal
> > request structure) is attached as the p_madw-
> > >context.ni_context.node_guid
>
> Also see this comment:
>
> /*
> Provide MAD context such that the call back will know what to
> do.
> We have to keep the entire request structure so we know the
> CB.
> Since we can not rely on the client to keep it around until
> the response - we duplicate it and will later dispose it (in
> CB).
> To store on the MADW we cast it into what opensm has:
> p_madw->context.ni_context.node_guid
> */
> p_query_req_copy = malloc(sizeof(*p_query_req_copy));
> if (!p_query_req_copy) {
> OSM_LOG(p_log, OSM_LOG_ERROR, "ERR 5511: "
> "Unable to acquire memory for query copy\n");
> osm_mad_pool_put(p_bind->p_mad_pool, p_madw);
> status = IB_INSUFFICIENT_RESOURCES;
> goto Exit;
> }
> *p_query_req_copy = *p_query_req;
> p_madw->context.ni_context.node_guid =
> (ib_net64_t) (long)p_query_req_copy;
>
> The (long) cast should probably be (uintptr_t) when saving and
> restoring the pointer.
> _______________________________________________
> ofw mailing list
> ofw at lists.openfabrics.org
> http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ofw
More information about the ofw
mailing list