Commit Graph

7 Commits (master)

Author SHA1 Message Date
Richard Cochran e43a76cbe6 Convert call sites to the proper method for setting the time stamping label.
Signed-off-by: Richard Cochran <richardcochran@gmail.com>
2020-03-04 09:46:00 -08:00
Richard Cochran e4d1988f54 rtnl: Constify the public interface.
Three of the rtnl methods never modify the strings passed in.  This
patch adds the const keyword to ensure these functions stay that way.

Signed-off-by: Richard Cochran <richardcochran@gmail.com>
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
2020-03-04 09:43:37 -08:00
Miroslav Lichvar 742f878821 rtnl: remove dependency on config.h.
Change the rtnl_get_ts_label() function to accept the name of the master
interface and the buffer for the slave interface directly instead of the
struct interface from config.h.

Also, rename the function to rtnl_get_ts_device().

Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
2018-04-19 07:41:11 -07:00
Hangbin Liu 6d1e2a62bd rtnl: add function rtnl_get_ts_label to get interface ts_label info
Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
2017-10-14 05:34:18 -07:00
Hangbin Liu 80bc4d4c2f rtnl: update function rtnl_link_status to get bond slave info
Update function rtnl_link_status to get bond slave info. Pass the slave index
to call back functions. i.e. port_link_status.

Also check the interface index of rtnl message in function rtnl_link_status.
Then we don't need to check it in port_link_status.

Add ifndef IFLA_BOND_MAX in case we build linuxptp on kernel before v3.13-rc1.

Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
2017-10-14 05:34:18 -07:00
Hangbin Liu 05bba46198 rtnl: update rtgenmsg to ifinfomsg when request link info
The previous function use general message and will dump all interfaces'
information. Now update with ifinfomsg so we could get specific interface's
information.

We still could get all interfaces' info if set device to NULL.

Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
2017-10-14 05:34:18 -07:00
Richard Cochran 0b3c045a42 rtnl: Introduce RT netlink sockets.
This patch adds a source module that implements RT netlink sockets
for the purpose of link monitoring.  Unfortunately the netlink API
offers no possibility for per-port notification.  Instead it
forces us to use a de-multiplexing pattern.

Signed-off-by: Richard Cochran <richardcochran@gmail.com>
2016-10-16 12:42:56 +02:00