Page MenuHomeFreeBSD

ksyms: Lock the object while setting NOSPLIT.
ClosedPublic

Authored by markj on Nov 3 2019, 4:19 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Jun 28, 7:59 AM
Unknown Object (File)
Thu, Jun 26, 8:56 PM
Unknown Object (File)
Wed, Jun 25, 10:58 PM
Unknown Object (File)
Wed, Jun 25, 7:56 PM
Unknown Object (File)
Tue, Jun 24, 6:51 PM
Unknown Object (File)
Mon, Jun 23, 2:53 AM
Unknown Object (File)
Fri, Jun 20, 8:49 AM
Unknown Object (File)
Wed, Jun 18, 7:42 PM
Subscribers

Details

Summary

Alan pointed out that the object resides in the global object list, so
formally we should lock it to synchronize with a scan of the list.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 27333
Build 25584: arc lint + arc unit

Event Timeline

I think that we should consider adding a vm_object_allocate_flags().

This revision is now accepted and ready to land.Nov 3 2019, 5:20 PM

Although unlocked manipulations of the flags were removed AFAIR.

I realized after submitting this that really we should be using OBJT_PHYS here. The object's contents are not pageable.

Convert to OBJT_PHYS and stop setting NOSPLIT entirely.

This revision now requires review to proceed.Nov 3 2019, 7:30 PM
sys/dev/ksyms/ksyms.c
44

Is this still needed?

Remove unneeded include.

In D22229#485773, @kib wrote:

Although unlocked manipulations of the flags were removed AFAIR.

Yes, I believe so. However, in recent weeks, I recall seeing at least two attempts to reintroduce unlocked manipulations, counting this as one of them. I think that a vm_object_allocate_flags() would eliminate the temptation to do so.

This revision is now accepted and ready to land.Nov 4 2019, 3:51 PM
This revision was automatically updated to reflect the committed changes.