Page MenuHomeFreeBSD

Fix if_(m)addr_rlock() on stable/12.
ClosedPublic

Authored by markj on Mar 30 2019, 5:48 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Apr 14, 6:29 PM
Unknown Object (File)
Sun, Apr 14, 6:06 PM
Unknown Object (File)
Sun, Apr 14, 5:50 PM
Unknown Object (File)
Jan 28 2024, 8:07 PM
Unknown Object (File)
Dec 21 2023, 12:24 AM
Unknown Object (File)
Dec 20 2023, 6:11 AM
Unknown Object (File)
Nov 9 2023, 9:30 PM
Unknown Object (File)
Nov 8 2023, 2:39 PM
Subscribers

Details

Summary

This is an alternative to r340413 that does not break the KBI. We have
users hitting the bug on 12.0, and the patch D17996 solves the problem.

Test Plan

One stf(4) user was hitting memory corruption panics that have gone
away with this patch applied to stable/12.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

markj added reviewers: glebius, hselasky.
markj added a subscriber: emaste.

The patch technically looks good to me. Is this change for MFC only?

This revision is now accepted and ready to land.Mar 30 2019, 6:57 PM

The patch technically looks good to me. Is this change for MFC only?

My plan is to commit directly to stable/12 and request an EN for 12.0.

sys/net/if_var.h
385 ↗(On Diff #55624)

We have to replace these with padding to preserve the KBI.

This revision was automatically updated to reflect the committed changes.

Mark, do you suppose that this can fix some another strange panics that appeared after epochification?

In D19764#424043, @ae wrote:

Mark, do you suppose that this can fix some another strange panics that appeared after epochification?

It's hard to say without more info. The two cases I saw were indeed "strange": one panic in kevent, and one in the pfil hooks. Note that the problem applies only to stable/12, the bug has been fixed in head for a few months.

In D19764#424043, @ae wrote:

Mark, do you suppose that this can fix some another strange panics that appeared after epochification?

It's hard to say without more info. The two cases I saw were indeed "strange": one panic in kevent, and one in the pfil hooks. Note that the problem applies only to stable/12, the bug has been fixed in head for a few months.

Note, this was without INVARIANTS. With INVARIANTS enabled we saw an assertion failure in the epoch code.