#
b4c94968 |
| 20-Jan-2024 |
Gordon Bergling <gbe@FreeBSD.org> |
if_llatbl: Fix a typo in a KASSERT message
- s/entires/entries/
MFC after: 5 days
|
Revision tags: release/14.0.0 |
|
#
6e281255 |
| 17-Oct-2023 |
R. Christian McDonald <rcm@rcm.sh> |
lltable: fix ddb show llentry l3_addr pretty printer
The ddb commands for lltable do not produce useful l3_addr information.
This fixes the llentry pretty printer to correctly display the l3_addr
lltable: fix ddb show llentry l3_addr pretty printer
The ddb commands for lltable do not produce useful l3_addr information.
This fixes the llentry pretty printer to correctly display the l3_addr
Reviewed by: kp Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D42253
show more ...
|
#
685dc743 |
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
#
4d846d26 |
| 10-May-2023 |
Warner Losh <imp@FreeBSD.org> |
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause.
Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
show more ...
|
#
20b6945c |
| 26-Apr-2023 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
netlink: fix IPv6 proxy ndp deletion.
* Move LLT_ADDEDPROXY handling into lltable_link_entry() to reduct duplication * Use standard lltable_delete_addr() for entry deletion * Add (forgotten) call t
netlink: fix IPv6 proxy ndp deletion.
* Move LLT_ADDEDPROXY handling into lltable_link_entry() to reduct duplication * Use standard lltable_delete_addr() for entry deletion * Add (forgotten) call to llt_post_resolved handler after adding the entry via netlink.
MFC after: 2 weeks
show more ...
|
Revision tags: release/13.2.0 |
|
#
2c2b37ad |
| 13-Jan-2023 |
Justin Hibbits <jhibbits@FreeBSD.org> |
ifnet/API: Move struct ifnet definition to a <net/if_private.h>
Hide the ifnet structure definition, no user serviceable parts inside, it's a netstack implementation detail. Include it temporarily
ifnet/API: Move struct ifnet definition to a <net/if_private.h>
Hide the ifnet structure definition, no user serviceable parts inside, it's a netstack implementation detail. Include it temporarily in <net/if_var.h> until all drivers are updated to use the accessors exclusively.
Reviewed by: glebius Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D38046
show more ...
|
Revision tags: release/12.4.0 |
|
#
4f493559 |
| 04-Jun-2022 |
Gordon Bergling <gbe@FreeBSD.org> |
if_llatbl: Fix a typo in a debug statement
- s/droped/dropped/
Obtained from: NetBSD MFC after: 3 days
|
#
d18b4bec |
| 31-May-2022 |
Arseny Smalyuk <smalukav@gmail.com> |
netinet6: Fix mbuf leak in NDP
Mbufs leak when manually removing incomplete NDP records with pending packet via ndp -d. It happens because lltable_drop_entry_queue() rely on `la_numheld` counter whe
netinet6: Fix mbuf leak in NDP
Mbufs leak when manually removing incomplete NDP records with pending packet via ndp -d. It happens because lltable_drop_entry_queue() rely on `la_numheld` counter when dropping NDP entries (lles). It turned out NDP code never increased `la_numheld`, so the actual free never happened.
Fix the issue by introducing unified lltable_append_entry_queue(), common for both ARP and NDP code, properly addressing packet queue maintenance.
Reviewed By: melifaro Differential Revision: https://reviews.freebsd.org/D35365 MFC after: 2 weeks
show more ...
|
#
d6cd20cc |
| 30-May-2022 |
KUROSAWA Takahiro <takahiro.kurosawa@gmail.com> |
netinet6: fix ndp proxying
We could insert proxy NDP entries by the ndp command, but the host with proxy ndp entries had not responded to Neighbor Solicitations. Change the following points for prox
netinet6: fix ndp proxying
We could insert proxy NDP entries by the ndp command, but the host with proxy ndp entries had not responded to Neighbor Solicitations. Change the following points for proxy NDP to work as expected: * join solicited-node multicast addresses for proxy NDP entries in order to receive Neighbor Solicitations. * look up proxy NDP entries not on the routing table but on the link-level address table when receiving Neighbor Solicitations.
Reviewed By: melifaro Differential Revision: https://reviews.freebsd.org/D35307 MFC after: 2 weeks
show more ...
|
#
77001f9b |
| 30-May-2022 |
KUROSAWA Takahiro <takahiro.kurosawa@gmail.com> |
lltable: introduce the llt_post_resolved callback
In order to decrease ifdef INET/INET6s in the lltable implementation, introduce the llt_post_resolved callback and implement protocol-dependent code
lltable: introduce the llt_post_resolved callback
In order to decrease ifdef INET/INET6s in the lltable implementation, introduce the llt_post_resolved callback and implement protocol-dependent code in the protocol-dependent part.
Reviewed By: melifaro Differential Revision: https://reviews.freebsd.org/D35322 MFC after: 2 weeks
show more ...
|
Revision tags: release/13.1.0 |
|
#
990a6d18 |
| 08-Apr-2022 |
Mark Johnston <markj@FreeBSD.org> |
net: Fix memory leaks in lltable_calc_llheader() error paths
Also convert raw epoch_call() calls to lltable_free_entry() calls, no functional change intended. There's no need to asynchronously free
net: Fix memory leaks in lltable_calc_llheader() error paths
Also convert raw epoch_call() calls to lltable_free_entry() calls, no functional change intended. There's no need to asynchronously free the LLEs in that case to begin with, but we might as well use the lltable interfaces consistently.
Noticed by code inspection; I believe lltable_calc_llheader() failures do not generally happen in practice.
Reviewed by: bz MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D34832
show more ...
|
#
a6668e31 |
| 02-Jan-2022 |
Ed Maste <emaste@FreeBSD.org> |
Fix kernel build without INET and INET6
Reviewed by: brooks, melifaro Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D33718
|
#
818952c6 |
| 30-Dec-2021 |
Ed Maste <emaste@FreeBSD.org> |
Fix kernel build without INET6
Reported by: Gary Jennejohn Fixes: ff3a85d32411 ("[lltable] Add per-family lltable ...") Sponsored by: The FreeBSD Foundation
|
#
63f7f392 |
| 26-Dec-2021 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
routing: Add unified level-based logging support for the routing subsystem.
Summary: MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D33664
|
#
ff3a85d3 |
| 26-Dec-2021 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
[lltable] Add per-family lltable getters.
Introduce a new function, lltable_get(), to retrieve lltable pointer for the specified interface and family. Use it to avoid all-iftable list traversal whe
[lltable] Add per-family lltable getters.
Introduce a new function, lltable_get(), to retrieve lltable pointer for the specified interface and family. Use it to avoid all-iftable list traversal when adding or deleting ARP/ND records.
Differential Revision: https://reviews.freebsd.org/D33660 MFC after: 2 weeks
show more ...
|
Revision tags: release/12.3.0 |
|
#
c541bd36 |
| 21-Aug-2021 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
lltable: Add support for "child" LLEs holding encap for IPv4oIPv6 entries.
Currently we use pre-calculated headers inside LLE entries as prepend data for `if_output` functions. Using these headers
lltable: Add support for "child" LLEs holding encap for IPv4oIPv6 entries.
Currently we use pre-calculated headers inside LLE entries as prepend data for `if_output` functions. Using these headers allows saving some CPU cycles/memory accesses on the fast path.
However, this approach makes adding L2 header for IPv4 traffic with IPv6 nexthops more complex, as it is not possible to store multiple pre-calculated headers inside lle. Additionally, the solution space is limited by the fact that PCB caching saves LLEs in addition to the nexthop.
Thus, add support for creating special "child" LLEs for the purpose of holding custom family encaps and store mbufs pending resolution. To simplify handling of those LLEs, store them in a linked-list inside a "parent" (e.g. normal) LLE. Such LLEs are not visible when iterating LLE table. Their lifecycle is bound to the "parent" LLE - it is not possible to delete "child" when parent is alive. Furthermore, "child" LLEs are static (RTF_STATIC), avoding complex state machine used by the standard LLEs.
nd6_lookup() and nd6_resolve() now accepts an additional argument, family, allowing to return such child LLEs. This change uses `LLE_SF()` macro which packs family and flags in a single int field. This is done to simplify merging back to stable/. Once this code lands, most of the cases will be converted to use a dedicated `family` parameter.
Differential Revision: https://reviews.freebsd.org/D31379 MFC after: 2 weeks
show more ...
|
#
0b79b007 |
| 06-Aug-2021 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
[lltable] Restructure nd6 code.
Factor out lltable locking logic from lltable_try_set_entry_addr() into a separate lltable_acquire_wlock(), so the latter can be used in other parts of the code w/o
[lltable] Restructure nd6 code.
Factor out lltable locking logic from lltable_try_set_entry_addr() into a separate lltable_acquire_wlock(), so the latter can be used in other parts of the code w/o duplication.
Create nd6_try_set_entry_addr() to avoid code duplication in nd6.c and nd6_nbr.c.
Move lle creation logic from nd6_resolve_slow() into a separate nd6_get_llentry() to simplify the former.
These changes serve as a pre-requisite for implementing RFC8950 (IPv4 prefixes with IPv6 nexthops).
Differential Revision: https://reviews.freebsd.org/D31432 MFC after: 2 weeks
show more ...
|
#
f3a3b061 |
| 03-Aug-2021 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
[lltable] Unify datapath feedback mechamism.
Use newly-create llentry_request_feedback(), llentry_mark_used() and llentry_get_hittime() to request datapatch usage check and fetch the results in t
[lltable] Unify datapath feedback mechamism.
Use newly-create llentry_request_feedback(), llentry_mark_used() and llentry_get_hittime() to request datapatch usage check and fetch the results in the same fashion both in IPv4 and IPv6.
While here, simplify llentry_provide_feedback() wrapper by eliminating 1 condition check.
MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D31390
show more ...
|
Revision tags: release/13.0.0 |
|
#
e5b394f2 |
| 20-Feb-2021 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
Fix setting static entries for arp/ndp.
rtsock message validation changes committed in 2fe5a79425c7 did not take llinfo messages into account.
Add a special validation case for RTA_GATEWAY llinfo
Fix setting static entries for arp/ndp.
rtsock message validation changes committed in 2fe5a79425c7 did not take llinfo messages into account.
Add a special validation case for RTA_GATEWAY llinfo messages.
MFC after: 2 days
show more ...
|
Revision tags: release/12.2.0 |
|
#
662c1305 |
| 01-Sep-2020 |
Mateusz Guzik <mjg@FreeBSD.org> |
net: clean up empty lines in .c and .h files
|
Revision tags: release/11.4.0 |
|
#
da187ddb |
| 01-Jun-2020 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
* Add rib_<add|del|change>_route() functions to manipulate the routing table.
The main driver for the change is the need to improve notification mechanism. Currently callers guess the operation data
* Add rib_<add|del|change>_route() functions to manipulate the routing table.
The main driver for the change is the need to improve notification mechanism. Currently callers guess the operation data based on the rtentry structure returned in case of successful operation result. There are two problems with this appoach. First is that it doesn't provide enough information for the upcoming multipath changes, where rtentry refers to a new nexthop group, and there is no way of guessing which paths were added during the change. Second is that some rtentry fields can change during notification and protecting from it by requiring customers to unlock rtentry is not desired.
Additionally, as the consumers such as rtsock do know which operation they request in advance, making explicit add/change/del versions of the functions makes sense, especially given the functions don't share a lot of code.
With that in mind, introduce rib_cmd_info notification structure and rib_<add|del|change>_route() functions, with mandatory rib_cmd_info pointer. It will be used in upcoming generalized notifications.
* Move definitions of the new functions and some other functions/structures used for the routing table manipulation to a separate header file, net/route/route_ctl.h. net/route.h is a frequently used file included in ~140 places in kernel, and 90% of the users don't need these definitions.
Reviewed by: ae Differential Revision: https://reviews.freebsd.org/D25067
show more ...
|
#
e7403d02 |
| 01-Jun-2020 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
Revert r361704, it accidentally committed merged D25067 and D25070.
|
#
79674562 |
| 01-Jun-2020 |
Alexander V. Chernikov <melifaro@FreeBSD.org> |
* Add rib_<add|del|change>_route() functions to manipulate the routing table.
The main driver for the change is the need to improve notification mechanism. Currently callers guess the operation data
* Add rib_<add|del|change>_route() functions to manipulate the routing table.
The main driver for the change is the need to improve notification mechanism. Currently callers guess the operation data based on the rtentry structure returned in case of successful operation result. There are two problems with this appoach. First is that it doesn't provide enough information for the upcoming multipath changes, where rtentry refers to a new nexthop group, and there is no way of guessing which paths were added during the change. Second is that some rtentry fields can change during notification and protecting from it by requiring customers to unlock rtentry is not desired.
Additionally, as the consumers such as rtsock do know which operation they request in advance, making explicit add/change/del versions of the functions makes sense, especially given the functions don't share a lot of code.
With that in mind, introduce rib_cmd_info notification structure and rib_<add|del|change>_route() functions, with mandatory rib_cmd_info pointer. It will be used in upcoming generalized notifications.
* Move definitions of the new functions and some other functions/structures used for the routing table manipulation to a separate header file, net/route/route_ctl.h. net/route.h is a frequently used file included in ~140 places in kernel, and 90% of the users don't need these definitions.
Reviewed by: ae Differential Revision: https://reviews.freebsd.org/D25067
show more ...
|
#
e43d33d2 |
| 05-Mar-2020 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r358466 through r358677.
|
#
3818c25a |
| 04-Mar-2020 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
Implement optional table entry limits for if_llatbl.
Implement counting of table entries linked on a per-table base with an optional (if set > 0) limit of the maximum number of table entries.
For t
Implement optional table entry limits for if_llatbl.
Implement counting of table entries linked on a per-table base with an optional (if set > 0) limit of the maximum number of table entries.
For that the public lltable_link_entry() and lltable_unlink_entry() functions as well as the internal function pointers change from void to having an int return type.
Given no consumer currently sets the new llt_maxentries this can be committed on its own. The moment we make use of the table limits, the callers of the link function must check the return value as it can change and entries might not be added.
Adjustments for IPv6 (and possibly IPv4) will follow.
Sponsored by: Netflix (originally) Reviewed by: melifaro MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D22713
show more ...
|