From patchwork Tue Jan 13 07:14:24 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rajkumar Manoharan X-Patchwork-Id: 5618231 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 459ABC058D for ; Tue, 13 Jan 2015 07:14:48 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 76CEA205E8 for ; Tue, 13 Jan 2015 07:14:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 88398205D3 for ; Tue, 13 Jan 2015 07:14:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751015AbbAMHOp (ORCPT ); Tue, 13 Jan 2015 02:14:45 -0500 Received: from sabertooth01.qualcomm.com ([65.197.215.72]:57414 "EHLO sabertooth01.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750968AbbAMHOo (ORCPT ); Tue, 13 Jan 2015 02:14:44 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qti.qualcomm.com; i=@qti.qualcomm.com; q=dns/txt; s=qcdkim; t=1421133284; x=1452669284; h=from:to:cc:subject:date:message-id:mime-version; bh=vKX5usgLQ05jjVTnb8SPcjBi96TKMYMvat6IAYe98To=; b=JkFtx0kEmFisHUx+KOKzBUaYhHSghddTb+P59OqEYgdaZ3U0axOpI8to ZH/aStlp9QU9DA99a28xmi0/+eBkGf8wEcL4sh53NXlqF7it4ehQ8a7sc 1rC3UM2xGpSgU95ymy7QtS/wHIxAi1ak7PPDkHB5s9y36HC3PDK8UVt95 U=; X-IronPort-AV: E=McAfee;i="5600,1067,7679"; a="81427385" Received: from ironmsg04-r.qualcomm.com ([172.30.46.18]) by sabertooth01.qualcomm.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 12 Jan 2015 23:14:44 -0800 X-IronPort-AV: E=Sophos;i="5.07,748,1413270000"; d="scan'208";a="882864615" Received: from nasanexm02b.na.qualcomm.com ([10.46.200.37]) by Ironmsg04-R.qualcomm.com with ESMTP/TLS/RC4-SHA; 12 Jan 2015 23:14:44 -0800 Received: from aphydexm01b.ap.qualcomm.com (10.222.112.203) by nasanexm02b.na.qualcomm.com (10.46.200.37) with Microsoft SMTP Server (TLS) id 15.0.995.29; Mon, 12 Jan 2015 23:14:42 -0800 Received: from qcmail1.qualcomm.com (10.80.80.8) by aphydexm01b.ap.qualcomm.com (10.222.112.203) with Microsoft SMTP Server (TLS) id 15.0.995.29; Mon, 12 Jan 2015 23:14:35 -0800 Received: by qcmail1.qualcomm.com (sSMTP sendmail emulation); Tue, 13 Jan 2015 12:44:25 +0530 From: Rajkumar Manoharan To: CC: , Rajkumar Manoharan Subject: [PATCH v2] ath10k: fix hwmon temperature input units Date: Tue, 13 Jan 2015 12:44:24 +0530 Message-ID: <1421133264-21278-1-git-send-email-rmanohar@qti.qualcomm.com> X-Mailer: git-send-email 2.2.1 MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: NASANEXM01F.na.qualcomm.com (10.85.0.32) To aphydexm01b.ap.qualcomm.com (10.222.112.203) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID,T_RP_MATCHES_RCVD,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP To be compliant with the hwmon interface the unit needs to be millidegree Celsius. Fix that. Reported-by: Matthias Kaehlcke Signed-off-by: Rajkumar Manoharan --- v2: added new line for better readability. drivers/net/wireless/ath/ath10k/thermal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath10k/thermal.c b/drivers/net/wireless/ath/ath10k/thermal.c index b14ae8d..e915178 100644 --- a/drivers/net/wireless/ath/ath10k/thermal.c +++ b/drivers/net/wireless/ath/ath10k/thermal.c @@ -160,7 +160,8 @@ static ssize_t ath10k_thermal_show_temp(struct device *dev, temperature = ar->thermal.temperature; spin_unlock_bh(&ar->data_lock); - ret = snprintf(buf, PAGE_SIZE, "%d", temperature); + /* display in millidegree celcius */ + ret = snprintf(buf, PAGE_SIZE, "%d\n", temperature * 1000); out: mutex_unlock(&ar->conf_mutex); return ret;