Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754862Ab2JPO7K (ORCPT ); Tue, 16 Oct 2012 10:59:10 -0400 Received: from mga11.intel.com ([192.55.52.93]:19928 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754796Ab2JPO7H (ORCPT ); Tue, 16 Oct 2012 10:59:07 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.80,593,1344236400"; d="scan'208";a="235797905" From: Yuanhan Liu To: linux-kernel@vger.kernel.org Cc: Yuanhan Liu , Herbert Xu , "David S. Miller" , linux-crypto@vger.kernel.org, Fengguang Wu Subject: [PATCH 5/5] crypto: suspend/resume callbacks should be conditionally compiled on CONFIG_PM_SLEEP Date: Tue, 16 Oct 2012 22:59:05 +0800 Message-Id: <1350399545-11179-5-git-send-email-yuanhan.liu@linux.intel.com> X-Mailer: git-send-email 1.7.7.6 In-Reply-To: <1350399545-11179-1-git-send-email-yuanhan.liu@linux.intel.com> References: <1350399545-11179-1-git-send-email-yuanhan.liu@linux.intel.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2051 Lines: 63 This will fix warnings like following when CONFIG_PM_SLEEP is not set: warning: 'xxx_suspend' defined but not used [-Wunused-function] warning: 'xxx_resume' defined but not used [-Wunused-function] Cc: Herbert Xu Cc: "David S. Miller" Cc: linux-crypto@vger.kernel.org Signed-off-by: Yuanhan Liu Signed-off-by: Fengguang Wu --- drivers/crypto/ux500/cryp/cryp_core.c | 2 ++ drivers/crypto/ux500/hash/hash_core.c | 2 ++ 2 files changed, 4 insertions(+), 0 deletions(-) diff --git a/drivers/crypto/ux500/cryp/cryp_core.c b/drivers/crypto/ux500/cryp/cryp_core.c index bc615cc..21b50ea 100644 --- a/drivers/crypto/ux500/cryp/cryp_core.c +++ b/drivers/crypto/ux500/cryp/cryp_core.c @@ -1662,6 +1662,7 @@ static void ux500_cryp_shutdown(struct platform_device *pdev) } +#ifdef CONFIG_PM_SLEEP static int ux500_cryp_suspend(struct device *dev) { int ret; @@ -1742,6 +1743,7 @@ static int ux500_cryp_resume(struct device *dev) return ret; } +#endif static SIMPLE_DEV_PM_OPS(ux500_cryp_pm, ux500_cryp_suspend, ux500_cryp_resume); diff --git a/drivers/crypto/ux500/hash/hash_core.c b/drivers/crypto/ux500/hash/hash_core.c index 632c333..906559f 100644 --- a/drivers/crypto/ux500/hash/hash_core.c +++ b/drivers/crypto/ux500/hash/hash_core.c @@ -1892,6 +1892,7 @@ static void ux500_hash_shutdown(struct platform_device *pdev) __func__); } +#ifdef CONFIG_PM_SLEEP /** * ux500_hash_suspend - Function that suspends the hash device. * @dev: Device to suspend. @@ -1959,6 +1960,7 @@ static int ux500_hash_resume(struct device *dev) return ret; } +#endif static SIMPLE_DEV_PM_OPS(ux500_hash_pm, ux500_hash_suspend, ux500_hash_resume); -- 1.7.7.6 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/