Re: [PATCH] dwc3: dwc3-pci: Use SIMPLE_DEV_PM_OPS

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

 



On Tue, Aug 13, 2013 at 11:05 AM, Peter Chen <hzpeterchen@xxxxxxxxx> wrote:

> But what I see is the &dwc3_pci_dev_pm_ops is not NULL if CONFIG_PM_SLEEP
> is not defined.

The point of this macro is that we do not need to provide the .suspend
and .resume NULL version when !CONFIG_PM_SLEEP because the macro takes
care of this for us:

#ifdef CONFIG_PM_SLEEP
#define SET_SYSTEM_SLEEP_PM_OPS(suspend_fn, resume_fn) \
	.suspend = suspend_fn, \
	.resume = resume_fn, \
	.freeze = suspend_fn, \
	.thaw = resume_fn, \
	.poweroff = suspend_fn, \
	.restore = resume_fn,
#else
#define SET_SYSTEM_SLEEP_PM_OPS(suspend_fn, resume_fn)
#endif
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux