From 4f0295fca2cfd933f4b9b539d5505cb24e4d420c Mon Sep 17 00:00:00 2001 From: David Sommerseth Date: Wed, 28 Apr 2010 17:04:26 +0200 Subject: Updated to fetch the interface information when the "getter" function triggers --- python-ethtool/etherinfo.h | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) (limited to 'python-ethtool/etherinfo.h') diff --git a/python-ethtool/etherinfo.h b/python-ethtool/etherinfo.h index bda5185..1b8c425 100644 --- a/python-ethtool/etherinfo.h +++ b/python-ethtool/etherinfo.h @@ -17,18 +17,16 @@ #ifndef _ETHERINFO_H #define _ETHERINFO_H -struct etherinfo { - int index; - char *device; - char *hwaddress; - char *ipv4_address; - int ipv4_netmask; - char *ipv4_broadcast; - char *ipv6_address; - int ipv6_netmask; -}; +#include +#include +#include +#include +#include +#include -struct etherinfo *get_etherinfo(); +typedef enum {NLQRY_LINK, NLQRY_ADDR} nlQuery; + +int get_etherinfo(struct etherinfo *ethinf, struct _nlconnection *nlc, nlQuery query); void free_etherinfo(struct etherinfo *ptr); void dump_etherinfo(FILE *, struct etherinfo *); -- cgit