On Wed, Mar 27, 2024 at 01:40:54PM +0100, Krzysztof Kozlowski wrote:
> Modules registering driver with register_virtio_driver() might forget to
> set .owner field. i2c-virtio.c for example has it missing. The field
> is used by some of other kernel parts for reference counting
>
On Fri, Mar 29, 2024 at 01:07:31PM +0100, Krzysztof Kozlowski wrote:
On 29/03/2024 12:42, Stefano Garzarella wrote:
};
-int register_virtio_driver(struct virtio_driver *driver)
+int __register_virtio_driver(struct virtio_driver *driver, struct module
*owner)
{
/* Catch this early. */
On 29/03/2024 12:42, Stefano Garzarella wrote:
>> };
>>
>> -int register_virtio_driver(struct virtio_driver *driver)
>> +int __register_virtio_driver(struct virtio_driver *driver, struct module
>> *owner)
>> {
>> /* Catch this early. */
>> BUG_ON(driver->feature_table_size &&
On Wed, Mar 27, 2024 at 01:40:54PM +0100, Krzysztof Kozlowski wrote:
Modules registering driver with register_virtio_driver() might forget to
set .owner field. i2c-virtio.c for example has it missing. The field
is used by some of other kernel parts for reference counting
(try_module_get()), so
Modules registering driver with register_virtio_driver() might forget to
set .owner field. i2c-virtio.c for example has it missing. The field
is used by some of other kernel parts for reference counting
(try_module_get()), so it is expected that drivers will set it.
Solve the problem by moving