summaryrefslogtreecommitdiffstats
path: root/package/network/config/swconfig/src/swlib.h
diff options
context:
space:
mode:
authorblogic <blogic@3c298f89-4303-0410-b956-a3cf2f4a3e73>2013-04-09 14:19:13 +0000
committerblogic <blogic@3c298f89-4303-0410-b956-a3cf2f4a3e73>2013-04-09 14:19:13 +0000
commit65dcba6303e8d0ae940dfc0ffe6b1e48f9114159 (patch)
treea3ea430dcef3781b3947206602f5c2b80e14f8bf /package/network/config/swconfig/src/swlib.h
parentef55a217d20e3910d4a37af41447cfffb1178591 (diff)
[swconfig] add portmap support to userland
Signed-off-by: John Crispin <blogic@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36284 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/network/config/swconfig/src/swlib.h')
-rw-r--r--package/network/config/swconfig/src/swlib.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/package/network/config/swconfig/src/swlib.h b/package/network/config/swconfig/src/swlib.h
index 02fa45610..016f74b4f 100644
--- a/package/network/config/swconfig/src/swlib.h
+++ b/package/network/config/swconfig/src/swlib.h
@@ -109,6 +109,7 @@ enum swlib_port_flags {
struct switch_dev;
struct switch_attr;
struct switch_port;
+struct switch_port_map;
struct switch_val;
struct uci_package;
@@ -123,6 +124,7 @@ struct switch_dev {
struct switch_attr *ops;
struct switch_attr *port_ops;
struct switch_attr *vlan_ops;
+ struct switch_portmap *maps;
struct switch_dev *next;
void *priv;
};
@@ -154,12 +156,23 @@ struct switch_port {
unsigned int flags;
};
+struct switch_portmap {
+ unsigned int virt;
+ const char *segment;
+};
+
/**
* swlib_list: list all switches
*/
void swlib_list(void);
/**
+ * swlib_print_portmap: get portmap
+ * @dev: switch device struct
+ */
+void swlib_print_portmap(struct switch_dev *dev, char *segment);
+
+/**
* swlib_connect: connect to the switch through netlink
* @name: name of the ethernet interface,
*