Is there some documentation about the uci_blob_param_info
?
Currently, I look at the odhcpd and I do not understand what this .info
is doing.
enum {
IFACE_ATTR_INTERFACE,
IFACE_ATTR_IFNAME,
IFACE_ATTR_UPSTREAM,
....
}
static const struct blobmsg_policy iface_attrs[IFACE_ATTR_MAX] = {
[IFACE_ATTR_INTERFACE] = { .name = "interface", .type = BLOBMSG_TYPE_STRING },
[IFACE_ATTR_IFNAME] = { .name = "ifname", .type = BLOBMSG_TYPE_STRING },
[IFACE_ATTR_UPSTREAM] = { .name = "upstream", .type = BLOBMSG_TYPE_ARRAY }
...
};
static const struct uci_blob_param_info iface_attr_info[IFACE_ATTR_MAX] = {
[IFACE_ATTR_UPSTREAM] = { .type = BLOBMSG_TYPE_STRING },
[IFACE_ATTR_DNS] = { .type = BLOBMSG_TYPE_STRING },
[IFACE_ATTR_DOMAIN] = { .type = BLOBMSG_TYPE_STRING },
};
const struct uci_blob_param_list interface_attr_list = {
.n_params = IFACE_ATTR_MAX,
.params = iface_attrs,
.info = iface_attr_info,
};