Discussion:
[Bug 219250] [Panic] panic: in6_ifattach_linklocal: ia == NULL (assigning ipv6 addresses)
(too old to reply)
b***@freebsd.org
2018-11-07 19:10:49 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Eric van Gyzen <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Severity|Affects Only Me |Affects Some People
Summary|[Panic] [VIMAGE] panic: |[Panic] panic:
|in6_ifattach_linklocal |in6_ifattach_linklocal: ia
|(assigning ipv6 addresses |== NULL (assigning ipv6
|in vnet jail) |addresses)
Hardware|amd64 |Any

--- Comment #2 from Eric van Gyzen <***@FreeBSD.org> ---
Something removed an IPv6 link-local interface address immediately after it was
added. I don't know how this happened. However, it is clear that there is no
thread synchronization to prevent this scenario and guarantee the assertion.
This function (or its caller) really needs some kind of synchronization.
Write-locking the if_addr_lock, which protects the interface's list of
addresses, seems like a good choice, but I haven't tested that.

I'm removing [VIMAGE] from the title, since this can be triggered without
VIMAGE.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freebsd.org
2018-11-07 22:13:24 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Bjoern A. Zeeb <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |***@FreeBSD.org
Keywords| |ipv6
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freebsd.org
2018-11-08 15:00:07 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Eric van Gyzen <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Assignee|***@FreeBSD.org |***@FreeBSD.org
Status|New |In Progress

--- Comment #3 from Eric van Gyzen <***@FreeBSD.org> ---
https://reviews.freebsd.org/D17898
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freebsd.org
2018-11-08 15:28:27 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Rodney W. Grimes <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |***@FreeBSD.org
--
You are receiving this mail because:
You are on the CC list for the bug.
b***@freebsd.org
2018-11-08 19:51:14 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

--- Comment #4 from commit-***@freebsd.org ---
A commit references this bug:

Author: vangyzen
Date: Thu Nov 8 19:50:23 UTC 2018
New revision: 340257
URL: https://svnweb.freebsd.org/changeset/base/340257

Log:
in6_ifattach_linklocal: handle immediate removal of the new LLA

If another thread immediately removes the link-local address
added by in6_update_ifa(), in6ifa_ifpforlinklocal() can return NULL,
so the following assertion (or dereference) is wrong.
Remove the assertion, and handle NULL somewhat better than panicking.
This matches all of the other callers of in6_update_ifa().

PR: 219250
Reviewed by: bz, dab (both an earlier version)
MFC after: 1 week
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D17898

Changes:
head/sys/netinet6/in6_ifattach.c
--
You are receiving this mail because:
You are on the CC list for the bug.
b***@freebsd.org
2018-11-19 08:53:13 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Kubilay Kocak <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Flags| |mfc-stable12?
Keywords| |crash
URL| |https://reviews.freebsd.org
| |/D17898
Summary|[Panic] panic: |panic:
|in6_ifattach_linklocal: ia |in6_ifattach_linklocal: ia
|== NULL (assigning ipv6 |== NULL (assigning ipv6
|addresses) |addresses)
--
You are receiving this mail because:
You are on the CC list for the bug.
b***@freebsd.org
2018-11-27 19:40:39 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

--- Comment #5 from commit-***@freebsd.org ---
A commit references this bug:

Author: vangyzen
Date: Tue Nov 27 19:40:07 UTC 2018
New revision: 341086
URL: https://svnweb.freebsd.org/changeset/base/341086

Log:
MFC r340257

in6_ifattach_linklocal: handle immediate removal of the new LLA

If another thread immediately removes the link-local address
added by in6_update_ifa(), in6ifa_ifpforlinklocal() can return NULL,
so the following assertion (or dereference) is wrong.
Remove the assertion, and handle NULL somewhat better than panicking.
This matches all of the other callers of in6_update_ifa().

PR: 219250
Reviewed by: bz, dab (both an earlier version)
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D17898

Changes:
_U stable/12/
stable/12/sys/netinet6/in6_ifattach.c
--
You are receiving this mail because:
You are on the CC list for the bug.
b***@freebsd.org
2018-11-27 19:41:53 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Eric van Gyzen <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|In Progress |Closed
Resolution|--- |FIXED
--
You are receiving this mail because:
You are on the CC list for the bug.
b***@freebsd.org
2018-11-27 19:40:42 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

--- Comment #6 from commit-***@freebsd.org ---
A commit references this bug:

Author: vangyzen
Date: Tue Nov 27 19:40:18 UTC 2018
New revision: 341087
URL: https://svnweb.freebsd.org/changeset/base/341087

Log:
MFC r340257

in6_ifattach_linklocal: handle immediate removal of the new LLA

If another thread immediately removes the link-local address
added by in6_update_ifa(), in6ifa_ifpforlinklocal() can return NULL,
so the following assertion (or dereference) is wrong.
Remove the assertion, and handle NULL somewhat better than panicking.
This matches all of the other callers of in6_update_ifa().

PR: 219250
Reviewed by: bz, dab (both an earlier version)
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D17898

Changes:
_U stable/11/
stable/11/sys/netinet6/in6_ifattach.c
--
You are receiving this mail because:
You are on the CC list for the bug.
b***@freebsd.org
2018-11-28 04:08:18 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=219250

Kubilay Kocak <***@FreeBSD.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Flags|mfc-stable12? |mfc-stable11+,
| |mfc-stable12+
--
You are receiving this mail because:
You are on the CC list for the bug.
Loading...