summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2011-07-29 19:24:47 +0200
committerFelix Fietkau <nbd@openwrt.org>2011-07-29 19:24:47 +0200
commit3062736f3cf323e3b0f95c4c97fdcf57ab768590 (patch)
tree1446ff3e21f37eea6dd3e53d182efaa9af205bcd
parent8c7ee052813ae68490b230c657a4a36700654ce5 (diff)
s/set_device_present/device_set_present/
-rw-r--r--bridge.c6
-rw-r--r--device.c2
-rw-r--r--device.h2
-rw-r--r--system-dummy.c2
-rw-r--r--ubus.c2
-rw-r--r--vlan.c4
6 files changed, 9 insertions, 9 deletions
diff --git a/bridge.c b/bridge.c
index 6dca6e3..aff41fb 100644
--- a/bridge.c
+++ b/bridge.c
@@ -81,7 +81,7 @@ bridge_member_cb(struct device_user *dev, enum device_event ev)
if (bst->dev.active)
bridge_enable_member(bm);
else if (bst->n_present == 1)
- set_device_present(&bst->dev, true);
+ device_set_present(&bst->dev, true);
break;
case DEV_EVENT_REMOVE:
@@ -94,7 +94,7 @@ bridge_member_cb(struct device_user *dev, enum device_event ev)
bm->present = false;
bm->bst->n_present--;
if (bst->n_present == 0)
- set_device_present(&bst->dev, false);
+ device_set_present(&bst->dev, false);
break;
default:
@@ -136,7 +136,7 @@ bridge_set_up(struct bridge_state *bst)
if (!bst->n_present) {
/* initialization of all member interfaces failed */
system_bridge_delbr(&bst->dev);
- set_device_present(&bst->dev, false);
+ device_set_present(&bst->dev, false);
return -ENOENT;
}
diff --git a/device.c b/device.c
index 88b2cd0..61b50bc 100644
--- a/device.c
+++ b/device.c
@@ -239,7 +239,7 @@ void cleanup_device(struct device *dev)
avl_delete(&devices, &dev->avl);
}
-void set_device_present(struct device *dev, bool state)
+void device_set_present(struct device *dev, bool state)
{
if (dev->present == state)
return;
diff --git a/device.h b/device.h
index dd2b5ed..dd7e114 100644
--- a/device.h
+++ b/device.h
@@ -136,7 +136,7 @@ struct device *get_device(const char *name, bool create);
void device_add_user(struct device_user *dep, struct device *iface);
void device_remove_user(struct device_user *dep);
-void set_device_present(struct device *dev, bool state);
+void device_set_present(struct device *dev, bool state);
int claim_device(struct device *dev);
void release_device(struct device *dev);
int check_device_state(struct device *dev);
diff --git a/system-dummy.c b/system-dummy.c
index f24f686..80f1734 100644
--- a/system-dummy.c
+++ b/system-dummy.c
@@ -57,7 +57,7 @@ int system_if_check(struct device *dev)
dev->ifindex = 0;
if (!strcmp(dev->ifname, "eth0"))
- set_device_present(dev, true);
+ device_set_present(dev, true);
return 0;
}
diff --git a/ubus.c b/ubus.c
index 72cf0e5..2e98b2b 100644
--- a/ubus.c
+++ b/ubus.c
@@ -38,7 +38,7 @@ static int netifd_handle_device(struct ubus_context *ctx, struct ubus_object *ob
return UBUS_STATUS_NOT_FOUND;
if (!add || (tb[DEV_FORCE] && blobmsg_get_u8(tb[DEV_FORCE])))
- set_device_present(dev, add);
+ device_set_present(dev, add);
else
check_device_state(dev);
diff --git a/vlan.c b/vlan.c
index b906cd5..ce9d2d7 100644
--- a/vlan.c
+++ b/vlan.c
@@ -55,10 +55,10 @@ static void vlan_dev_cb(struct device_user *dep, enum device_event ev)
vldev = container_of(dep, struct vlan_device, dep);
switch(ev) {
case DEV_EVENT_ADD:
- set_device_present(&vldev->dev, true);
+ device_set_present(&vldev->dev, true);
break;
case DEV_EVENT_REMOVE:
- set_device_present(&vldev->dev, false);
+ device_set_present(&vldev->dev, false);
break;
default:
break;