From patchwork Fri Feb 8 01:13:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kachhap X-Patchwork-Id: 2114491 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 084EE3FDF1 for ; Fri, 8 Feb 2013 01:13:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759540Ab3BHBNp (ORCPT ); Thu, 7 Feb 2013 20:13:45 -0500 Received: from mail-ye0-f171.google.com ([209.85.213.171]:40881 "EHLO mail-ye0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759578Ab3BHBN3 (ORCPT ); Thu, 7 Feb 2013 20:13:29 -0500 Received: by mail-ye0-f171.google.com with SMTP id m8so799543yen.30 for ; Thu, 07 Feb 2013 17:13:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references; bh=w/SuLPzyXY5EgtYi42jJqgmMJRHNI8GRADYOz9jtD+s=; b=g2aZ5/XQv6lzIQbd5q+pCGkxtzrbJzGSyupbJayOdasq2JSyAGCV0UpSgi/Cfl9I3t 8+LNCx8ofrEnTV99U8kqDabLuuQKeFDfEa6HlTETxgqSBwZtBQxiSJRkES4OvEmPnF58 GD1e1UDnudAdnWjyJgkD/cDgtEZOgAf9ULF3LbofjuZjjadqvDN4DC3vMXLsDuhv8o/c NqDkJgc0bVTwzTEht/8xtbsZpKDNoiNq5xkE5Yonanqb+NzNfEA/LzMw0LrcshsDbjHq EdU7Q18SNN6qMK8E8dVTQcLzGoWOlMnBIWPWjkA4kEoSmJZ0KII4qPw1VchfT+W6tfkE 3cVA== X-Received: by 10.236.142.101 with SMTP id h65mr3957036yhj.95.1360286008367; Thu, 07 Feb 2013 17:13:28 -0800 (PST) Received: from localhost.localdomain (D32451F2.uspool.samsung.com. [211.36.81.242]) by mx.google.com with ESMTPS id w2sm50170605yhk.8.2013.02.07.17.13.25 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 07 Feb 2013 17:13:27 -0800 (PST) From: Amit Daniel Kachhap To: linux-pm@vger.kernel.org, Zhang Rui Cc: jonghwa3.lee@samsung.com, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org, kgene.kim@samsung.com Subject: [PATCH V3 2/2] thermal: exynos: Use the new thermal trend type for quick cooling action. Date: Thu, 7 Feb 2013 17:13:07 -0800 Message-Id: <1360285987-13921-2-git-send-email-amit.daniel@samsung.com> X-Mailer: git-send-email 1.7.5.4 In-Reply-To: <1360285987-13921-1-git-send-email-amit.daniel@samsung.com> References: <1360285987-13921-1-git-send-email-amit.daniel@samsung.com> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org This patch uses the quick thermal cooling trend type macros. This is needed as exynos5 and other thermal sensors now supports only interrupt method for thresold temperature check. Acked-by: Kukjin Kim Signed-off-by: Amit Daniel Kachhap --- Hi, Submitting these patches again as they got lost somewhere and was not merged. Changes since V2: * Rebased against Rui Zhang next tree. * Added Kukjin Kim acked by. All these patches are based on thermal maintainer next branch. git://git.kernel.org/pub/scm/linux/kernel/git/rzhang/linux.git thermal drivers/thermal/exynos_thermal.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c index 65f69cf..030bba3 100644 --- a/drivers/thermal/exynos_thermal.c +++ b/drivers/thermal/exynos_thermal.c @@ -296,7 +296,7 @@ static int exynos_bind(struct thermal_zone_device *thermal, case MONITOR_ZONE: case WARN_ZONE: if (thermal_zone_bind_cooling_device(thermal, i, cdev, - level, level)) { + level, 0)) { pr_err("error binding cdev inst %d\n", i); ret = -EINVAL; } @@ -399,9 +399,9 @@ static int exynos_get_trend(struct thermal_zone_device *thermal, return ret; if (thermal->temperature >= trip_temp) - *trend = THERMAL_TREND_RAISING; + *trend = THERMAL_TREND_RAISE_FULL; else - *trend = THERMAL_TREND_DROPPING; + *trend = THERMAL_TREND_DROP_FULL; return 0; }