[openib-general] [PATCH][RFC] kDAPL: remove dat wrapper function dat_ia_query()

Grant Grundler iod00d at hp.com
Wed Jun 8 17:07:31 PDT 2005


On Wed, Jun 08, 2005 at 03:54:34PM -0700, Tom Duffy wrote:
> I am putting this out there to see what people think about this sort of
> change.  This only does it for one of the functions in dat provider, but
> I will change it for all if this is accepted.

I agree it's the right direction. I would not have guessed dat_ia_query()
is really a macro that does pointer chasing.

> -    ret = dat_ia_query (test_ptr->ia,
> -			NULL,
> -			&test_ptr->ia_attr,
> -			NULL);
> +    ret = test_ptr->ia->common.provider->dat_ia_query(test_ptr->ia, NULL,
> +						      &test_ptr->ia_attr, NULL);

Maybe not reference test_ptr in this line so often?
It could read:
	ret = ia->common.provider->dat_ia_query(ia, NULL, &test_ptr->ia_attr,
							NULL);

> -	.ia_query_func = &dapl_ia_query,
> +	.dat_ia_query = &dapl_ia_query,

Yes. I like this alot better too.

thanks,
grant



More information about the general mailing list