HomeFreeBSD

Struct cdev is always the member of the struct cdev_priv. When devfs

Description

Struct cdev is always the member of the struct cdev_priv. When devfs
needed to promote cdev to cdev_priv, the si_priv pointer was followed.

Use member2struct() to calculate address of the wrapping cdev_priv.
Rename si_priv to __si_reserved.

Tested by: pho
Reviewed by: ed
MFC after: 2 weeks

Details

Provenance
kibAuthored on Jun 16 2008, 5:34 PM
Parents
rG4c20b7670c3a: Add the member2struct() macro, that returns pointer to the containing
Branches
Unknown
Tags
Unknown

Event Timeline