ROUTE_ONLINK,
ROUTE_TYPE,
ROUTE_PROTO,
+ ROUTE_DISABLED,
__ROUTE_MAX
};
[ROUTE_ONLINK] = { .name = "onlink", .type = BLOBMSG_TYPE_BOOL },
[ROUTE_TYPE] = { .name = "type", .type = BLOBMSG_TYPE_STRING },
[ROUTE_PROTO] = { .name = "proto", .type = BLOBMSG_TYPE_STRING },
+ [ROUTE_DISABLED] = { .name = "disabled", .type = BLOBMSG_TYPE_BOOL },
};
const struct uci_blob_param_list route_attr_list = {
blobmsg_parse(route_attr, __ROUTE_MAX, tb, blobmsg_data(attr), blobmsg_data_len(attr));
+ if ((cur = tb[ROUTE_DISABLED]) != NULL && blobmsg_get_bool(cur))
+ return;
+
if (!iface) {
if ((cur = tb[ROUTE_INTERFACE]) == NULL)
return;