Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp2558992rwb; Mon, 3 Oct 2022 02:32:55 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5X+IWNXRZhLOhaykLM0+j9NsbklKdCSBlHVErlG62HCjXo3wypcJdXgFnwAN0jhf3slHFH X-Received: by 2002:a05:6402:35d6:b0:44e:f45a:8f79 with SMTP id z22-20020a05640235d600b0044ef45a8f79mr17964833edc.393.1664789575042; Mon, 03 Oct 2022 02:32:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664789575; cv=none; d=google.com; s=arc-20160816; b=Z8W/SGlyGLUuu5d2SUjxgdW5gPwyQGW8kNBmNXy71jaURdxczpRUEToXcG4yf6+PAJ 24vnloa5cKvSeY14oU2eAd8Yq3VFPjDxapYNql6M0dILiqdSQZXyKUdsUCCcEEfyZ+wh OX9Wtm3FfM0mEBsDxbZ1DEgChUK9Jl5njpMLvtDrmbJC71J9mpkVt1I4OXaOqhraIYw+ b+yMMgFxYUof+74JXhlIFCL56yh7l2M4iGi9rc2Stt0bp7swE9Yg9UodNWHHDPJstJ+u 73bOWx2tK/23q0AyI6vIgtBnbqo+R095H/BkocnkgWNYxcUrYYAjxx5oN4/fK02JVQKt 7BLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=G/YO0fJeKfkSzRqdgqFU3ij4yJaDOnZPHmbsRpXJf/A=; b=dfKNjTutq495GgkuwEvLDnSkf89yj6q8IKhPFZWSkh6v5Wm6TOB4qjI7hIpa3Ob1mI TLGVL3CFwcvysDwx9+/ND0ZwvZ4Cb+WAVF0BnKEENhSy/71DLbtZX3M4MAx1Zd8z7N3r COXB+MY8PXgVdtHm87P/AAAfqUYGeOU0CRhSvqnMgSwhuzrlUP7Tjzc+aZ9oQDdTEnle 9zuP4zM1+Rm2ONebzYt73OjAukgkUHoQa68qCO5To7sCH/31JnAnAK++N/Xpbts+f0m5 TDhlahEsuvYUUFFGvp+xGVcTZDAOmMSSdnyPNTXXM52hmTwminDGUd7zrKvJ66sMP9vp ZVYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=m8PGB4q8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d28-20020a056402517c00b00456c221ffd5si6819236ede.478.2022.10.03.02.32.22; Mon, 03 Oct 2022 02:32:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=m8PGB4q8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229685AbiJCJ37 (ORCPT + 99 others); Mon, 3 Oct 2022 05:29:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57458 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231602AbiJCJ2M (ORCPT ); Mon, 3 Oct 2022 05:28:12 -0400 Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8A9F0474FF for ; Mon, 3 Oct 2022 02:27:08 -0700 (PDT) Received: by mail-wr1-x429.google.com with SMTP id bq9so15789250wrb.4 for ; Mon, 03 Oct 2022 02:27:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=G/YO0fJeKfkSzRqdgqFU3ij4yJaDOnZPHmbsRpXJf/A=; b=m8PGB4q8KhZuJG6l/iwZ3mhCBCZ/XAWQq4HqyyeOlZmJsxaKnDIAvHfvP2B8cpfI+q YM3K1cyu4sxjpaAmCPBWvKeeLa1EEb6ZJka1ItuxPrMZjKEz4ETXfhJIEemzcWj0kgOo 2KT0FPG0besMn6ElRxhEiGyzaGdQKW034dZ8e78COMrF9oCqOLlC/zD6Ee37125Ew5kC eHySFW2YcmjFQ7yyql3CyGezaW6mb/IC6/a2GHQLVO/CebhgzwsMSL95rI42xQdFf75t azAlJ7AqS+tkSm4dNRK7WkHqo2z2tdE2lgmIbaWzQFs8BSmD9yfLseDkCDgSJ6HOiUMe /HRg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=G/YO0fJeKfkSzRqdgqFU3ij4yJaDOnZPHmbsRpXJf/A=; b=mKSrm0+DOTBUL1tAnYEr72Yl8Lhbh+SNVbrExOKDlViLXOcFgcQeAGUP/6l973W1Am MOkDw7yTa7rh8otkCpvNv2Kfrtv6hUqTORjyxYWonknB05hlJDpLOTwPag9xEiPeQ9dp rKnBYpVhtQJVgANORoatSb4IXS4OSHJxr5dWECTcTvJVI5jKlrJr3J8fsWCD9bM1zgQa CFXG2862VDFawGaPpP9mDxgWqEfa/SMNMkV8vxFolDGGRVAwBSPN4jnJy25S8AQBquUn FZx9fXl6FM9TJkZ62ZIVjisDvjtaJEPO/IcnJ3W9Wkk8WnmU1tusYEPOZeNUq7n6Kq6H TsoQ== X-Gm-Message-State: ACrzQf3At5FSEXd5BNvN2+k/h67WCRLGqjIq7UY/siMUSx5LvIUZ1Zr6 tSpLUGDSc3a+WZCN+CU4gWVAMg== X-Received: by 2002:a5d:56c8:0:b0:22e:32c5:d397 with SMTP id m8-20020a5d56c8000000b0022e32c5d397mr4824209wrw.462.1664789227584; Mon, 03 Oct 2022 02:27:07 -0700 (PDT) Received: from mai.. ([2a05:6e02:1041:c10:f3a:9f5e:1605:a75a]) by smtp.gmail.com with ESMTPSA id ay3-20020a5d6f03000000b0022cc157bf26sm9707520wrb.85.2022.10.03.02.27.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 03 Oct 2022 02:27:07 -0700 (PDT) From: Daniel Lezcano To: daniel.lezcano@linaro.org, rafael@kernel.org Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, rui.zhang@intel.com, Raju Rangoju , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Peter Kaestle , Hans de Goede , Mark Gross , Miquel Raynal , Amit Kucheria , Nicolas Saenz Julienne , Broadcom Kernel Team , Florian Fainelli , Ray Jui , Scott Branden , Support Opensource , Lukasz Luba , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Thara Gopinath , Andy Gross , Bjorn Andersson , =?UTF-8?q?Niklas=20S=C3=B6derlund?= , Bartlomiej Zolnierkiewicz , Krzysztof Kozlowski , Alim Akhtar , Thierry Reding , Jonathan Hunter , Eduardo Valentin , Keerthy , Kunihiko Hayashi , Masami Hiramatsu , Antoine Tenart , Srinivas Pandruvada , Dmitry Osipenko , netdev@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-tegra@vger.kernel.org, linux-omap@vger.kernel.org Subject: [PATCH v8 16/29] thermal/of: Remove of_thermal_get_ntrips() Date: Mon, 3 Oct 2022 11:25:49 +0200 Message-Id: <20221003092602.1323944-17-daniel.lezcano@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221003092602.1323944-1-daniel.lezcano@linaro.org> References: <20221003092602.1323944-1-daniel.lezcano@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The thermal OF code uses the generic trip points to initialize the thermal zone. Consequently thermal_zone_get_num_trips() can be used and the of_thermal_get_ntrips() is no longer needed. Remove it. Signed-off-by: Daniel Lezcano --- drivers/thermal/thermal_core.h | 5 ----- drivers/thermal/thermal_of.c | 16 ---------------- 2 files changed, 21 deletions(-) diff --git a/drivers/thermal/thermal_core.h b/drivers/thermal/thermal_core.h index c5990a3fcf8a..b00fc1913734 100644 --- a/drivers/thermal/thermal_core.h +++ b/drivers/thermal/thermal_core.h @@ -139,13 +139,8 @@ thermal_cooling_device_stats_update(struct thermal_cooling_device *cdev, /* device tree support */ #ifdef CONFIG_THERMAL_OF -int of_thermal_get_ntrips(struct thermal_zone_device *); bool of_thermal_is_trip_valid(struct thermal_zone_device *, int); #else -static inline int of_thermal_get_ntrips(struct thermal_zone_device *tz) -{ - return 0; -} static inline bool of_thermal_is_trip_valid(struct thermal_zone_device *tz, int trip) { diff --git a/drivers/thermal/thermal_of.c b/drivers/thermal/thermal_of.c index 2f533fc94917..89afa59c4915 100644 --- a/drivers/thermal/thermal_of.c +++ b/drivers/thermal/thermal_of.c @@ -19,22 +19,6 @@ #include "thermal_core.h" -/** - * of_thermal_get_ntrips - function to export number of available trip - * points. - * @tz: pointer to a thermal zone - * - * This function is a globally visible wrapper to get number of trip points - * stored in the local struct __thermal_zone - * - * Return: number of available trip points, -ENODEV when data not available - */ -int of_thermal_get_ntrips(struct thermal_zone_device *tz) -{ - return tz->num_trips; -} -EXPORT_SYMBOL_GPL(of_thermal_get_ntrips); - /** * of_thermal_is_trip_valid - function to check if trip point is valid * -- 2.34.1