diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2024-04-17 00:04:59 +0300 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2024-04-17 00:04:59 +0300 |
commit | 640958fde130acfea98f539dfd4de6a9e72cf012 (patch) | |
tree | c122cb130940b99f79e9b21cdc00c7437afd98ce /include/linux/virtio.h | |
parent | 4e2e3612922529f03a6fb380d416ba8c968b34cc (diff) | |
parent | 0bbac3facb5d6cc0171c45c9873a2dc96bea9680 (diff) | |
download | linux-640958fde130acfea98f539dfd4de6a9e72cf012.tar.xz |
Merge branch 'master' into mm-stable
Diffstat (limited to 'include/linux/virtio.h')
-rw-r--r-- | include/linux/virtio.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/include/linux/virtio.h b/include/linux/virtio.h index b0201747a263..26c4325aa373 100644 --- a/include/linux/virtio.h +++ b/include/linux/virtio.h @@ -170,7 +170,7 @@ size_t virtio_max_dma_size(const struct virtio_device *vdev); /** * struct virtio_driver - operations for a virtio I/O driver - * @driver: underlying device driver (populate name and owner). + * @driver: underlying device driver (populate name). * @id_table: the ids serviced by this driver. * @feature_table: an array of feature numbers supported by this driver. * @feature_table_size: number of entries in the feature table array. @@ -208,7 +208,10 @@ static inline struct virtio_driver *drv_to_virtio(struct device_driver *drv) return container_of(drv, struct virtio_driver, driver); } -int register_virtio_driver(struct virtio_driver *drv); +/* use a macro to avoid include chaining to get THIS_MODULE */ +#define register_virtio_driver(drv) \ + __register_virtio_driver(drv, THIS_MODULE) +int __register_virtio_driver(struct virtio_driver *drv, struct module *owner); void unregister_virtio_driver(struct virtio_driver *drv); /* module_virtio_driver() - Helper macro for drivers that don't do |