Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2658878imj; Mon, 11 Feb 2019 06:36:12 -0800 (PST) X-Google-Smtp-Source: AHgI3IZc/MAWXsezFTjBT3hBNkVXD5YyJ+sfHpx2bsNvmRkXOMXuqS9ZpUprarBf2gY51gdUgZS+ X-Received: by 2002:a63:fc4d:: with SMTP id r13mr34084007pgk.242.1549895771960; Mon, 11 Feb 2019 06:36:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549895771; cv=none; d=google.com; s=arc-20160816; b=sOBjJwdb/OKa/q8OwCq7p3NtAWBmjDzkqWQAIumX9MbWcEGQ+QR2KmyRGFrBNo8XuJ qgLyTAggN0rTYxzOxdWf9IFQ6TiDWh3Nn8s/c4cKmdI0Gxy4tnFtKHhjK78IAs4BwAyD jjpKY7ASjAApkbqYedp/9bvihHnwprDfkxrKLKK/xTY99VHM4+XLal9uj1wuzOdqEd/s uihu6pqSEL6EHS1qqsCuyWW8o7TRlrfcT/rCNcbuHFRPmq2guzYNEEFvMaK9GMQUkR0D 47be4jGG7IadKvJM2hWrga1sp/FixLX87skg+UzpUgXe6O5EPRKf5oIodkz1zRDlKZU3 wwrA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Qg7HCej80YUGDJkK9tbb3WxFsvT1KUCfdbPJDw4kSDM=; b=yRWNebl3JEMO6vCUzi51DK7mFsl3oSCMq0IftqfOESs8C/PhfKekbbfdmQu2r7sHiF Fatd1vVMTPpQYsDOjUGDTM5h8z1sMNO1yVLlCMM9eLI8/OHgivaDLQ6IxgHejhuXrhjz J5BTaJ8m8ndjQD1cBUVdHDHsnQfbSSBBQUqWLJbb2VMnAeIYdBEB7P/Y925G9PiZ4q85 sO6whbFyseOM+mhaRB2SZxW7SI8NM7GrRACh2YOLiXwmGQzZbvwYYLX0Zg+OJCJVAWop 8FkQCULYLKlDGmEMsy5YoDYwUC+xNa7S7d64lHK7qb03p6lVuiwAYXaCsxCUBTtp4EZ5 vZDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=lwNGq576; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 34si5607115pgn.141.2019.02.11.06.35.55; Mon, 11 Feb 2019 06:36:11 -0800 (PST) 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=@kernel.org header.s=default header.b=lwNGq576; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730789AbfBKOeK (ORCPT + 99 others); Mon, 11 Feb 2019 09:34:10 -0500 Received: from mail.kernel.org ([198.145.29.99]:42270 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730784AbfBKOeH (ORCPT ); Mon, 11 Feb 2019 09:34:07 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1AB9920844; Mon, 11 Feb 2019 14:34:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549895646; bh=INa4LW+sgyDef/HCjlcZT9AOPjH2urDQyvm+KbDyg+o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lwNGq576bPU10RANnL3IIpbeaG1c1AAGAipUiZJhz77dWXvZEsEEEYNFrfvAdOLqZ F7gzK0JdNMB88zfKdrY7IHQ8iskYHREaPdO9eDboP1d2VzbLlWNyvZbH+A9d/03e8E 38P7l1b9PRbUXZ8KHsfB14ETVj5VZGPDIZ9SQyzA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Matthias Brugger , Stefan Wahren , Eduardo Valentin , Sasha Levin Subject: [PATCH 4.20 274/352] thermal: bcm2835: enable hwmon explicitly Date: Mon, 11 Feb 2019 15:18:21 +0100 Message-Id: <20190211141904.405860821@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190211141846.543045703@linuxfoundation.org> References: <20190211141846.543045703@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.20-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit d56c19d07e0bc3ceff366a49b7d7a2440c967b1b ] By defaul of-based thermal driver do not enable hwmon. This patch does this explicitly, so that the temperature can be read through the common hwmon sysfs. Signed-off-by: Matthias Brugger Acked-by: Stefan Wahren Signed-off-by: Eduardo Valentin Signed-off-by: Sasha Levin --- drivers/thermal/broadcom/bcm2835_thermal.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/thermal/broadcom/bcm2835_thermal.c b/drivers/thermal/broadcom/bcm2835_thermal.c index b9d90f0ed504..720760cd493f 100644 --- a/drivers/thermal/broadcom/bcm2835_thermal.c +++ b/drivers/thermal/broadcom/bcm2835_thermal.c @@ -18,6 +18,8 @@ #include #include +#include "../thermal_hwmon.h" + #define BCM2835_TS_TSENSCTL 0x00 #define BCM2835_TS_TSENSSTAT 0x04 @@ -266,6 +268,15 @@ static int bcm2835_thermal_probe(struct platform_device *pdev) platform_set_drvdata(pdev, tz); + /* + * Thermal_zone doesn't enable hwmon as default, + * enable it here + */ + tz->tzp->no_hwmon = false; + err = thermal_add_hwmon_sysfs(tz); + if (err) + goto err_tz; + bcm2835_thermal_debugfs(pdev); return 0; -- 2.19.1