switch: export name of device found via /proc
[openwrt/svn-archive/archive.git] / package / switch / src / switch-core.h
index 7192f7b0f4a8cbf932c3ade1319bd43fb6feeeb3..cc520e4935344cf2c91c3f16538f7b8cb428b20e 100644 (file)
@@ -4,6 +4,7 @@
 #include <linux/version.h>
 #include <linux/list.h>
 #define SWITCH_MAX_BUFSZ       4096
+#define SWITCH_NAME_BUFSZ      16
 
 #define SWITCH_MEDIA_AUTO      1
 #define SWITCH_MEDIA_100       2
@@ -28,6 +29,7 @@ typedef struct {
        const switch_config *driver_handlers, *port_handlers, *vlan_handlers;
        void *data;
        void *priv;
+       char dev_name[SWITCH_NAME_BUFSZ];
 } switch_driver;
 
 typedef struct {