Re: [PATCH 1/5] kobject: make kobject_get_ownership() take a constant kobject *

From: Jakub Kicinski
Date: Mon Nov 21 2022 - 15:18:13 EST


On Mon, 21 Nov 2022 10:46:45 +0100 Greg Kroah-Hartman wrote:
> The call, kobject_get_ownership(), does not modify the kobject passed
> into it, so make it const. This propagates down into the kobj_type
> function callbacks so make the kobject passed into them also const,
> ensuring that nothing in the kobject is being changed here.
>
> This helps make it more obvious what calls and callbacks do, and do not,
> modify structures passed to them.

Acked-by: Jakub Kicinski <kuba@xxxxxxxxxx>