aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJiri Pirko <jpirko@redhat.com>2012-06-19 01:54:11 -0400
committerDavid S. Miller <davem@davemloft.net>2012-06-19 18:00:23 -0400
commit0f1aad2b7f01d88782fbf4ab08b13a7d92b9b6b2 (patch)
treef37dde889cebd9168e0c8a0784d128a006367dd0 /drivers
parent85d59a87248de90e3266e10dce99477b60f524c0 (diff)
team: allow async option changes
This patch adds two exported functions. One allows to mark option instance as changed and the second processes change check and does transfer of changed options to userspace. Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/team/team.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/net/team/team.c b/drivers/net/team/team.c
index cff8e253df72..7988ba099b94 100644
--- a/drivers/net/team/team.c
+++ b/drivers/net/team/team.c
@@ -82,6 +82,7 @@ static void team_refresh_port_linkup(struct team_port *port)
82 port->state.linkup; 82 port->state.linkup;
83} 83}
84 84
85
85/******************* 86/*******************
86 * Options handling 87 * Options handling
87 *******************/ 88 *******************/
@@ -387,6 +388,22 @@ static int team_option_set(struct team *team,
387 return err; 388 return err;
388} 389}
389 390
391void team_option_inst_set_change(struct team_option_inst_info *opt_inst_info)
392{
393 struct team_option_inst *opt_inst;
394
395 opt_inst = container_of(opt_inst_info, struct team_option_inst, info);
396 opt_inst->changed = true;
397}
398EXPORT_SYMBOL(team_option_inst_set_change);
399
400void team_options_change_check(struct team *team)
401{
402 __team_options_change_check(team);
403}
404EXPORT_SYMBOL(team_options_change_check);
405
406
390/**************** 407/****************
391 * Mode handling 408 * Mode handling
392 ****************/ 409 ****************/
@@ -2051,6 +2068,7 @@ static void team_port_change_check(struct team_port *port, bool linkup)
2051 mutex_unlock(&team->lock); 2068 mutex_unlock(&team->lock);
2052} 2069}
2053 2070
2071
2054/************************************ 2072/************************************
2055 * Net device notifier event handler 2073 * Net device notifier event handler
2056 ************************************/ 2074 ************************************/