Re: [PATCH v10] i2c: virtio: add a virtio i2c frontend driver
From: Viresh Kumar
Date: Wed Mar 24 2021 - 00:01:31 EST
On 24-03-21, 09:17, Jie Deng wrote:
> I didn't see the "struct virtio_driver" has a member "struct dev_pm_ops *pm"
>
> It defines its own hooks (freeze and restore) though it includes "struct
> device_driver"
>
> which has a "struct dev_pm_ops *pm".
>
> I just follow other virtio drivers to directly use the hooks defined in
> "struct virtio_driver".
Right, I think we can't use the SIMPLE PM OPS for virtio yet, the core calls
only the freeze and restore callbacks which are part of struct virtio_driver.
> For this driver, Both __maybe_unused and #ifdef are OK to me.
Yes, and so you should use only #ifdef here as Arnd confirmed. You shouldn't be
using __maybe_unused as there is nothing confusing here related to the macros.
--
viresh