Subject: Re: [PATCH v2 01/17] IB/Verbs: Implement new callback query_transport() for each HW

From: Doug Ledford <[email-masked]>
Date: Thu, 09 Apr 2015 17:19:08 -0400

On Thu, 2015-04-09 at 10:01 -0600, Jason Gunthorpe wrote:
> On Thu, Apr 09, 2015 at 10:34:30AM -0400, Doug Ledford wrote:
> 
> > These are exactly the tests I proposed Jason.  I'm not sure I see your
> > point here.  I guess my point is that although the scenario of all the
> > different items seems complex, it really does boil down to needing only
> > exactly what I proposed earlier to fulfill the entire test matrix.
> 
> I have no problem with minimizing a bitmap, but I want the accessors
> to make sense first.
> 
> My specific problem with your suggestion was combining cap_ib_mad,
> cap_ib_sa, and cap_ib_smi into rdma_port_ib_fabric_mgmt.
> 
> Not only do the three cap things not return the same value for all
> situations, the documentary knowledge is lost by the reduction.
> 
> I'd prefer we look at this from a 'what do the call sites need' view,
> not a 'how do we minimize' view.
> 
> I've written this before: The mess here is that it is too hard to know
> what the call sites are actually checking for when it is some baroque
> conditional.

The two goals: being specific about what the test is returning and
minimizing the bitmap footprint; are not necessarily opposed.  One can
do both at the same time.

-- 
Doug Ledford <[email-masked]>
              GPG KeyID: 0E572FDD