Re: [PATCH v2 6/6] Input: cyttsp5 - implement proper sleep and wakeup procedures

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 01, 2023 at 01:30:10PM +0200, Maximilian Weigand wrote:
>  struct cyttsp5 {
>  	struct device *dev;
>  	struct completion cmd_done;
> +	struct completion cmd_command_done;

Why do we need separate comletion? Do you observe some additional
traffic from the controller when powering it off and on?

> +static int __maybe_unused cyttsp5_suspend(struct device *dev)
> +{
> +	struct cyttsp5 *ts = dev_get_drvdata(dev);
> +
> +	if (!ts->is_wakeup_source)

I believe the idiomatic way to check this is to call
device_may_wakeup().

> +		cyttsp5_enter_sleep(ts);
> +	return 0;
> +}

Thanks.

-- 
Dmitry



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux