diff options
author | Hans Dedecker <dedeckeh@gmail.com> | 2018-11-17 18:41:16 +0100 |
---|---|---|
committer | Hans Dedecker <dedeckeh@gmail.com> | 2018-11-19 09:02:29 +0100 |
commit | 70506bf09b8ef971ae90155bc86ef3e9bed6785f (patch) | |
tree | a429f5c7443721e53ce6a8dd7a118a70f6c70088 | |
parent | d9872db72eb63e9fa454446756e10fc7c52effc5 (diff) |
treewide: make some functions static
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
-rw-r--r-- | bridge.c | 4 | ||||
-rw-r--r-- | device.c | 2 | ||||
-rw-r--r-- | device.h | 1 | ||||
-rw-r--r-- | interface-ip.c | 2 | ||||
-rw-r--r-- | interface-ip.h | 1 | ||||
-rw-r--r-- | interface.c | 6 | ||||
-rw-r--r-- | interface.h | 2 |
7 files changed, 7 insertions, 11 deletions
@@ -77,7 +77,7 @@ static struct device *bridge_create(const char *name, struct device_type *devtyp static void bridge_config_init(struct device *dev); static void bridge_free(struct device *dev); static void bridge_dump_info(struct device *dev, struct blob_buf *b); -enum dev_change_type +static enum dev_change_type bridge_reload(struct device *dev, struct blob_attr *attr); static struct device_type bridge_device_type = { @@ -633,7 +633,7 @@ bridge_apply_settings(struct bridge_state *bst, struct blob_attr **tb) cfg->bridge_empty = blobmsg_get_bool(cur); } -enum dev_change_type +static enum dev_change_type bridge_reload(struct device *dev, struct blob_attr *attr) { struct blob_attr *tb_dev[__DEV_ATTR_MAX]; @@ -733,7 +733,7 @@ void device_add_user(struct device_user *dep, struct device *dev) __device_add_user(dep, dev); } -void +static void device_free(struct device *dev) { __devlock++; @@ -269,7 +269,6 @@ void device_release(struct device_user *dep); int device_check_state(struct device *dev); void device_dump_status(struct blob_buf *b, struct device *dev); -void device_free(struct device *dev); void device_free_unused(struct device *dev); struct device *get_vlan_device_chain(const char *ifname, bool create); diff --git a/interface-ip.c b/interface-ip.c index b7c1807..9cea0a6 100644 --- a/interface-ip.c +++ b/interface-ip.c @@ -1176,7 +1176,7 @@ interface_ip_set_ula_prefix(const char *prefix) } } -void +static void interface_add_dns_server(struct interface_ip_settings *ip, const char *str) { struct dns_server *s; diff --git a/interface-ip.h b/interface-ip.h index 197bd9a..5374d93 100644 --- a/interface-ip.h +++ b/interface-ip.h @@ -153,7 +153,6 @@ extern const struct uci_blob_param_list route_attr_list; extern struct list_head prefixes; void interface_ip_init(struct interface *iface); -void interface_add_dns_server(struct interface_ip_settings *ip, const char *str); void interface_add_dns_server_list(struct interface_ip_settings *ip, struct blob_attr *list); void interface_add_dns_search_list(struct interface_ip_settings *ip, struct blob_attr *list); void interface_write_resolv_conf(void); diff --git a/interface.c b/interface.c index 4a09a22..041f0a5 100644 --- a/interface.c +++ b/interface.c @@ -78,7 +78,7 @@ const struct uci_blob_param_list interface_attr_list = { }; static void -set_config_state(struct interface *iface, enum interface_config_state s); +interface_set_main_dev(struct interface *iface, struct device *dev); static void interface_event(struct interface *iface, enum interface_event ev); @@ -964,7 +964,7 @@ interface_set_l3_dev(struct interface *iface, struct device *dev) } } -void +static void interface_set_main_dev(struct interface *iface, struct device *dev) { bool claimed = iface->l3_dev.claimed; @@ -988,7 +988,7 @@ interface_set_main_dev(struct interface *iface, struct device *dev) interface_set_l3_dev(iface, dev); } -int +static int interface_remove_link(struct interface *iface, struct device *dev) { struct device *mdev = iface->main_dev.dev; diff --git a/interface.h b/interface.h index f92a35e..098e0fc 100644 --- a/interface.h +++ b/interface.h @@ -186,13 +186,11 @@ void interface_set_up(struct interface *iface); void interface_set_down(struct interface *iface); int interface_renew(struct interface *iface); -void interface_set_main_dev(struct interface *iface, struct device *dev); void interface_set_l3_dev(struct interface *iface, struct device *dev); void interface_add_user(struct interface_user *dep, struct interface *iface); void interface_remove_user(struct interface_user *dep); -int interface_remove_link(struct interface *iface, struct device *dev); int interface_handle_link(struct interface *iface, const char *name, bool add, bool link_ext); void interface_add_error(struct interface *iface, const char *subsystem, |