Commit 45ffda75 authored by Scott Feldman's avatar Scott Feldman Committed by David S. Miller

switchdev: update documentation on FDB ageing_time

Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
Reviewed-by: default avatarVivien Didelot <vivien.didelot@savoirfairelinux.com>
Acked-by: default avatarJiri Pirko <jiri@resnulli.us>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent dcd45e06
...@@ -239,20 +239,20 @@ The driver should initialize the attributes to the hardware defaults. ...@@ -239,20 +239,20 @@ The driver should initialize the attributes to the hardware defaults.
FDB Ageing FDB Ageing
^^^^^^^^^^ ^^^^^^^^^^
There are two FDB ageing models supported: 1) ageing by the device, and 2) The bridge will skip ageing FDB entries marked with NTF_EXT_LEARNED and it is
ageing by the kernel. Ageing by the device is preferred if many FDB entries the responsibility of the port driver/device to age out these entries. If the
are supported. The driver calls call_switchdev_notifiers(SWITCHDEV_FDB_DEL, port device supports ageing, when the FDB entry expires, it will notify the
...) to age out the FDB entry. In this model, ageing by the kernel should be driver which in turn will notify the bridge with SWITCHDEV_FDB_DEL. If the
turned off. XXX: how to turn off ageing in kernel on a per-port basis or device does not support ageing, the driver can simulate ageing using a
otherwise prevent the kernel from ageing out the FDB entry? garbage collection timer to monitor FBD entries. Expired entries will be
notified to the bridge using SWITCHDEV_FDB_DEL. See rocker driver for
In the kernel ageing model, the standard bridge ageing mechanism is used to age example of driver running ageing timer.
out stale FDB entries. To keep an FDB entry "alive", the driver should refresh
the FDB entry by calling call_switchdev_notifiers(SWITCHDEV_FDB_ADD, ...). The To keep an NTF_EXT_LEARNED entry "alive", the driver should refresh the FDB
entry by calling call_switchdev_notifiers(SWITCHDEV_FDB_ADD, ...). The
notification will reset the FDB entry's last-used time to now. The driver notification will reset the FDB entry's last-used time to now. The driver
should rate limit refresh notifications, for example, no more than once a should rate limit refresh notifications, for example, no more than once a
second. If the FDB entry expires, fdb_delete is called to remove entry from second. (The last-used time is visible using the bridge -s fdb option).
the device.
STP State Change on Port STP State Change on Port
^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment