Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp1166131rwb; Wed, 28 Sep 2022 14:17:10 -0700 (PDT) X-Google-Smtp-Source: AMsMyM67w0H9mkfJ2dZenbwIu/8jfhSSqvSOYseEjZ1isDjFkmTsCd23U8uIGbKDQhAyb+Wp4Fnt X-Received: by 2002:a17:907:1ded:b0:76f:af8f:942e with SMTP id og45-20020a1709071ded00b0076faf8f942emr28789622ejc.120.1664399829849; Wed, 28 Sep 2022 14:17:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664399829; cv=none; d=google.com; s=arc-20160816; b=RRGPc/FiNmE5P/NpdwAIPntUrBcJKXD5wxmjzP3ieuNtyzPi0BQOCXsZQK6dgghS+2 aH5GDRdPTcZxV51FAvneds4gVGOER5VbIgrxm3mZ9/dIoI1OJuVfrdfvlfLsKpjv+XEZ S/UPnJqJd/x4WtiH9HgEArnjczjXR3VAf2l9Q41lJnBRBurtQiMMxhA0iXmJ1ZiIsX9l /n+GkdQPLQJoD7bCrm3dV2lshtFzA0k7R2CXBP3TihJCJBzKtyFy9kUnvSwCkjle6bYZ sOq49qbQHzDpN0rWih63gev9xXeRlCLWAYlxoOE3a0qbaGqjm1anm2Z8Bc1fArTdREzK ybhQ== 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=ra/NTmhquKOhfWDaPH89G/inBU26CJBLd7jC04RCLchM5WXYM2vdKBdKknkEm01XCy ckluG6tFiGPFb7v/mrTY8SK1RWzIUkQ7CI+PTEQkOAilj/GreW2wXW7VuNNeXcMEpFhc t5sqv/VsXuD5Ju6S/wEFyRQ0Nwp6/gonYNRw7OALWdeHvlg8yrYPhfIT5xQ3rwZsVSMC pYRt7FvhUNIxbctySZ28umyGSGHA94c1jEUKeH5A6Xfy5sLlz0JsfEGMVNNDN+/dRsO3 OyXCNIjQID9B3chtKbiQGWLwQusJX+n+TXh2D66ayz2DQA+nGrWLZyj+Ux7Ge3CGc4WI P35Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SHso3cVk; 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 dm4-20020a170907948400b0073064d1c27bsi5379984ejc.500.2022.09.28.14.16.42; Wed, 28 Sep 2022 14:17:09 -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=SHso3cVk; 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 S234021AbiI1VFJ (ORCPT + 99 others); Wed, 28 Sep 2022 17:05:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44868 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234494AbiI1VET (ORCPT ); Wed, 28 Sep 2022 17:04:19 -0400 Received: from mail-wr1-x430.google.com (mail-wr1-x430.google.com [IPv6:2a00:1450:4864:20::430]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 88CF8DDD81 for ; Wed, 28 Sep 2022 14:02:03 -0700 (PDT) Received: by mail-wr1-x430.google.com with SMTP id bk15so13844784wrb.13 for ; Wed, 28 Sep 2022 14:02:03 -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=SHso3cVk3QtQMcsPDoM7lPq2tpaKy5MkF2SAkytxXbqLl8v5pzT2ebw4HBjehLTvmh ZDkWG48CUmKv+XYQKHEZSOKNimHSX1KV7ZcPj0w087qCfdS2Zvj86MwNnOZ7vZ4zNDGn 56ZjCwef7LGV520iEaGUwq3MfNjnJnKUVBdZUnRLVU5XFS5TPJegbdsQWiRVVBI2lKr2 2zTTfuAv7myPLtGLVlZRM9uCd3oXpGR5r8WKSUQnIda0JIl0h39nvme4kb8PTRAmWD67 WdOd6XrdeJdO+OKBadlWHhqx8WffNLRoBAmLDHJFgFQyIeLd+vDrqy+cBqfLOjQCazqH nhsw== 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=OldHhSYG1d8aUhEW0vfcOQQkXQn2Qd7r+ab1Jkd3vZiNh4aWupPB58g78VhxiNiBr8 LUDqCmIJoNH20NnzvWb27MWs1o2CUfFwaTRxZuEdii+H2q7tqA7qUhE4o0O7Qu0qiWTr Agzy12wH4KVi+OPL1Ig7PnhSUWGd3f3HxstGKIp1uKr07d88rz7OMH8+6L++rnLA6D7s 5rf3muvcmYyl3ptH7GTVSNnWuceFeKSEoELUE5NOLczHgBlEvLj7LwzAhE80y23VPJw+ ws0dfcDoAU2GOdxggnY4nFxyDDSM9Urre4SDIwo8aZBtKJ2/wJ3tG3r/oW0sMgeGuqmv aBUQ== X-Gm-Message-State: ACrzQf2lHyq6zHSx+qmbcYsq5PDXYoKmmlRm0AsFFesEHRma6StPD78W c6lcOWo4gIB9tLg6iz2z1Ko9uA== X-Received: by 2002:adf:fb50:0:b0:22a:e4e9:a6b3 with SMTP id c16-20020adffb50000000b0022ae4e9a6b3mr21666572wrs.467.1664398922583; Wed, 28 Sep 2022 14:02:02 -0700 (PDT) Received: from mai.. ([2a05:6e02:1041:c10:48a2:39eb:9d1b:8b8d]) by smtp.gmail.com with ESMTPSA id g20-20020a05600c4ed400b003b4931eb435sm2874300wmq.26.2022.09.28.14.01.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Sep 2022 14:02:02 -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 v7 16/29] thermal/of: Remove of_thermal_get_ntrips() Date: Wed, 28 Sep 2022 23:00:46 +0200 Message-Id: <20220928210059.891387-17-daniel.lezcano@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220928210059.891387-1-daniel.lezcano@linaro.org> References: <20220928210059.891387-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=ham 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