Re: RFC : Wireless Netlink events

kuznet@ms2.inr.ac.ru
Wed, 10 Oct 2001 21:49:52 +0400 (MSK DST)


Hello!

> o Is there a way to do a reverse of SIOCGIFINDEX ? If you have
> an interface index, how do you get its name ?

SIOCGIFNAME.

But this does not matter, applications using rtnetlink should
not use these ioctls. They have all the information from rtnetlink.

> o Should I put the full interface name in the event ? That
> would make events larger but help query the interface when receiving
> the event.

Never. They are known from context.

> o Any other comments ?

I am not sure that it is right and in right place. I would not create one
more message type for such... mmm... special case.
Probably, you could add a new attribute to RTM_*LINK sort of
IFLA_MISC and to send ifinfo messages.

But I see logical flaw: no way to _retrieve_ information about state
on demand. Hence no right application cannot rely only on these messages.
Hence you should go all the way and to allow to dump this and,
probably, to add statistics shown in /proc/net/wireless.

Alexey
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/