diff options
author | Allan Jude <allanjude@FreeBSD.org> | 2021-02-14 18:39:09 +0000 |
---|---|---|
committer | Allan Jude <allanjude@FreeBSD.org> | 2021-02-16 19:02:00 +0000 |
commit | 922cf8ac43adc9983f9a9e05cfd838306c1ef483 (patch) | |
tree | a47be32a1659347823978882254d6a823c99603f /sys | |
parent | 97527e9c4fd37140da3129bc12003172edbf7a23 (diff) | |
download | src-922cf8ac43adc9983f9a9e05cfd838306c1ef483.tar.gz src-922cf8ac43adc9983f9a9e05cfd838306c1ef483.zip |
Use iflib_if_init_locked() during media change instead of iflib_init_locked().
iflib_init_locked() assumes that iflib_stop() has been called, however,
it is not called for media changes.
iflib_if_init_locked() calls stop then init, so fixes the problem.
PR: 253473
MFC after: 3 days
Reviewed by: markj
Sponsored by: Juniper Networks, Inc., Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D28667
Diffstat (limited to 'sys')
-rw-r--r-- | sys/net/iflib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/net/iflib.c b/sys/net/iflib.c index cce56d0e7335..a33ddbe5b8ae 100644 --- a/sys/net/iflib.c +++ b/sys/net/iflib.c @@ -2503,7 +2503,7 @@ iflib_media_change(if_t ifp) CTX_LOCK(ctx); if ((err = IFDI_MEDIA_CHANGE(ctx)) == 0) - iflib_init_locked(ctx); + iflib_if_init_locked(ctx); CTX_UNLOCK(ctx); return (err); } |