projects
/
project
/
netifd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
interface: fix regression on adding hotplug devices to interfaces
[project/netifd.git]
/
vlandev.c
diff --git
a/vlandev.c
b/vlandev.c
index d93d2b3c5aab459afba9e17f0d51ec98ef5ef6c5..4d6e76a75e43230f646170eb0dd7b19b069412ec 100644
(file)
--- a/
vlandev.c
+++ b/
vlandev.c
@@
-72,7
+72,9
@@
__vlandev_hotplug_op(struct device *dev, struct device *member, struct blob_attr
blob_buf_init(&b, 0);
a = blobmsg_open_array(&b, "vlans");
blob_buf_init(&b, 0);
a = blobmsg_open_array(&b, "vlans");
- blobmsg_printf(&b, NULL, "%d", mvdev->config.vid);
+ blobmsg_printf(&b, NULL, "%d:u", mvdev->config.vid);
+ if (vlan && blobmsg_len(vlan))
+ blob_put_raw(&b, blobmsg_data(vlan), blobmsg_len(vlan));
blobmsg_close_array(&b, a);
if (add)
blobmsg_close_array(&b, a);
if (add)
@@
-189,7
+191,7
@@
vlandev_set_state(struct device *dev, bool up)
{
struct vlandev_device *mvdev;
{
struct vlandev_device *mvdev;
- D(SYSTEM, "vlandev_set_state(%s, %u)
\n
", dev->ifname, up);
+ D(SYSTEM, "vlandev_set_state(%s, %u)", dev->ifname, up);
mvdev = container_of(dev, struct vlandev_device, dev);
if (up)
mvdev = container_of(dev, struct vlandev_device, dev);
if (up)
@@
-288,7
+290,8
@@
static void vlandev_qos_mapping_list_apply(struct vlist_simple_tree *qos_mapping
{
struct blob_attr *cur;
struct vlan_qos_mapping *qos_mapping;
{
struct blob_attr *cur;
struct vlan_qos_mapping *qos_mapping;
- int rem, rc;
+ size_t rem;
+ int rc;
blobmsg_for_each_attr(cur, list, rem) {
if (blobmsg_type(cur) != BLOBMSG_TYPE_STRING)
blobmsg_for_each_attr(cur, list, rem) {
if (blobmsg_type(cur) != BLOBMSG_TYPE_STRING)