summaryrefslogtreecommitdiffstats
path: root/include/netlink/route/link
Commit message (Collapse)AuthorAgeFilesLines
* lib/route: add support for bridge mstiRonan Dalton2024-10-101-0/+7
| | | | https://github.com/thom311/libnl/pull/409
* lib/route: add support for bridge info booloptsRonan Dalton2024-09-181-0/+5
| | | | Add support for the IFLA_BR_MULTI_BOOLOPT bridge link attribute.
* lib/route: extend bridge info supportRonan Dalton2024-09-161-0/+15
| | | | | | | | Add support for the following attributes for bridge links: IFLA_BR_STP_STATE IFLA_BR_MCAST_ROUTER IFLA_BR_MCAST_SNOOPING
* lib/route: add missing bridge info getter functionsRonan Dalton2024-09-161-0/+9
| | | | | | There are bridge info setter functions for nf_call_iptables, nf_call_ip6tables and nf_call_arptables, but no corresponding getter functions, so add them.
* lib/route: extend bridge flagsRonan Dalton2024-09-121-7/+18
| | | | | | | | | | | | | | | | | | Add support for the following bridge flags: IFLA_BRPORT_PROXYARP IFLA_BRPORT_PROXYARP_WIFI IFLA_BRPORT_MCAST_FLOOD IFLA_BRPORT_MCAST_TO_UCAST IFLA_BRPORT_VLAN_TUNNEL IFLA_BRPORT_BCAST_FLOOD IFLA_BRPORT_NEIGH_SUPPRESS IFLA_BRPORT_ISOLATED IFLA_BRPORT_LOCKED IFLA_BRPORT_MAB IFLA_BRPORT_NEIGH_VLAN_SUPPRESS https://github.com/thom311/libnl/pull/403
* link/bonding: add getters for attributesJonas Gorski2024-08-271-3/+12
| | | | | | | In preparation of parsing bond link attributes, add getters for all supported attributes. Signed-off-by: Jonas Gorski <jonas.gorski@bisdn.de>
* include: add _NL_NO_WARN_DEPRECATED_HEADER for suppressing warning about ↵Thomas Haller2024-05-062-0/+4
| | | | | | | | | | | | | | | | deprecated headers Header files are part of a stable API. Warning about using deprecated API is cumbersome, albeit often useful to force the user to migrate away from the API. But it also requires that the unit test disables "-Wcpp". That is problematic on its own, because we don't want to disable any warnings. As we only have 4 such header files, instead guard the warnings with a #ifndef _NL_NO_WARN_DEPRECATED_HEADER
* route: add support for layer 3 filtering on bridgesCordell O'Leary2024-04-031-0/+6
| | | | https://github.com/thom311/libnl/pull/373
* route: add support for vlan filtering on bridge ports.Cordell O'Leary2024-02-292-0/+10
|
* route: Add support to set ageing time for dynamic bridge table entriesCordell O'Leary2024-02-291-0/+5
|
* route/can: implement can_device_statsJob Feikens2023-12-011-0/+3
| | | | | | | Adds the rtnl_link_can_get_device_stats function to get xstats of a CAN-bus link as a can_device_stats struct. https://github.com/thom311/libnl/pull/368
* route/link: add bonding interface options set rtnl apisLokesh Dhoundiyal2023-10-301-0/+3
| | | | | | | [thaller@redhat.com: fixed wrong variable name in code and reworded commit message.] https://github.com/thom311/libnl/pull/363
* include: make "netlink/route/link/{inet,inet6}.h" self-containedThomas Haller2023-08-022-0/+2
|
* route/bond: Add support for link_info for bondMallikarjun Nemagoudar2023-07-271-0/+3
| | | | | | | | | | | | | following API has been added to bonding bond_alloc bond_free rtnl_link_bond_set_activeslave rtnl_link_bond_set_mode bond_put_attrs Signed-off-by: Mallikarjun Nemagoudar <MallikarjunRamappa.Nemagoudar@infineon.com> https://github.com/thom311/libnl/pull/349
* route/link: remove rtnl_link_inet6_set_conf() APIThomas Haller2023-07-241-4/+0
| | | | | | | | | | | | | | It's not clear how this API is useful. I don't think that kernel accepts netlink requests to change the settings. So constructing a libnl3 object in the user application seems not useful. Also, because of the difficulty that DEVCONF_MAX is depending on the current kernel, and changing. We need to improve how to handle the option, and a rtnl_link_inet6_set_conf() only makes that more confusing. The same is the case for rtnl_link_inet6_set_flags(), but that API already exists, while rtnl_link_inet6_set_conf() is still new and unreleased.
* route/link: various fixes for rtnl_link_inet6_get_conf() APIThomas Haller2023-07-241-2/+2
|
* route/link: add accessor API for IPv6 DEVCONFAbdurrahman Hussain2023-03-291-0/+8
| | | | Signed-off-by: Abdurrahman Hussain <abdurrahman@hussain.rocks>
* bridge: use SPDX license identifiers in bridge_info filesThomas Haller2022-08-241-7/+1
|
* bridge: reformat bridge_info file with clang-formatThomas Haller2022-08-241-8/+14
|
* bridge: extend libnl with options needed for VLAN aware forwardingRobert Dabrowski2022-08-241-0/+35
| | | | | | Signed-off-by: Robert Dabrowski <rdabrowski@maxlinear.com> Co-Authored-By: Kacper Ludwinski <kludwinski@maxlinear.com>
* route: make argument of rtnl_link_can_set_{bittiming,data_bittiming}() constThomas Haller2022-03-151-2/+2
| | | | | | The argument of the setters does not get modified. Make it const. This change does not break API/ABI.
* route: add rtnl_link_can_set_data_bittiming_const()Thomas Haller2022-03-151-0/+2
| | | | | In can_put_attrs(), we also put ci_data_bittiming_const. It is thus necessary to be able to set it.
* route: drop bitrate,sample-point getters/setters from can linkThomas Haller2022-03-151-6/+0
| | | | | | | | | | | | | | These accessor functions just get/set a field of ci_data_bittiming, which can already be get/set as a whole. It seems redundant, so drop it. It's really important that things are principle at all (like, setting ci_data_bittiming). It's not clear that we need such convenience functions, if you can achieve the same result otherwise. Yes, we have similar accessors already. I think that is not a good approach though. If they turn out very useful, we can still revert this patch.
* route: rename rtnl_link_can_get_data_bt_const() to ↵Thomas Haller2022-03-151-2/+2
| | | | | | rtnl_link_can_get_data_bittiming_const() It seems more consistent with the other names.
* route: fix indentationThomas Haller2022-03-151-6/+6
|
* route/link: add CAN FD supportAnders Piniesjö2022-03-151-0/+13
| | | | | | | Add CAN FD support analog to the normal CAN support. [thaller@redhat.com: second part of original commit. The first part was merged as commit 5d925168a459]
* license: use SPDX license identifiers and drop license commentsThomas Haller2022-03-111-8/+1
|
* ip6vti: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* ip6gre: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* sit: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* ipip: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* ip6_tnl: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* ipvti: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* ipgre: Add fwmark APIThomas Winter2022-03-111-0/+3
| | | | | | This is a new option that was added in Linux v4.12. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* ip6vti: Add IPv6 VTI supportThomas Winter2022-03-111-0/+44
| | | | | | | This patch adds support for IPv6 VTI tunneling that uses the vti6 kernel module. Signed-off-by: Thomas Winter <Thomas.Winter@alliedtelesis.co.nz>
* license: use SPDX license identifiers and drop license commentsThomas Haller2022-03-112-15/+2
|
* route/link: add support for team deviceJonas Johansson2022-03-101-0/+32
| | | | Signed-off-by: Jonas Johansson <jonas.johansson@westermo.se>
* route/link: Add IPv6 GRE supportScott Parlane2022-03-091-0/+62
| | | | | | | This patch adds support for IPv6 GRE tunneling that uses the ip6_gre kernel module. https://github.com/thom311/libnl/pull/255
* Supporting Hardware offload capability for MACsecJohan Alexis Duque Cadena2022-03-031-0/+3
| | | | | | [thaller@redhat.com: adjust libnl-route-3.sym file] https://github.com/thom311/libnl/pull/300
* license: fix and add SPDX license identifiers and drop license commentsThomas Haller2020-04-1624-169/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also fixes a few wrong SPDX license identifiers, where the original license comment indicates GPL-2.0-only. This is not done manually, but by running the following script: --- #!/bin/bash # Tool to drop license comments, adding SPDX license identifiers, while preserving # copyright comments. The point is not to manually do this task, but perform some # hacked up string replacement. _cp() { /bin/cp "$@" } _cat() { /bin/cat "$@" } in_file() { local T=$(mktemp) _cp -f "$1" "$T" _cat "$T" rm -f "$T" } out_file() { local T=$(mktemp) _cat - > "$T" _cp -f "$T" "$1" rm -f "$T" } join() { _cat "$@" | awk '{ printf("%s#x#", $0)}' } unjoin() { _cat - | sed 's/#x#/\n/g' } files_all() { git ls-files | grep -v '\.png$' | grep -v '^include/linux-private/' } adjust() { NEWLINES='\(#x#\)\+' COPYRIGHTS='\(\( \* Copyright (c) 20..\(-20..\|, 20..\)\? [^#]\+#x#\)\+\( \*#x# \* \(Stolen[^#]*\|Based on [^#]*\)#x#\)\?\)' _cat - | \ sed '1s%^\(/\* SPDX-License-Identifier: LGPL-2.1-only \*/\|\)#x#/\*#x# \* [^#]*#x# \*#x# \*[ ]\+This library is free software; you can redistribute it and/or#x# \*[ ]\+modify it under the terms of the GNU Lesser General Public#x# \*[ ]\+License as published by the Free Software Foundation version 2.1#x# \*[ ]\+of the License.#x# \*#x#'"$COPYRIGHTS"' \*/'"$NEWLINES"'%/\* SPDX-License-Identifier: LGPL-2.1-only \*/#x#/*#x#\2 */#x##x#%' | \ sed '1s%^/\*#x# \* [^#]*#x# \*#x# \*[ ]\+This library is free software; you can redistribute it and/or#x# \*[ ]\+modify it under the terms of the GNU Lesser General Public#x# \*[ ]\+License as published by the Free Software Foundation version 2.1#x# \*[ ]\+of the License.#x# \*/'"$NEWLINES"'%/\* SPDX-License-Identifier: LGPL-2.1-only \*/#x##x#%' | \ sed '1s%^\(\)/\*#x# \* [^#]*#x# \*#x# \*[ ]\+This library is free software; you can redistribute it and/or#x# \*[ ]\+modify it under the terms of the GNU Lesser General Public#x# \*[ ]\+License as published by the Free Software Foundation version 2.1#x# \*[ ]\+of the License.#x# \*#x#'"$COPYRIGHTS"' \*/'"$NEWLINES"'%/\* SPDX-License-Identifier: LGPL-2.1-only \*/#x#/*#x#\2 */#x##x#%' | \ sed '1s%^\(/\* SPDX-License-Identifier: LGPL-2.1-only \*/\|\)#x#/\*#x# \* [^#]*#x# \*#x# \*[ ]\+This library is free software; you can redistribute it and/or#x# \*[ ]\+modify it under the terms of the GNU General Public License as#x# \*[ ]\+published by the Free Software Foundation version 2 of the License.#x# \*#x#'"$COPYRIGHTS"' \*/'"$NEWLINES"'%/\* SPDX-License-Identifier: GPL-2.0-only \*/#x#/*#x#\2 */#x##x#%' } FILES=( $(files_all) ) for f in "${FILES[@]}"; do echo "processing \"$f\"..." in_file "$f" | join | adjust | unjoin | out_file "$f" done
* license: cleanup copyright commentsThomas Haller2020-04-161-0/+1
| | | | Manually make copyright comments in a consistent format.
* xfrmi: return error code from getters for XFRM linksThomas Haller2019-09-011-2/+2
| | | | | | | | Returning the value directly as uint32_t does not leave room for an error code. E.g. we want to indicate to the caller whether the attribute is present or not (-NLE_NOATTR). Currenlty, the code is quite unforgiving and will just crash/assert against invalid arguments. In theory, we could also be more forgiving and return a error code if the link argument is invalid.
* xfrmi: introduce XFRM interfaces supportEyal Birger2019-09-011-0/+37
| | | | | | | XFRM interfaces were introduced in kernel 4.19. This commit adds link support for these interfaces. Signed-off-by: Eyal Birger <eyal.birger@gmail.com>
* lib/rtnl: rename public define RTNL_GENEVE_ID_MAXThomas Haller2018-02-121-1/+1
| | | | | Public defines must have a libnl3 related prefix. Rename GENEVE_ID_MAX to RTNL_GENEVE_ID_MAX.
* link: add Geneve support.Wang Jian2018-02-121-0/+60
| | | | Signed-off-by: Wang Jian <jianjian.wang1@gmail.com>
* route/link: add accessor API for IPv6 flagsMarkus Trapp2017-05-031-0/+10
| | | | | | | | Add functions to access the IPv6 specific flags of a link object. Also the functions for IPv6 link flags translation are now exported, similar to the non IPv6 specific translation functions. https://github.com/thom311/libnl/pull/136
* include: restore linux header includes in public headersThomas Haller2017-03-022-0/+3
| | | | | | | | | The previous commits reorganized the public headers to drop includes of linux kernel headers. Restore the previous situation because otherwise the change might break compilation for users who rely on certain headers getting dragged in by libnl3.
* include: don't include kernel headers in public libnl3 headersThomas Haller2017-03-023-3/+8
| | | | | | | | | | | | | | | | | It would be desirable not to include kernel headers in our public libnl3 headers. As a test, remove all those includes, and fix compilation by explicitly including the kernel headers where needed. In some cases, that requires forward declaration for kernel structures, as we use them as part of our own headers. Realistically, we cannot drop those includes as it probalby breaks compilation for users that expect to get a certain kernel header when including a libnl3 header. So, this will not be done and the includes will be restored in the next commit. Do this step to show how it would be and to verify that we could build with such a change. The reason not to do this is backward compatibility (at compile-time).
* link/sit: Add missing prototype for rtnl_link_is_sit()Tobias Klauser2017-01-201-0/+2
| | | | | | | | | | | Add the function prototype for rtnl_link_is_ipip() to the public header. This fixes the following GCC warning when compiling with -Wmissing-prototypes: route/link/sit.c:400:5: warning: no previous prototype for ‘rtnl_link_is_sit’ [-Wmissing-prototypes] Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
* link/ipvti: Fix and add function prototypes in public headerTobias Klauser2017-01-201-4/+6
| | | | | | | | | | | | | | | | | | | Add missing "_ipvti" part to function prototypes so they match the exported name. Also add the missing prototype for rtnl_link_is_ipvti(). This fixes the following GCC warnings when compiling with -Wmissing-prototypes: route/link/ipvti.c:281:5: warning: no previous prototype for ‘rtnl_link_is_ipvti’ [-Wmissing-prototypes] route/link/ipvti.c:369:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_ikey’ [-Wmissing-prototypes] route/link/ipvti.c:403:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_okey’ [-Wmissing-prototypes] route/link/ipvti.c:437:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_local’ [-Wmissing-prototypes] route/link/ipvti.c:471:10: warning: no previous prototype for ‘rtnl_link_ipvti_get_remote’ [-Wmissing-prototypes] Also fix the corresponding names in documentation. Fixes: 8f6301426a00 ("ipvti: introduce vti tunnel support") Signed-off-by: Tobias Klauser <tklauser@distanz.ch>