From: Mark A. Greer Date: Tue, 2 Sep 2014 22:12:35 +0000 (-0700) Subject: NFC: trf7970a: Don't assume CONFIG_PM_RUNTIME is enabled X-Git-Tag: fixes-against-v3.18-rc2~144^2~39^2~72^2~46 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ceccd6aa50887352e66d0edf68d8be510a639da6;p=pandora-kernel.git NFC: trf7970a: Don't assume CONFIG_PM_RUNTIME is enabled The current code assumes that CONFIG_PM_RUNTIME is always defined so it won't power up the trf7970a when it isn't enabled. Fix this by moving the power up/down code from the pm_runtime_resume/suspend routines into their own routines and calling the power up function from the probe routine. This ensures the device is powered up even when CONFIG_PM_RUNTIME is not defined. In order to not power on/off a device that is already powered on/off, create a new state to indicate that the power is off (TRF7970A_ST_PWR_OFF). Signed-off-by: Mark A. Greer Signed-off-by: Samuel Ortiz --- Reading git-diff-tree failed