mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] virtio: Remove PM #ifdef guards to fix i2c driver
@ 2023-08-01 10:58 Arnd Bergmann
  2023-08-01 22:20 ` Andi Shyti
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Arnd Bergmann @ 2023-08-01 10:58 UTC (permalink / raw)
  To: Andi Shyti
  Cc: Arnd Bergmann, Michael S. Tsirkin, Jason Wang, Xuan Zhuo,
	Stefano Garzarella, Christophe JAILLET, Feng Liu, Viresh Kumar,
	Paul Cercueil, Jonathan Cameron, virtualization, linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

A cleanup in the virtio i2c caused a build failure:

drivers/i2c/busses/i2c-virtio.c:270:10: error: 'struct virtio_driver' has no member named 'freeze'
drivers/i2c/busses/i2c-virtio.c:271:10: error: 'struct virtio_driver' has no member named 'restore'

Change the structure definition to allow this cleanup to
be applied everywhere.

Fixes: 73d546c76235b ("i2c: virtio: Remove #ifdef guards for PM related functions")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 include/linux/virtio.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/include/linux/virtio.h b/include/linux/virtio.h
index 0f3b9017dff40..9b94e2c9bbb81 100644
--- a/include/linux/virtio.h
+++ b/include/linux/virtio.h
@@ -218,10 +218,8 @@ struct virtio_driver {
 	void (*scan)(struct virtio_device *dev);
 	void (*remove)(struct virtio_device *dev);
 	void (*config_changed)(struct virtio_device *dev);
-#ifdef CONFIG_PM
 	int (*freeze)(struct virtio_device *dev);
 	int (*restore)(struct virtio_device *dev);
-#endif
 };
 
 static inline struct virtio_driver *drv_to_virtio(struct device_driver *drv)
-- 
2.39.2


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-08-02 23:50 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-01 10:58 [PATCH] virtio: Remove PM #ifdef guards to fix i2c driver Arnd Bergmann
2023-08-01 22:20 ` Andi Shyti
2023-08-01 23:06 ` Paul Cercueil
2023-08-01 23:42   ` Andi Shyti
2023-08-02 20:10 ` Andi Shyti

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®