diff options
| author | Vivien Didelot <vivien.didelot@savoirfairelinux.com> | 2017-11-06 16:11:53 -0500 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2017-11-08 19:26:49 -0500 |
| commit | b4fbb347fe4cd7988d0f9453a7e3ab0cd1b4a75a (patch) | |
| tree | 4595fb0d4562f8344212e3f0c2842d5ab8a63cfb /net/dsa | |
| parent | 308173546ac4342103541e8d4e4ce83d1a5e7eba (diff) | |
net: dsa: rename probe and remove switch functions
This commit brings no functional changes. It gets rid of the underscore
prefixed _dsa_register_switch and _dsa_unregister_switch functions in
favor of dsa_switch_probe() which parses and adds a switch to a tree and
dsa_switch_remove() which removes a switch from a tree.
Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa')
| -rw-r--r-- | net/dsa/dsa2.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/dsa/dsa2.c b/net/dsa/dsa2.c index 3db50e68640e..fd54a8e17986 100644 --- a/net/dsa/dsa2.c +++ b/net/dsa/dsa2.c | |||
| @@ -718,7 +718,7 @@ static int dsa_switch_add(struct dsa_switch *ds) | |||
| 718 | return dsa_tree_add_switch(dst, ds); | 718 | return dsa_tree_add_switch(dst, ds); |
| 719 | } | 719 | } |
| 720 | 720 | ||
| 721 | static int _dsa_register_switch(struct dsa_switch *ds) | 721 | static int dsa_switch_probe(struct dsa_switch *ds) |
| 722 | { | 722 | { |
| 723 | struct dsa_chip_data *pdata = ds->dev->platform_data; | 723 | struct dsa_chip_data *pdata = ds->dev->platform_data; |
| 724 | struct device_node *np = ds->dev->of_node; | 724 | struct device_node *np = ds->dev->of_node; |
| @@ -764,14 +764,14 @@ int dsa_register_switch(struct dsa_switch *ds) | |||
| 764 | int err; | 764 | int err; |
| 765 | 765 | ||
| 766 | mutex_lock(&dsa2_mutex); | 766 | mutex_lock(&dsa2_mutex); |
| 767 | err = _dsa_register_switch(ds); | 767 | err = dsa_switch_probe(ds); |
| 768 | mutex_unlock(&dsa2_mutex); | 768 | mutex_unlock(&dsa2_mutex); |
| 769 | 769 | ||
| 770 | return err; | 770 | return err; |
| 771 | } | 771 | } |
| 772 | EXPORT_SYMBOL_GPL(dsa_register_switch); | 772 | EXPORT_SYMBOL_GPL(dsa_register_switch); |
| 773 | 773 | ||
| 774 | static void _dsa_unregister_switch(struct dsa_switch *ds) | 774 | static void dsa_switch_remove(struct dsa_switch *ds) |
| 775 | { | 775 | { |
| 776 | struct dsa_switch_tree *dst = ds->dst; | 776 | struct dsa_switch_tree *dst = ds->dst; |
| 777 | unsigned int index = ds->index; | 777 | unsigned int index = ds->index; |
| @@ -782,7 +782,7 @@ static void _dsa_unregister_switch(struct dsa_switch *ds) | |||
| 782 | void dsa_unregister_switch(struct dsa_switch *ds) | 782 | void dsa_unregister_switch(struct dsa_switch *ds) |
| 783 | { | 783 | { |
| 784 | mutex_lock(&dsa2_mutex); | 784 | mutex_lock(&dsa2_mutex); |
| 785 | _dsa_unregister_switch(ds); | 785 | dsa_switch_remove(ds); |
| 786 | mutex_unlock(&dsa2_mutex); | 786 | mutex_unlock(&dsa2_mutex); |
| 787 | } | 787 | } |
| 788 | EXPORT_SYMBOL_GPL(dsa_unregister_switch); | 788 | EXPORT_SYMBOL_GPL(dsa_unregister_switch); |
