net: dsa: add notifier for ageing time
This patch keeps the port-wide ageing time handling code in dsa_port_ageing_time, pushes the requested ageing time value in a new switch fabric notification, and moves the switch-wide ageing time handling code in dsa_switch_ageing_time. This has the effect that now not only the switch that the target port belongs to can be programmed, but all switches composing the switch fabric. For the moment, keep the current behavior and ignore other switches. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
52c96f9d70
commit
1faabf7440
@@ -17,10 +17,18 @@
|
||||
#include <net/dsa.h>
|
||||
|
||||
enum {
|
||||
DSA_NOTIFIER_AGEING_TIME,
|
||||
DSA_NOTIFIER_BRIDGE_JOIN,
|
||||
DSA_NOTIFIER_BRIDGE_LEAVE,
|
||||
};
|
||||
|
||||
/* DSA_NOTIFIER_AGEING_TIME */
|
||||
struct dsa_notifier_ageing_time_info {
|
||||
struct switchdev_trans *trans;
|
||||
unsigned int ageing_time;
|
||||
int sw_index;
|
||||
};
|
||||
|
||||
/* DSA_NOTIFIER_BRIDGE_* */
|
||||
struct dsa_notifier_bridge_info {
|
||||
struct net_device *br;
|
||||
|
Reference in New Issue
Block a user