Re: [PATCH] container_of: add type safety

Greg Kroah-Hartman
2023-03-08T17:57:49Z

On Wed, Mar 08, 2023 at 12:35:03PM -0500, Michael S. Tsirkin wrote:
> Using a wrong member in container_of will result in an error.
> No so for container_of_const - it is just a cast so will
> happily give you a wrong pointer.
>
> Use logic from container_of to add safety.

Also your subject line is wrong :(