On Thu, Feb 07, 2019 at 10:31:48PM +0200, Leon Romanovsky wrote: > > That is a silly place to end up - there is no reason to use port == 0 > > here as invalid, it should be fixed. > > What exactly do you suggest to fix? > > If user provides "port", it will need to pass rdma_is_port_valid() check. > We have exactly zero drivers which know how to handle is_switch correctly. I do not want to see half implemented stuff, either follow the existing convention for port number and is_switch in the core code or delete the is_switch stuff. Since using -1 or something here is really trivial, that seesm like the right answer Jason