From patchwork Thu Apr 26 11:51:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartlomiej Zolnierkiewicz X-Patchwork-Id: 10365735 X-Patchwork-Delegate: eduardo.valentin@ti.com 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 40B37601BE for ; Thu, 26 Apr 2018 11:52:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 328541FF82 for ; Thu, 26 Apr 2018 11:52:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2736527F9F; Thu, 26 Apr 2018 11:52:12 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI 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 BBC9A1FF82 for ; Thu, 26 Apr 2018 11:52:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755063AbeDZLwJ (ORCPT ); Thu, 26 Apr 2018 07:52:09 -0400 Received: from mailout2.samsung.com ([203.254.224.25]:48561 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755542AbeDZLwF (ORCPT ); Thu, 26 Apr 2018 07:52:05 -0400 Received: from epcas2p1.samsung.com (unknown [182.195.41.53]) by mailout2.samsung.com (KnoxPortal) with ESMTP id 20180426115203epoutp029d745016b623198971de3498b218ef3e~o_if_s3Bi1577015770epoutp02P; Thu, 26 Apr 2018 11:52:03 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.samsung.com 20180426115203epoutp029d745016b623198971de3498b218ef3e~o_if_s3Bi1577015770epoutp02P DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1524743523; bh=GLwGuaOE7QjptGakq7QzVpGGXoG9gTCPfldXaq8SxSM=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=J67FHDxqW62+AKnoIbhUN0MBz+UJuC1D6EmBwNCnW+etuLl9zzatpaqrU/8mtcWHV 7fecRgYMREjP9HYMZWWISbl5QJH0hdPKMAmovwwm1OwWK15umXIeve5P/h+h1ZZwsd SkRxtXxNLXGGhQBdfAz2aqv5LOWCfQiAQVlmMhEA= Received: from epsmges2p4.samsung.com (unknown [182.195.42.72]) by epcas2p1.samsung.com (KnoxPortal) with ESMTP id 20180426115203epcas2p1c6beaa1412ecbf9dd9c9090bddfa4f3e~o_ifmwgiz2422624226epcas2p12; Thu, 26 Apr 2018 11:52:03 +0000 (GMT) Received: from epcas2p3.samsung.com ( [182.195.41.55]) by epsmges2p4.samsung.com (Symantec Messaging Gateway) with SMTP id 9C.94.04079.26DB1EA5; Thu, 26 Apr 2018 20:52:03 +0900 (KST) Received: from epsmgms2p2new.samsung.com (unknown [182.195.42.143]) by epcas2p1.samsung.com (KnoxPortal) with ESMTP id 20180426115201epcas2p17e5cdb0f79927903880e58c290b663e6~o_ieSUfns1413414134epcas2p1u; Thu, 26 Apr 2018 11:52:01 +0000 (GMT) X-AuditID: b6c32a48-c31ff70000000fef-de-5ae1bd62403e Received: from epmmp2 ( [203.254.227.17]) by epsmgms2p2new.samsung.com (Symantec Messaging Gateway) with SMTP id DC.2B.03817.16DB1EA5; Thu, 26 Apr 2018 20:52:01 +0900 (KST) Received: from AMDC3058.DIGITAL.local ([106.120.53.102]) by mmp2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0P7S00GD7JMBQG00@mmp2.samsung.com>; Thu, 26 Apr 2018 20:52:01 +0900 (KST) From: Bartlomiej Zolnierkiewicz To: Eduardo Valentin Cc: Zhang Rui , linux-samsung-soc@vger.kernel.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, b.zolnierkie@samsung.com Subject: [PATCH 01/18] thermal: exynos: fix setting rising_threshold for Exynos5433 Date: Thu, 26 Apr 2018 13:51:16 +0200 Message-id: <1524743493-28113-2-git-send-email-b.zolnierkie@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1524743493-28113-1-git-send-email-b.zolnierkie@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrFIsWRmVeSWpSXmKPExsWy7bCmuW7y3odRBsdamS02zljPajH/yjVW i8u75rBZfO49wmgx4/w+JosnD/vYHNg8ds66y+6xeM9LJo++LasYPT5vkgtgieKySUnNySxL LdK3S+DKuP26kalgJ1vF1+bX7A2M+1m7GDk5JARMJHrbr7GD2EICOxgluh7ydzFyAdnfGSX2 nbnICFPU+fQmI0RiA6PE4abnLBDOL0aJYy132UCq2ASsJCa2rwLrEBHQkjhxaTsTSBGzwBxG iVkNu4E6ODiEBUIluuaFg9SwCKhKPOrdyQJi8wp4SEzf8pkJYpucxMljk8HO4xTwlLhwpAls mYTAX1aJHfvesEAUuUicX/2XGcIWlnh1fAs7hC0t8WzVRkaIhmZGiW879kAVTWCU2LNeCMK2 ljh8/CLYBmYBPomOw3/ZQY6TEOCV6GiDKvGQWP7kC9T7jhJ3nh2Feh/omdaP59gnMEotYGRY xSiWWlCcm55abFRgolecmFtcmpeul5yfu4kRHINaHjsYD5zzOcQowMGoxMMbsPBBlBBrYllx Ze4hRgkOZiUR3vjWh1FCvCmJlVWpRfnxRaU5qcWHGKU5WJTEeRt8z0QJCaQnlqRmp6YWpBbB ZJk4OKUaGB1yl915UzZbNi7ji6Qeq97emN9bbhQW1i46+djn9mXOBTs/Ve14prqtcOJN502q E/+9yGRj8NhmUc5a87axTlZVjamTmcuKL9vv17dfE08IfStq/nVTcU3liRfiZ9RtskMu7BfN DzfuCz/qwNP4Ys+LPdu35Szf96/6+0m5IAv9FJ2qFF+DxUosxRmJhlrMRcWJAF5EKUu9AgAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpiluLIzCtJLcpLzFFi42I5/e+xoG7i3odRBusXa1hsnLGe1WL+lWus Fpd3zWGz+Nx7hNFixvl9TBZPHvaxObB57Jx1l91j8Z6XTB59W1YxenzeJBfAEsVlk5Kak1mW WqRvl8CVcft1I1PBTraKr82v2RsY97N2MXJySAiYSHQ+vcnYxcjFISSwjlFi5pclLBDOL0aJ VfPOMoJUsQlYSUxsXwVmiwhoSZy4tJ0JpIhZYA6jxPMVc4AcDg5hgVCJrnnhIDUsAqoSj3p3 soDYvAIeEtO3fGaC2CYncfLYZLDNnAKeEheONIHVCAHV3O97zzaBkWcBI8MqRsnUguLc9Nxi owKjvNRyveLE3OLSvHS95PzcTYzAkNl2WKt/B+PjJfGHGAU4GJV4eAMWPogSYk0sK67MPcQo wcGsJMIb3/owSog3JbGyKrUoP76oNCe1+BCjNAeLkjgvf/6xSCGB9MSS1OzU1ILUIpgsEwen VANjrYObvcfuS9qRZe+4LDc/2cax1INf4JHsd1lnhiXnri3S2vOqKinSbmprUBu7ZNbJ7ll9 Zlad4al80hmJm79b1vduuZm4WCO95YKfcopfeVfi4mKDgoUFM0UuhpRbBOg9/xm/w/SBz+TH z9Pn/tI/FbrwhdSam6WmBd9EzmsmyfTNjpz6VF+JpTgj0VCLuag4EQAVwAHjFQIAAA== X-CMS-MailID: 20180426115201epcas2p17e5cdb0f79927903880e58c290b663e6 X-Msg-Generator: CA CMS-TYPE: 102P X-CMS-RootMailID: 20180426115201epcas2p17e5cdb0f79927903880e58c290b663e6 X-RootMTR: 20180426115201epcas2p17e5cdb0f79927903880e58c290b663e6 References: <1524743493-28113-1-git-send-email-b.zolnierkie@samsung.com> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add missing clearing of the previous value when setting rising temperature threshold. Signed-off-by: Bartlomiej Zolnierkiewicz --- drivers/thermal/samsung/exynos_tmu.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index cda716c..523d26e 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c @@ -577,6 +577,7 @@ static int exynos5433_tmu_initialize(struct platform_device *pdev) threshold_code = temp_to_code(data, temp); rising_threshold = readl(data->base + rising_reg_offset); + rising_threshold &= ~(0xff << j * 8); rising_threshold |= (threshold_code << j * 8); writel(rising_threshold, data->base + rising_reg_offset);