On Thu, 2004-10-14 at 14:50, Sean Hefty wrote: > I was thinking that clients wouldn't provide a mad_reg_req parameter > if they were only going to issue sends. Although, I can see where the > documentation says that the parameter _may_ be NULL in that case, > rather than _must_ be NULL. Is there any use for mad_reg_req > for clients that only issue sends?
I don't see one. It is pretty much ignored on the send side right now. The only use would be if we implemented some send side checking. > How about this? > > In ib_post_send_mad(), we could perform something like: > > if (!mad_agent->send_handler || > (send_wc->wr.ud.timeout_ms && !mad_agent->recv_handler)) > return -EINVAL; > > With this check and a check in ib_register_mad_agent() for: > > if (mad_reg_req && !recv_handler) > return -EINVAL > > (or something similar, depending on when mad_reg_req is required.) > I think we can safely remove all other checks for valid handlers. > We may still want to keep the other send_handler check after the > else to if (mad_reg_req) in ib_register_mad_agent(), but it shouldn't > be needed. This makes sense. I'll work up a patch for this approach. -- Hal _______________________________________________ openib-general mailing list [EMAIL PROTECTED] http://openib.org/mailman/listinfo/openib-general To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general
