Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp828781imm; Wed, 17 Oct 2018 08:56:58 -0700 (PDT) X-Google-Smtp-Source: ACcGV617918fBx4fR5FNvdIoo0uZEMgHP+KJ5FjbqpmUMt3ltU4+5YgJ3PTG/oCA+FhCF8TYn9yP X-Received: by 2002:a17:902:2867:: with SMTP id e94-v6mr13278621plb.317.1539791818792; Wed, 17 Oct 2018 08:56:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539791818; cv=none; d=google.com; s=arc-20160816; b=nFXQJRxZRxyXgGvF8xlbemJRq+GL45ckelF/qhxlRH1RZMQL2mwRMbJwSXfPMwd9vo fHzlYYkQoc4Paf+D8UDrRW5hy1TuSY9Lo73oAw8Q3wvKCUphtYWplRzKxsJKv5wHtVjm OF18AU5WLbFDosidNrvGowTjjN83JhJY3u8JICzdP0BCcvh62M76AHAwaDGWSf1FrHVo ujzuJvf54+mQg6yrBcVe9Q0OS53247y/SDodvwr3z8bm/8t3flc1t7CQrTZZdvRsNAyC +NVA9BEY4sUMjfFfP+nhgCCebpU0Ywxg0s0z+kTtkUQ3iKU49vnM13GkndU8Wb2Y/oJL XZ2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:cms-type:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature:dkim-filter; bh=U1IhVFsSqW2TG06k3HCt9gp0mnPHXvzkI3ko6pz8vZs=; b=KArCaa+ye4eWQRLgQGtPRoheBQYjjkKEwBKOFcPebXY94yfl2NWZbOwqZQM3k9Koed hZE+91Skv6QNIDvrfRhz7e5evyl/gfCqd65MApdNAE7zwqsM5n/rtOEp0DJFXcWUUIlP wVSD9tolFQFIHiDvRvNSITyZ5hQylevQ9Nf0/F6ooNIxQfIjYAzgzYeT3cZTwocdAQBb zjmd8+p3/vsY6wuvBomPUtOfE7otsRMmRjPCPzwUYdxt9YHcxBVNS4r1EYB5JkT0ea6O h0C0lbpQkwGYa1rKUq66/AHlcZ5T25VYdgzwvBv//8rxJFrtrQGYBESj0btNwrqTNXJ9 NXTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=MZIdGFi5; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v4-v6si18410990plb.384.2018.10.17.08.56.43; Wed, 17 Oct 2018 08:56:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=MZIdGFi5; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728113AbeJQXux (ORCPT + 99 others); Wed, 17 Oct 2018 19:50:53 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:63400 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727013AbeJQXuw (ORCPT ); Wed, 17 Oct 2018 19:50:52 -0400 Received: from epcas2p2.samsung.com (unknown [182.195.41.54]) by mailout1.samsung.com (KnoxPortal) with ESMTP id 20181017155430epoutp018e84d6d39ec6a3c6e95cc037bc3b043b~ecF29lpfw3012130121epoutp01D; Wed, 17 Oct 2018 15:54:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.samsung.com 20181017155430epoutp018e84d6d39ec6a3c6e95cc037bc3b043b~ecF29lpfw3012130121epoutp01D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1539791670; bh=U1IhVFsSqW2TG06k3HCt9gp0mnPHXvzkI3ko6pz8vZs=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=MZIdGFi5liua3bG5uUyQVdUMynBrvfKJvDRLzTbruoAy6XVNquCV0pigXbbAxBRdN ls9TBK5xMIysjiZqwoAVIh2RmVrmTXZ/gUAnCJsO3Ho/+RJPqr5WwGvZUFQ0dK/s2n +ecKWn/XCk9G4IS39YOwyKISLOEXOOfkpir3eTPo= Received: from epsmges2p4.samsung.com (unknown [182.195.42.72]) by epcas2p4.samsung.com (KnoxPortal) with ESMTP id 20181017155429epcas2p4248d231b6e5ebae6c9df0f02b411546a~ecF18wDyQ0750407504epcas2p4V; Wed, 17 Oct 2018 15:54:29 +0000 (GMT) Received: from epcas2p2.samsung.com ( [182.195.41.54]) by epsmges2p4.samsung.com (Symantec Messaging Gateway) with SMTP id D3.5F.04069.53B57CB5; Thu, 18 Oct 2018 00:54:29 +0900 (KST) Received: from epsmgms2p2new.samsung.com (unknown [182.195.42.143]) by epcas2p1.samsung.com (KnoxPortal) with ESMTP id 20181017155428epcas2p1aca0b5e7b30b89db7be7026dfa740fc6~ecF1IC3ZR2791227912epcas2p1Q; Wed, 17 Oct 2018 15:54:28 +0000 (GMT) X-AuditID: b6c32a48-e59ff70000000fe5-21-5bc75b35ce67 Received: from epmmp2 ( [203.254.227.17]) by epsmgms2p2new.samsung.com (Symantec Messaging Gateway) with SMTP id F7.44.03633.43B57CB5; Thu, 18 Oct 2018 00:54:28 +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 <0PGR00KZM2SD3M00@mmp2.samsung.com>; Thu, 18 Oct 2018 00:54:28 +0900 (KST) From: Bartlomiej Zolnierkiewicz To: Zhang Rui , Eduardo Valentin Cc: Amit kucheria , Eric Anholt , Stefan Wahren , Markus Mayer , bcm-kernel-feedback-list@broadcom.com, Heiko Stuebner , Thierry Reding , Jonathan Hunter , Keerthy , Masahiro Yamada , Jun Nie , Baoyou Xie , Shawn Guo , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, b.zolnierkie@samsung.com Subject: [PATCH v2 12/17] thermal: exynos: enable+check sensor after its setup is finished Date: Wed, 17 Oct 2018 17:52:38 +0200 Message-id: <1539791563-5959-13-git-send-email-b.zolnierkie@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1539791563-5959-1-git-send-email-b.zolnierkie@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAAzWSa0hTYRjHfbezs7PZ5DBN3zSsFhIKWYnG25UgPxyywE9dXGWHdpiSm7Iz Jf1QpuUNp+WMeVmz1EyGlxzLTbPwumXkogyz0tVKzC5YtEDSwtyOfvv/n+f/8HseeAi+tEgQ TqSrtYxGTWfIcDHWPRS9e3uC3Cnf+du2HhXmN/FQV02nAM16nQC160Yw1PBqQoD6r4wDtPzx mwA9tRXw0NW6Rgw1z3iEaLzXiCOvbhgg4/w7IZrxVOBozhqGLK2TOPrTa8LQI7cXHJJSBT8c OFX3fgyneuqmhdSDtwlUU98XHmUxl+LU1EQfTukK53GqwmoGlG3CxKeeGBYwyjlp41FeS2Sy JEW8X8FkpOcwmh0Hz4nTBjp6+Fk14ot6nR3LBy6iDIgISMbD6govvwyICSlpB3DIWQ84swCg y9gtWEt9vuPBucZ9AMvdvRhnFgEs7O/AfSmc3AtvFJtXxgkihEyC1jY/gk+OYPCTN9qng8nT cE7fjfk0RkbBxp8DQp+WkBRcbO3jcbBIOOrQ+8Gilbpr+bYfDEmTEA7rDUIulAgnizpWdTD8 6rSu6gg4a+4C3IABwO+LdzHOdALY9syxiti3cugLAbdeECwZ+if0bQ1JCSwpknIRCv6d0/G4 K+sBdBjHBNfBhtsgwAxCmSxWpWTYuKz4WJZWsdlqZez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+57AtL0EUB+7q2HQsX16yRktv26dX5ZS7l F6XrPDklEnrW96QG5K6cL3CIv2J5yd84DSldI6Ub+js3rVRiKc5INNRiLipOBADFkLNLewIA AA== X-CMS-MailID: 20181017155428epcas2p1aca0b5e7b30b89db7be7026dfa740fc6 X-Msg-Generator: CA CMS-TYPE: 102P X-CMS-RootMailID: 20181017155428epcas2p1aca0b5e7b30b89db7be7026dfa740fc6 References: <1539791563-5959-1-git-send-email-b.zolnierkie@samsung.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Enable sensor after doing chipset specific initialization operation and check sensor after doing chipset specific control operation. Signed-off-by: Bartlomiej Zolnierkiewicz --- drivers/thermal/samsung/exynos_tmu.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index 8ec74a62..796a868 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c @@ -1109,15 +1109,14 @@ static int exynos_tmu_probe(struct platform_device *pdev) goto err_sclk; } - thermal_zone_set_mode(data->tzd, THERMAL_DEVICE_ENABLED); - thermal_zone_device_check(data->tzd); - ret = exynos_tmu_initialize(pdev); if (ret) { dev_err(&pdev->dev, "Failed to initialize TMU\n"); goto err_thermal; } + thermal_zone_set_mode(data->tzd, THERMAL_DEVICE_ENABLED); + ret = devm_request_irq(&pdev->dev, data->irq, exynos_tmu_irq, IRQF_TRIGGER_RISING | IRQF_SHARED, dev_name(&pdev->dev), data); if (ret) { @@ -1126,6 +1125,9 @@ static int exynos_tmu_probe(struct platform_device *pdev) } exynos_tmu_control(pdev, true); + + thermal_zone_device_check(data->tzd); + return 0; err_thermal: -- 1.9.1