Re: [PATCH v2 5/5] Input: edt-ft5x06 - improve power management operations

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

 



On Wed, Nov 27, 2019 at 06:25:22PM +0100, Marco Felsch wrote:
> On 19-11-27 16:32, Andy Shevchenko wrote:
> > On Wed, Nov 27, 2019 at 02:06:02PM +0100, Marco Felsch wrote:
> > > On 19-11-27 14:59, Andy Shevchenko wrote:
> > > > On Wed, Nov 27, 2019 at 01:09:48PM +0100, Marco Felsch wrote:

> > static void edt_ft5x06_ts_toggle_gpio(struct gpio_desc *gpiod, int value)
> > {
> > 	gpiod_...(..., !value);
> > 	...
> > 	gpiod_...(..., value);
> > 	...
> > }
> > 
> > ...resume(...)
> > {
> > 	...
> > 	if (wake_gpio)
> > 		...toggle_gpio(wake_gpio, 1);
> > 	else if (reset_gpio)
> > 		...toggle_gpio(reset_gpio, 0);
> > 	...
> > }
> > 
> > ?
> 
> That's possible.. Don't see the improvement yet, but I can prepare a
> folllow-up patch if Dmitry wants.

The improvement is to get rid of duplication of flow how you toggle the GPIO.
But yes, up to Dmitry.

-- 
With Best Regards,
Andy Shevchenko





[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