Page MenuHomeFreeBSD

pseudofs: Don't purge the cache on shutdown
ClosedPublic

Authored by des on Jul 20 2026, 6:46 PM.
Tags
None
Referenced Files
F171059147: D58359.id.diff
Tue, Sep 8, 11:17 AM
F170994840: D58359.id183435.diff
Tue, Sep 8, 2:03 AM
F170922647: D58359.diff
Mon, Sep 7, 3:09 PM
Unknown Object (File)
Mon, Sep 7, 4:24 AM
Unknown Object (File)
Sun, Sep 6, 4:19 PM
Unknown Object (File)
Fri, Sep 4, 7:19 PM
Unknown Object (File)
Fri, Sep 4, 3:07 AM
Unknown Object (File)
Wed, Sep 2, 2:47 PM
Subscribers

Details

Summary

This is a waste of time and results in a use-after-free if linsysfs is
loaded and a USB network interface is in use, since USB devices are
disconnected at shutdown, which triggers a call into linsysfs, which
then tries to destroy a pseudofs node which has already been purged.

MFC after: 1 week
Reported by: glebius

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 74961
Build 71844: arc lint + arc unit

Event Timeline

des requested review of this revision.Jul 20 2026, 6:46 PM

Thanks! While I'm 99% sure it is going to fix my panic, I can't test it right away. Traveling right now and machine that exhibits it is not with me. I'll be able to test next week. If you want you can delay the push until I test. I will report here, in this revision.

This revision is now accepted and ready to land.Jul 20 2026, 6:59 PM

I will be able tomorrow. Was traveling this week. Will update.

Yes, the patch works as expected: fixes the panic on shutdown. Thanks!

This revision was automatically updated to reflect the committed changes.