On Sat, Mar 09, 2019 at 11:47:00AM +0200, Leon Romanovsky wrote: > On Fri, Mar 08, 2019 at 08:18:01PM +0000, Jason Gunthorpe wrote: > > On Fri, Mar 08, 2019 at 10:13:48PM +0200, Leon Romanovsky wrote: > > > On Fri, Mar 08, 2019 at 02:16:31PM +0000, Jason Gunthorpe wrote: > > > > On Wed, Mar 06, 2019 at 12:08:47PM +0200, Leon Romanovsky wrote: > > > > > From: Leon Romanovsky <leonro@xxxxxxxxxxxx> > > > > > > > > > > Generalize the naming scheme for RDMA devices, so users will always > > > > > see names based on topology/GUID information. Such naming scheme has > > > > > big advantage that the names are fully automatic, fully predictable > > > > > and they stay fixed even if hardware is added or removed (i.e. no > > > > > reenumeration takes place) and that broken hardware can be replaced > > > > > seamlessly. > > > > > > > > > > The naming policy is possible to chose from NAME_KERNEL, NAME_PCI, > > > > > NAME_GUID or NAME_FALLBACK, which is controlled by udev rule. > > > > > > > > > > * NAME_KERNEL - don't change names and rely on kernel assignment. This > > > > > will keep RDMA names as before. Example: "mlx5_0". > > > > > * NAME_PCI - read PCI location and topology as a source for stable names, > > > > > which won't change in any software event (reset, PCI probe e.t.c.). > > > > > Example: "mlxp0s12f4". > > > > > > > > I don't think we should have the vendor/driver name in the stable > > > > names. Ethernet doesn't do this. > > > > > > > > At worst it should be the base technology: > > > > > > > > ibp0s12f4 > > > > rocep0s12f4 > > > > iwp0s12f4 > > > > opap0s12f4 > > > > > > It was my initial thought, but mlx4 with his dual mode, where one port > > > can be IB and another can be RoCE doesn't allow us to use this scheme. > > > Any idea how to name mlx4? > > > > It shouldn't be doing that in the first place, use the lowest port > > number to set the name. > > I'm not convinced that base technology is right thing to do. > > Do we have clear (and not verbs) way to distinguish type of HCA? > What should we do with non-RDMA devices like EFA or other big vendor who > will invent "new, single vendor technology"? > How can we recognize OPA? I think you are reading too much into things, we just need a sensible Linux-agreed name that reflects the capabilities of the nic. opa, efa, usnic, are good enough names for this purpose. It doesn't have to be 'standard' in broader sense. Jason