From: Guo-Fu Tseng Date: Tue, 28 Jun 2011 04:32:38 +0000 (+0800) Subject: jme: Fix compile warning introduced by new pm macro X-Git-Tag: bp-1.0.8.1~14 X-Git-Url: https://bbs.cooldavid.org/git/?p=jme.git;a=commitdiff_plain;h=fda5634a662b227a432d611ce756c3516ece131b jme: Fix compile warning introduced by new pm macro SIMPLE_DEV_PM_OPS is using SET_SYSTEM_SLEEP_PM_OPS and SET_SYSTEM_SLEEP_PM_OPS is empty when CONFIG_PM_SLEEP is not defined. Switching #ifdef CONFIG_PM to #ifdef CONFIG_PM_SLEEP --- diff --git a/jme.c b/jme.c index 3eb01a5..1457ce7 100644 --- a/jme.c +++ b/jme.c @@ -3331,7 +3331,17 @@ jme_shutdown(struct pci_dev *pdev) #endif } -#ifdef CONFIG_PM +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25) + #ifdef CONFIG_PM + #define JME_HAVE_PM + #endif +#else + #ifdef CONFIG_PM_SLEEP + #define JME_HAVE_PM + #endif +#endif + +#ifdef JME_HAVE_PM static int #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,38) jme_suspend(struct pci_dev *pdev, pm_message_t state)