Re: [PATCH v2] [RFC] rdma/cm: support option to allow manually setting IB path

Jason Gunthorpe
2009-10-22T18:36:36Z

On Thu, Oct 22, 2009 at 11:28:11AM -0700, Sean Hefty wrote:

> I don't like the idea of the kernel silently ignoring the alternate path.
> Returning an error seems like a better idea.

Then provide a way for userspace to know WTF to do. Without a
negotiation process this is now an 'impossible to use right' API.

There are other kernel protocols that work like this, some netlink
stuff works like this for instance. The notion of providing multiple
options and having the kernel pick the ones it supports is a standard
technique for forward API compatability.

How about a compromise. Add a IB_PATH_MUST or something, if the kernel
skips over an entry marked like that due to no support then it returns
-ENOSYS. Userspace that really cares can use that flag. I expect most
cases won't care..

Jason