summaryrefslogtreecommitdiffstats
path: root/package/swconfig/src/swlib.c
diff options
context:
space:
mode:
Diffstat (limited to 'package/swconfig/src/swlib.c')
-rw-r--r--package/swconfig/src/swlib.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/package/swconfig/src/swlib.c b/package/swconfig/src/swlib.c
index 8a9fd7a29..59456a33d 100644
--- a/package/swconfig/src/swlib.c
+++ b/package/swconfig/src/swlib.c
@@ -586,6 +586,8 @@ add_switch(struct nl_msg *msg, void *arg)
dev->ports = nla_get_u32(tb[SWITCH_ATTR_PORTS]);
if (tb[SWITCH_ATTR_VLANS])
dev->vlans = nla_get_u32(tb[SWITCH_ATTR_VLANS]);
+ if (tb[SWITCH_ATTR_CPU_PORT])
+ dev->cpu_port = nla_get_u32(tb[SWITCH_ATTR_CPU_PORT]);
if (!sa->head) {
sa->head = dev;