From patchwork Tue Mar 6 14:43:47 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartlomiej Zolnierkiewicz X-Patchwork-Id: 10262033 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B2B806016D for ; Tue, 6 Mar 2018 14:48:22 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A221E286EC for ; Tue, 6 Mar 2018 14:48:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9667728F7E; Tue, 6 Mar 2018 14:48:22 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F3290286EC for ; Tue, 6 Mar 2018 14:48:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753820AbeCFOsV (ORCPT ); Tue, 6 Mar 2018 09:48:21 -0500 Received: from mailout4.samsung.com ([203.254.224.34]:63098 "EHLO mailout4.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932228AbeCFOos (ORCPT ); Tue, 6 Mar 2018 09:44:48 -0500 Received: from epcas1p4.samsung.com (unknown [182.195.41.48]) by mailout4.samsung.com (KnoxPortal) with ESMTP id 20180306144446epoutp04bca6899306f8e591fc9526efcedc0560~ZW-vaVZRR1173811738epoutp04Z; Tue, 6 Mar 2018 14:44:46 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout4.samsung.com 20180306144446epoutp04bca6899306f8e591fc9526efcedc0560~ZW-vaVZRR1173811738epoutp04Z DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1520347486; bh=Qu6gQHKW7xoFY22MYs74OIf15MzkHHXPlrpzj9MiUGQ=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=g1oX0uMZk2KpGRX1HyrLLB1mhHyYxrwDfnL5q7ah7efAlnWq8rAzySDhTz/QeqFCP SWSPNH+Ixme6E0TgEgW1Rlhqc1WfxvHAFPJP1gli5eY5H/rEeXDexgsY9mtqZuNOlw VeogUyxaC0kVkry8EFr6cvbW3UFBWQZM2xEQpkgs= Received: from epsmges1p3.samsung.com (unknown [182.195.42.55]) by epcas1p1.samsung.com (KnoxPortal) with ESMTP id 20180306144445epcas1p1da837fb2c17aff825456a5a3059f9e66~ZW-uk7s5E2318623186epcas1p1m; Tue, 6 Mar 2018 14:44:45 +0000 (GMT) Received: from epcas1p1.samsung.com ( [182.195.41.45]) by epsmges1p3.samsung.com (Symantec Messaging Gateway) with SMTP id 2A.D7.04137.D59AE9A5; Tue, 6 Mar 2018 23:44:45 +0900 (KST) Received: from epsmgms2p1new.samsung.com (unknown [182.195.42.142]) by epcas1p1.samsung.com (KnoxPortal) with ESMTP id 20180306144445epcas1p1b2dee15107098f5974e3c41403594ffc~ZW-uJ131d2287822878epcas1p1n; Tue, 6 Mar 2018 14:44:45 +0000 (GMT) X-AuditID: b6c32a37-433ff70000001029-ca-5a9ea95d5deb Received: from epmmp1.local.host ( [203.254.227.16]) by epsmgms2p1new.samsung.com (Symantec Messaging Gateway) with SMTP id D5.4A.03826.C59AE9A5; Tue, 6 Mar 2018 23:44:45 +0900 (KST) Received: from AMDC3058.DIGITAL.local ([106.120.53.102]) by mmp1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0P56000X0BLSFM10@mmp1.samsung.com>; Tue, 06 Mar 2018 23:44:44 +0900 (KST) From: Bartlomiej Zolnierkiewicz To: Zhang Rui , Eduardo Valentin , Krzysztof Kozlowski Cc: Kukjin Kim , Rob Herring , Mark Rutland , Russell King , linux-samsung-soc@vger.kernel.org, linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, b.zolnierkie@samsung.com Subject: [PATCH 04/12] thermal: exynos: remove parsing of samsung,tmu_noise_cancel_mode property Date: Tue, 06 Mar 2018 15:43:47 +0100 Message-id: <1520347435-22970-5-git-send-email-b.zolnierkie@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1520347435-22970-1-git-send-email-b.zolnierkie@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrAIsWRmVeSWpSXmKPExsWy7bCmrm7synlRBm+2yFpsnLGe1WL+kXNA 4so1Vov+x6+ZLc6f38BusekxkHt51xw2i8+9RxgtZpzfx2RxaOpeRoul1y8yWbTuPcJu8eRh H5sDr8eaeWsYPS5fu8jssXPWXXaPxXteMnlsWtXJ5rF5Sb1H35ZVjB6fN8kFcERx2aSk5mSW pRbp2yVwZcz+YFcwWbTi6cwrrA2M7wS7GDk5JARMJJp6pzF1MXJxCAnsYJTovNnEDOF8Z5SY /OIfC0zVr42PWCESuxklulf0sUE4vxgl5vxbygpSxSZgJTGxfRUjiC0iUCIxbVUvI0gRs8BZ Jokd29+BjRIWSJLoPt0JVsQioCqx/NlndhCbV8BD4u2Sa6wQ6+QkTh6bDGZzCnhKnOg4B7ZN QuAIm8SZu+/ZIYpcJL5sPcoGYQtLvDq+BSjOAWRLS1w6agtR38wo8W3HHmaImgmMEnvWC0HY 1hKHj18EW8AswCfx7msPK0Qvr0RHG1SJh8T6dz+gxjtKdG3bxALx8RxGiRXdL1kmMEotYGRY xSiWWlCcm55abFhgrFecmFtcmpeul5yfu4kRHO9a5jsYN5zzOcQowMGoxMO7wWNulBBrYllx Ze4hRgkOZiUR3gj9e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 20180306144445epcas1p1b2dee15107098f5974e3c41403594ffc X-Msg-Generator: CA CMS-TYPE: 101P X-CMS-RootMailID: 20180306144445epcas1p1b2dee15107098f5974e3c41403594ffc X-RootMTR: 20180306144445epcas1p1b2dee15107098f5974e3c41403594ffc References: <1520347435-22970-1-git-send-email-b.zolnierkie@samsung.com> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP All SoCs use the same value (4) for the noise cancel mode so just make it explicit and remove parsing of samsung,tmu_noise_cancel_mode property. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz --- drivers/thermal/samsung/exynos_tmu.c | 10 ++++------ drivers/thermal/samsung/exynos_tmu.h | 3 --- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index 5877dd4..adfd9ef 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c @@ -168,6 +168,8 @@ #define EXYNOS_FIRST_POINT_TRIM 25 #define EXYNOS_SECOND_POINT_TRIM 85 +#define EXYNOS_NOISE_CANCEL_MODE 4 + #define MCELSIUS 1000 /** * struct exynos_tmu_data : A structure to hold the private data of the TMU @@ -386,10 +388,8 @@ static u32 get_con_reg(struct exynos_tmu_data *data, u32 con) con &= ~(EXYNOS_TMU_BUF_SLOPE_SEL_MASK << EXYNOS_TMU_BUF_SLOPE_SEL_SHIFT); con |= (pdata->gain << EXYNOS_TMU_BUF_SLOPE_SEL_SHIFT); - if (pdata->noise_cancel_mode) { - con &= ~(EXYNOS_TMU_TRIP_MODE_MASK << EXYNOS_TMU_TRIP_MODE_SHIFT); - con |= (pdata->noise_cancel_mode << EXYNOS_TMU_TRIP_MODE_SHIFT); - } + con &= ~(EXYNOS_TMU_TRIP_MODE_MASK << EXYNOS_TMU_TRIP_MODE_SHIFT); + con |= (EXYNOS_NOISE_CANCEL_MODE << EXYNOS_TMU_TRIP_MODE_SHIFT); return con; } @@ -1153,8 +1153,6 @@ static int exynos_of_sensor_conf(struct device_node *np, pdata->gain = (u8)value; of_property_read_u32(np, "samsung,tmu_reference_voltage", &value); pdata->reference_voltage = (u8)value; - of_property_read_u32(np, "samsung,tmu_noise_cancel_mode", &value); - pdata->noise_cancel_mode = (u8)value; of_property_read_u32(np, "samsung,tmu_efuse_value", &pdata->efuse_value); diff --git a/drivers/thermal/samsung/exynos_tmu.h b/drivers/thermal/samsung/exynos_tmu.h index a5d8c9c..b111a01 100644 --- a/drivers/thermal/samsung/exynos_tmu.h +++ b/drivers/thermal/samsung/exynos_tmu.h @@ -45,8 +45,6 @@ enum soc_type { * @reference_voltage: reference voltage of amplifier * in the positive-TC generator block * 0 < reference_voltage <= 31 - * @noise_cancel_mode: noise cancellation mode - * 000, 100, 101, 110 and 111 can be different modes * @efuse_value: platform defined fuse value * @min_efuse_value: minimum valid trimming data * @max_efuse_value: maximum valid trimming data @@ -57,7 +55,6 @@ enum soc_type { struct exynos_tmu_platform_data { u8 gain; u8 reference_voltage; - u8 noise_cancel_mode; u32 efuse_value; u32 min_efuse_value;