if (!iface)
return UBUS_STATUS_UNKNOWN_ERROR;
- interface_set_dynamic(iface);
iface->device_config = true;
config = blob_memdup(msg);
goto error;
interface_add(iface, config);
+ interface_set_dynamic(iface);
// need to look up the interface name again, in case of config update,
iface = vlist_find(&interfaces, name, iface, node);
blobmsg_add_string(&b, "device", dev->ifname);
if (iface->state == IFS_UP) {
+ if (iface->updated) {
+ a = blobmsg_open_array(&b, "updated");
+
+ if (iface->updated & IUF_ADDRESS)
+ blobmsg_add_string(&b, NULL, "addresses");
+ if (iface->updated & IUF_ROUTE)
+ blobmsg_add_string(&b, NULL, "routes");
+ if (iface->updated & IUF_PREFIX)
+ blobmsg_add_string(&b, NULL, "prefixes");
+ if (iface->updated & IUF_DATA)
+ blobmsg_add_string(&b, NULL, "data");
+
+ blobmsg_close_array(&b, a);
+ }
+
if (iface->ip4table)
blobmsg_add_u32(&b, "ip4table", iface->ip4table);
if (iface->ip6table)