[openib-general] Re: RFC: process_mad extension

Sean Hefty sean.hefty at intel.com
Sun Jan 9 23:57:13 PST 2005


> - Rather than changing IB_MAD_IGNORE_MKEY to IB_MAD_IGNORE_MKEY_BKEY,
>   why not introduce new flags IB_MAD_IGNORE_BKEY and IB_MAD_IGNORE_ALL
>   with IB_MAD_IGNORE_ALL set to IB_MAD_IGNORE_MKEY | IB_MAD_IGNORE_BKEY?
>   This matches the behavior of the FW better and lets existing code
>   such as sysfs.c remain unchanged.

I agree.  Creating a new flag to ignore the BKEY seems like a better
approach.  I don't know if it makes sense to create an IGNORE_ALL
flag, in case the flags need to be extended in the future.

> - This last comment is just taste and maybe I'm wrong, but I don't
>   see much advantage to defining a separate function build_smp_wc()
>   that is only called from one place.

I think that this is taste, but I myself find that separating 
functionality out into different routines tends to generate more
readable code, provided that the code is divided in a sane way.  In
this specific case, I think a separate call makes sense, but that's
just my opinion...

- Sean




More information about the general mailing list