aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/tpm
diff options
context:
space:
mode:
authorRafael J. Wysocki <rjw@sisk.pl>2012-08-09 17:00:35 -0400
committerRafael J. Wysocki <rjw@sisk.pl>2012-08-10 08:29:50 -0400
commit07368d32f1a67e797def08cf2ee3ea1647b204b6 (patch)
treef73b3d89ae6358eb775def3366ccf487016046dc /drivers/char/tpm
parent3567a4e2c52ce2f6fe74fc85690335ec7c96608e (diff)
tpm_tis / PM: Fix unused function warning for CONFIG_PM_SLEEP
According to a compiler warning, the tpm_tis_resume() function is not used for CONFIG_PM_SLEEP unset, so add a #ifdef to prevent it from being built in that case. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'drivers/char/tpm')
-rw-r--r--drivers/char/tpm/tpm_tis.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
index 89682fa8801e..c4be3519a587 100644
--- a/drivers/char/tpm/tpm_tis.c
+++ b/drivers/char/tpm/tpm_tis.c
@@ -807,6 +807,7 @@ module_param_string(hid, tpm_pnp_tbl[TIS_HID_USR_IDX].id,
807MODULE_PARM_DESC(hid, "Set additional specific HID for this driver to probe"); 807MODULE_PARM_DESC(hid, "Set additional specific HID for this driver to probe");
808#endif 808#endif
809 809
810#ifdef CONFIG_PM_SLEEP
810static int tpm_tis_resume(struct device *dev) 811static int tpm_tis_resume(struct device *dev)
811{ 812{
812 struct tpm_chip *chip = dev_get_drvdata(dev); 813 struct tpm_chip *chip = dev_get_drvdata(dev);
@@ -816,6 +817,7 @@ static int tpm_tis_resume(struct device *dev)
816 817
817 return tpm_pm_resume(dev); 818 return tpm_pm_resume(dev);
818} 819}
820#endif
819 821
820static SIMPLE_DEV_PM_OPS(tpm_tis_pm, tpm_pm_suspend, tpm_tis_resume); 822static SIMPLE_DEV_PM_OPS(tpm_tis_pm, tpm_pm_suspend, tpm_tis_resume);
821 823