HomeFreeBSD

MFC r351003:

Description

MFC r351003:
Fix build with DRM and INVARIANTS enabled.

The DRM drivers use the lockdep assertion macros with spinlock_t locks
which are backed by mutexes, not sx locks. This causes compile
failures since you can't use sx_assert with a mutex. Instead, change
the lockdep macros to use lock_class methods. This works by assuming
that each LinuxKPI locking primitive embeds a FreeBSD lock as its
first structure and uses a cast to get to the underlying 'struct
lock_object'.

Reviewed by: hselasky
Differential Revision: https://reviews.freebsd.org/D20992

Details

Provenance
hselaskyAuthored on
Reviewer
hselasky
Differential Revision
D20992: Fix build with DRM and INVARIANTS enabled.
Parents
rS361190: MFC r351003:
Branches
Unknown
Tags
Unknown