From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: mjg@redhat.com, platform-driver-x86@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH 5/5] platform-x86: intel_mid_thermal: turn off thermistor voltage by default
Date: Thu, 26 Jan 2012 17:39:46 +0000 [thread overview]
Message-ID: <20120126173943.16719.16596.stgit@bob.linux.org.uk> (raw)
In-Reply-To: <20120126173729.16719.15431.stgit@bob.linux.org.uk>
From: Mika Westerberg <mika.westerberg@linux.intel.com>
Instead of complaining that the voltage is on, we can just ask the MSIC to
turn the voltage off. This should save some power.
Voltage for thermistors is turned on when ADC conversion is initiated.
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
---
drivers/platform/x86/intel_mid_thermal.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/platform/x86/intel_mid_thermal.c b/drivers/platform/x86/intel_mid_thermal.c
index aef4979..a4e56be 100644
--- a/drivers/platform/x86/intel_mid_thermal.c
+++ b/drivers/platform/x86/intel_mid_thermal.c
@@ -360,8 +360,10 @@ static int mid_initialize_adc(struct device *dev)
if (ret)
return ret;
- if (data & MSIC_ADCTHERM_MASK)
- dev_warn(dev, "ADCTHERM already set");
+ data &= ~MSIC_ADCTHERM_MASK;
+ ret = intel_msic_reg_write(INTEL_MSIC_ADC1CNTL3, data);
+ if (ret)
+ return ret;
/* Index of the first channel in which the stop bit is set */
channel_index = find_free_channel();
next prev parent reply other threads:[~2012-01-26 17:26 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-26 17:37 [PATCH 1/5] platform, x86: Kill off Moorestown Alan Cox
2012-01-26 17:39 ` [PATCH 2/5] intel_scu_ipc: Remove Moorestown support Alan Cox
2012-01-26 17:39 ` [PATCH 3/5] platform-x86: intel_mid_thermal: add msic_thermal alias Alan Cox
2012-01-27 16:33 ` R, Durgadoss
2012-01-30 10:59 ` Alan Cox
2012-01-26 17:39 ` [PATCH 4/5] platform-x86: intel_mid_thermal: convert to use Intel MSIC API Alan Cox
2012-01-27 16:28 ` R, Durgadoss
2012-01-26 17:39 ` Alan Cox [this message]
2012-01-27 16:27 ` [PATCH 5/5] platform-x86: intel_mid_thermal: turn off thermistor voltage by default R, Durgadoss
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120126173943.16719.16596.stgit@bob.linux.org.uk \
--to=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=mjg@redhat.com \
--cc=platform-driver-x86@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox