On Sun, 2009-08-02 at 19:11 -0700, Darren Reed wrote: > In PSARC/2006/475, net_getlifflags is introduced to retrieve > the logical interface flags, which is fair enough. > > Reading the man page, there are some omissions, and possibly > with the case itself too. > > First, neither the man page nor the case enumerate what the > flags are. I suspect that the expectation is people will "know" > that the correct flags are found somewhere else. > > One of two files needs to be documented for use with this API: > either <net/if.h> or <inet/ip_if.h> > > And having chosen which file is to be documented (and thus an > appropriate commitment level given), the relevant flags need > to be pulled out and given the same treatment. > > The choice here is do we publish the IPIF_* names or the IFF_* > names?
IFF_* flags are already Public and documented in if_tcp(7P) (they also happen to be the union of the undocumented IPIF_*, ILLF_*, and PHYI_* flags used for implementation purposes). > The former makes the documentation easy, the latter means > we need to explicitly state that it is only possible for the > flags listed to be seen. The former should the the union of the latter. > On a related note, it is also useful to be able to get the > "other" flags, notably those that are PHYI_* and ILLF_*. IFF_* already includes all of those. > At present my need is only for PHYI_* and thus it seems > logical to construct net_getphyflags() to get just those. > But does that leave the ILLF_* flags out in the cold? > Unless someone can come up with a definitive answer on that, > I'm not comfortable with net_getphyflags() being anything > other than a consolidation private interface. The intent of the interface was to obtain IP interface flags, which are all represented by IFF_* values defined in <net/if.h>. -Seb