Re: [PATCH] coccinelle: api: fix kobj_to_dev.cocci warnings

From: Jens Axboe
Date: Thu Aug 27 2020 - 18:24:33 EST


On 8/27/20 2:13 PM, Julia Lawall wrote:
> Use kobj_to_dev() instead of container_of()
>
> Generated by: scripts/coccinelle/api/kobj_to_dev.cocci

Seem to see more of these, these days. I don't really like them, why not
just use container_of? The private bla_to_foo() helpers should go away,
they are actively hurting readability of the code imho.

--
Jens Axboe