On Tue, Jan 14, 2020 at 04:57:53PM +0100, Christian Gromm wrote:
> This patch moves the struct device of the interface structure to its
> private section, because only the core should access it directly. For
> other entities an API is provided.

This feels "wrong".

Shouldn't the struct device in this structure be the thing that is
handling the reference counting and sysfs integration for this
structure?  To put it as a "pointer" in a private section of the
structure feels like it is now backwards.

What is this helping with?  Who was messing with the device structure
here that needed to not mess with it?

It's good that you are now releasing the memory for the device structure
properly, but this still feels really wrong.  What is keeping the
lifetime of this structure now that the device is removed from it?

thanks,

greg k-h
_______________________________________________
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Reply via email to