From patchwork Wed Oct 21 16:42:29 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 286752 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5A370C55179 for ; Wed, 21 Oct 2020 16:42:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D5BC42177B for ; Wed, 21 Oct 2020 16:42:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="i0gAa5X6" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2409235AbgJUQmh (ORCPT ); Wed, 21 Oct 2020 12:42:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57646 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729371AbgJUQmh (ORCPT ); Wed, 21 Oct 2020 12:42:37 -0400 Received: from mail-wr1-x442.google.com (mail-wr1-x442.google.com [IPv6:2a00:1450:4864:20::442]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B69BDC0613CE for ; Wed, 21 Oct 2020 09:42:36 -0700 (PDT) Received: by mail-wr1-x442.google.com with SMTP id n6so3747757wrm.13 for ; Wed, 21 Oct 2020 09:42:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ktOQBsIi43nG8a2/21JQPeKNNuRP5PqTvkBAgWAn5tg=; b=i0gAa5X6lQdX9PQRLe+laWerY6VMaJl4dmiT6eFrLnTc2mxLVLmiMvAWGcvAnHcwx4 bRRsAi9yCpLOP6i5M1k46oXGtRSSFG50d2yRDnM3GpTKGjzsmZvi7RnjDvWU2vWQGe88 VzaMuPFNaxqlgjy5VXrpkhLGdYnX69HqlTMRgJg5VQF5t+OFCOFypTyytbfPIkrfxBFZ vJaqstRk6Qz7v1TQbN5K9qy2e8WBPScm5gEmXD4E8l1cRPGg0z1g9OLSdD82DY5g2/aG 9OuQm9Oo2M2Ul/rHhjpM3jLh4xOq+/ZhBLk4gBZ+oG6iFNcRpdJzO3+nMhM1u3bR6dhA GdAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ktOQBsIi43nG8a2/21JQPeKNNuRP5PqTvkBAgWAn5tg=; b=pJ/PRaVrzFzgUW0D8rDeen9uPMg5cvg0Wj111MCrVg7zpcoAC4A9egDEBJXRtwJ18O w5NwwjN2m3UA8+JRimTh6uq6VYfIEnuqiqrH9NQK1KJTlxtosr15J4jPYxF200pqxLG9 V/3AdgCzZCSC7P/BrQ2EzSG3jo931gZKlIPjkvzz+hVkbXfcpef0VOja92J7HjfQRmAi TQj/O0A8PWuAVyHnPwZR4+YyIzeCY2e4VhkzDtpNAu+JW91/b1N3VBEP6QnBBcN8pBDc ZRT7Jss79Rr5n7cVnzmgiJiZGmBT9KTywvgtRWoTvLiMqKuXWDYn4nRuFFGNzjGXpXOd +Fyw== X-Gm-Message-State: AOAM530d0BwtgyLF3R0zFyvQ0r9i5fLyczEVSxUJI5ntMdE/Cvro5eBR 0VOUrZDKLSIB/iOO7y76bkQCjQ== X-Google-Smtp-Source: ABdhPJwSC4b6Zp3WR/gk387RdiJewfMgrjpTyShE4TGDBNY3p53Pb4FZAnNyTZ++ZiVCeZuokVyJVg== X-Received: by 2002:adf:de91:: with SMTP id w17mr5681928wrl.84.1603298555294; Wed, 21 Oct 2020 09:42:35 -0700 (PDT) Received: from localhost.localdomain (58.164.185.81.rev.sfr.net. [81.185.164.58]) by smtp.gmail.com with ESMTPSA id a3sm5321724wrh.94.2020.10.21.09.42.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Oct 2020 09:42:34 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-pm@vger.kernel.org Cc: matthias.bgg@gmail.com, robh+dt@kernel.org, amitk@kernel.org, daniel.lezcano@linaro.org, rui.zhang@intel.com, Fabien Parent Subject: [PATCH 1/3] dt-bindings: thermal: mediatek: make resets property optional Date: Wed, 21 Oct 2020 18:42:29 +0200 Message-Id: <20201021164231.3029956-1-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org MT8516 Thermal IP does not support reset. Make the resets property optional in order to be able to support MT8516 SoC. Signed-off-by: Fabien Parent Acked-by: Rob Herring --- Documentation/devicetree/bindings/thermal/mediatek-thermal.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/thermal/mediatek-thermal.txt b/Documentation/devicetree/bindings/thermal/mediatek-thermal.txt index 1e249c42fae0..2d20f6b0dca0 100644 --- a/Documentation/devicetree/bindings/thermal/mediatek-thermal.txt +++ b/Documentation/devicetree/bindings/thermal/mediatek-thermal.txt @@ -20,12 +20,12 @@ Required properties: clocks are: "therm": Main clock needed for register access "auxadc": The AUXADC clock -- resets: Reference to the reset controller controlling the thermal controller. - mediatek,auxadc: A phandle to the AUXADC which the thermal controller uses - mediatek,apmixedsys: A phandle to the APMIXEDSYS controller. - #thermal-sensor-cells : Should be 0. See Documentation/devicetree/bindings/thermal/thermal-sensor.yaml for a description. Optional properties: +- resets: Reference to the reset controller controlling the thermal controller. - nvmem-cells: A phandle to the calibration data provided by a nvmem device. If unspecified default values shall be used. - nvmem-cell-names: Should be "calibration-data" From patchwork Wed Oct 21 16:42:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 286751 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-12.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 855B8C388F9 for ; Wed, 21 Oct 2020 16:42:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 26FCE2177B for ; Wed, 21 Oct 2020 16:42:42 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="rOtvEQOD" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2502591AbgJUQml (ORCPT ); Wed, 21 Oct 2020 12:42:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2441517AbgJUQmk (ORCPT ); Wed, 21 Oct 2020 12:42:40 -0400 Received: from mail-wr1-x443.google.com (mail-wr1-x443.google.com [IPv6:2a00:1450:4864:20::443]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D29B4C0613CE for ; Wed, 21 Oct 2020 09:42:39 -0700 (PDT) Received: by mail-wr1-x443.google.com with SMTP id g12so3786222wrp.10 for ; Wed, 21 Oct 2020 09:42:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=JS933voy/5ulGI3fj+GAntyF9rpzNqa0lFnIF6+V7Ss=; b=rOtvEQODVH17lLAdMVAKe/rIbWnNmfZ9BUkou7mb0yCv9F9XG8FRyBqy7VWOePZr3t B6bbFjV03umYPLuX1VcNKtC2+CLF3fFCFl2q6l/awYyDs/BPpvcVSF9hOKgrR5iLrW7b lEm+Km9Gh6CM0VkcmjHZOWplxr2pFhg6TscQAupU+C1yKCKQCW+rbog6Kl4pnvdbyEOn SzNZDXQVvd2fg/Ldq9HJBqhckN6lqdOML4KTnrtIsEdnInApEh5uCDhpgf7zIM3SZdVC WBK4gtXt1M8PfiI28v7ZS6ch4/9+wOq0c5udn+GBaDfNq9KzPkdqpzHy/MbqAzoo1fBS JMEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JS933voy/5ulGI3fj+GAntyF9rpzNqa0lFnIF6+V7Ss=; b=LeIxPkcVuJJt1b6mTX/UcllHbM2jS1Gzto6QNuUD+Y7XvieRW2hxvCNk8lBvJPT/U0 3PuTg6Jgs71PoFbs9gEk1CLvN9QI8sA9EQ6Y7ppH8+KqLKCxH2/XhIqkM9mfkDbaciEu 9cdpIbnfr7iQ1324lGTOmS0V450tQMLglWsWnVZ/wz7tLm5oFvLCbH0Dv8mGgvgBKx9D aTFG27/p7hLt+z2ynFWkPei3sDFiPw3/vaxYJ29cRsqwyxZ7BTsTbIzRmtzMEVNYyfXz 0gJMc1B9tK8BQ7i0iS6UOXXXhlKc7QSeyw0uuu6jpa4RgHaWThpqChzzv7ocNAiSpgoM NMaA== X-Gm-Message-State: AOAM532yOZefWTZQ9RTiWd8VenehZXKlenqfE2Z7OmjHZLhPDcOoSLh9 q4tvr2T7m0Y8hnAyAoqRb4rp4g== X-Google-Smtp-Source: ABdhPJyYyY/I9sCo3RstG+oqSDx3Z55fChra8Y/tiA2UQ+4pfA1kyDm2nohjoWskkdTymeEFd2UeCA== X-Received: by 2002:adf:fac3:: with SMTP id a3mr5613554wrs.240.1603298558589; Wed, 21 Oct 2020 09:42:38 -0700 (PDT) Received: from localhost.localdomain (58.164.185.81.rev.sfr.net. [81.185.164.58]) by smtp.gmail.com with ESMTPSA id a3sm5321724wrh.94.2020.10.21.09.42.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Oct 2020 09:42:37 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-pm@vger.kernel.org Cc: matthias.bgg@gmail.com, robh+dt@kernel.org, amitk@kernel.org, daniel.lezcano@linaro.org, rui.zhang@intel.com, Fabien Parent Subject: [PATCH 3/3] thermal: mtk_thermal: make device_reset optional Date: Wed, 21 Oct 2020 18:42:31 +0200 Message-Id: <20201021164231.3029956-3-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201021164231.3029956-1-fparent@baylibre.com> References: <20201021164231.3029956-1-fparent@baylibre.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org MT8516 does not support thermal reset. Use device_reset_optional instead of device_reset. Signed-off-by: Fabien Parent Reviewed-by: Matthias Brugger --- drivers/thermal/mtk_thermal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/thermal/mtk_thermal.c b/drivers/thermal/mtk_thermal.c index 0bd7aa564bc2..149c6d7fd5a0 100644 --- a/drivers/thermal/mtk_thermal.c +++ b/drivers/thermal/mtk_thermal.c @@ -1052,7 +1052,7 @@ static int mtk_thermal_probe(struct platform_device *pdev) return -EINVAL; } - ret = device_reset(&pdev->dev); + ret = device_reset_optional(&pdev->dev); if (ret) return ret;