Date: Thu, 13 Dec 2012 13:46:26 +0200 From: Andriy Gapon <avg@FreeBSD.org> To: freebsd-net@FreeBSD.org Subject: ng_ether naming Message-ID: <50C9C012.8020306@FreeBSD.org>
next in thread | raw e-mail | index | archive | help
ng_ether uses if_xname for naming its nodes. This could be troublesome for mapping interface names to their ng_ether companions in the face of interface renaming capability. Especially given that interface renaming and ng_ether _module_ loading may happen in an arbitrary order. I am not sure how to solve this best. One possibility is to use if_dname+if_dunit combination for ng_ether naming. This should be stable and available for querying. This behavior should also be backward compatible with ng_ether being compiled into kernel (if_dname+if_dunit == if_xname before any renaming could occur). Another possibility is to do ng_ether renaming when its interface is renamed. This seems nicer but appears to be more work and more intrusive, because interfaces would have to know about their ng_ether nodes. What do you think? Thank you. And just in case: $ ifconfig -l net0 lo0 $ ngctl list There are 2 total nodes: Name: re0 Type: ether ID: 00000001 Num hooks: 0 Name: ngctl11353 Type: socket ID: 00000003 Num hooks: 0 -- Andriy Gapon
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?50C9C012.8020306>