Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp69843rwb; Mon, 26 Sep 2022 09:23:35 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7sboKqlEZDAKvvTsWHMQp9fuzz4qzBBmsD6v3veYcT6WMsiCxpnmx5enttmqdJC8cQHejd X-Received: by 2002:a65:408b:0:b0:42a:55fb:60b0 with SMTP id t11-20020a65408b000000b0042a55fb60b0mr20677328pgp.431.1664209414865; Mon, 26 Sep 2022 09:23:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664209414; cv=none; d=google.com; s=arc-20160816; b=F4F96m6JKdvUzupQpSlJ53IykDZJZi1BPPgsIxHe4DL/GqKQH8+ij6PTHJPpTDWmE1 Ixt4bpLIqBkuxPFb0UcjTF7E7Smdd4uCmmSrURfwRt/JPrrE6EcjaMEovW+OTxQ6wpzX 62LKzRxIaHQzgN2hI0aTvEyBxKOKoJFBZs6qQCyJWgLfY8milDWQEcwhRUXq24qm+Or3 yWyTi476OjmPHCKaA+iyBF8MzVqFzjN1XMgjP7hr3p84IdC1AK/2RXArRx0kJpjXkJoV K2NWbBzVWisoaFjAHMNZ+76Mao5fFCrX2NpvpwiXREK4CNmFH5xhWGaaN8NtTbV1MTHa 7RnA== 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=OHXbaNWdyZ0Wkkc1xL/nI14ReQ0AVnlGlwSXS+lV7dA=; b=mI3GI9Q894v5TUSBxdjzTWYdHxegOFEwoXGLitEax/jjN+gEwKUXAgrFcsjkGM8Xrl a9C4P8hfqXepGaUD4ODAxIzfA5+38mj3069yiPeesN2XseFycjABmSd80w5E4oR9yYl8 s/OD3W8wLhrQlFDT4OtIvNloTMY+EprOcjJpP/NyXeg9NYoxvqiOp6BBSqKfeUA+B7Tt QcM+PYweysp/8vhuEKpILCZIayKoRhSjKyL5jWmCfktGm17JBvNRJkxSHTs2glC55P5I I5teELyJCCKbL64+UJenkdnUCk3eAkgB/cagySvWzSXlEqpfRSZWzKAB9/e6MbeOeB3c hbVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JL73WR17; 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 t72-20020a635f4b000000b0042b4b0750cfsi19599300pgb.868.2022.09.26.09.23.04; Mon, 26 Sep 2022 09:23:34 -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=JL73WR17; 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 S236338AbiIZPVQ (ORCPT + 99 others); Mon, 26 Sep 2022 11:21:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47192 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235862AbiIZPTX (ORCPT ); Mon, 26 Sep 2022 11:19:23 -0400 Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5565082D1E for ; Mon, 26 Sep 2022 07:06:46 -0700 (PDT) Received: by mail-wm1-x333.google.com with SMTP id r133-20020a1c448b000000b003b494ffc00bso7605597wma.0 for ; Mon, 26 Sep 2022 07:06:46 -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=OHXbaNWdyZ0Wkkc1xL/nI14ReQ0AVnlGlwSXS+lV7dA=; b=JL73WR17Wo9QtiWEbhImaTC+IY7m0f8+Gxb/T/yG0u1LYZIlnRv6/Hux7V6Y5ZdDyd expWew6jX2nlPDAHqOwy550lJYkPZuVTrhdZbZYt51MVbjAo5P/q+5CeHmFEJ/qkbtUz muc4aGInDU6KV8AMk4zyjW8fwAgoKSNgj9rybamoQxK5T/TE7dtk4+4sBvw/mZDNfzvV NWUdE4wDfXls4nUxh1zeg7paA/InfLF4c5xje02HzoyaVKvZ2Z1cdIaDjfyinfAToFWG /DPFQ0GM3mjlkSZcCvCpgbFy5dAUL2Znxa8bjUPV56B2FAUT5kcf2HVQmpD8BE6CLz2y JlrA== 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=OHXbaNWdyZ0Wkkc1xL/nI14ReQ0AVnlGlwSXS+lV7dA=; b=qjsQOcjWHI8HXdENlECcqOCZjN+tDo5+SB2MXkudy7mw0oPuhndDXJqo7i5g9L32kg JejGloBd7htWL8Dq4CTab7kYUVv7WWQsI3oqX1X/qVLlfJrHG6EekV5soV8sSyxJ1fdP 1ekwW0eVa+ofcrKNpjyf5ZWFcfK+2wbEB4Blpz1WWLZdMoQGOBI++z+LEhM1oDApvAzH xoIj977y0OyQ1vGUgsWbKbtvCKvFhQnieFosFl3bJ4Zg2yMjtXlOENDFhwn1TsScvuC/ aYOci/Eh4Ev5ouAh32GOrOcAIchfcSBSg8lbvSjfF10msFoImCoLNkGy+hpuoVDM8eVz Wscw== X-Gm-Message-State: ACrzQf3AjhhFNCatCtGh9btexHl5Az7LgT9McwNEK3pKk15vJ1Yx1WoB 6Ji5ki6NnncqH+eewuw1rkguDA== X-Received: by 2002:a05:600c:1d2a:b0:3b4:6e31:92da with SMTP id l42-20020a05600c1d2a00b003b46e3192damr21415076wms.103.1664201204691; Mon, 26 Sep 2022 07:06:44 -0700 (PDT) Received: from mai.. (146725694.box.freepro.com. [130.180.211.218]) by smtp.gmail.com with ESMTPSA id v3-20020adfebc3000000b0022adf321d22sm14310731wrn.92.2022.09.26.07.06.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Sep 2022 07:06:44 -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, Amit Kucheria Subject: [PATCH v5 20/30] thermal/of: Remove of_thermal_get_crit_temp() Date: Mon, 26 Sep 2022 16:05:54 +0200 Message-Id: <20220926140604.4173723-21-daniel.lezcano@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220926140604.4173723-1-daniel.lezcano@linaro.org> References: <20220926140604.4173723-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 generic version of of_thermal_get_crit_temp() can be used. Let's remove this ops which is pointless. Signed-off-by: Daniel Lezcano --- drivers/thermal/thermal_of.c | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/drivers/thermal/thermal_of.c b/drivers/thermal/thermal_of.c index 494e9c319541..bd872183e521 100644 --- a/drivers/thermal/thermal_of.c +++ b/drivers/thermal/thermal_of.c @@ -19,20 +19,6 @@ #include "thermal_core.h" -static int of_thermal_get_crit_temp(struct thermal_zone_device *tz, - int *temp) -{ - int i; - - for (i = 0; i < tz->num_trips; i++) - if (tz->trips[i].type == THERMAL_TRIP_CRITICAL) { - *temp = tz->trips[i].temperature; - return 0; - } - - return -EINVAL; -} - /*** functions parsing device tree nodes ***/ static int of_find_trip_id(struct device_node *np, struct device_node *trip) @@ -529,7 +515,6 @@ struct thermal_zone_device *thermal_of_zone_register(struct device_node *sensor, goto out_kfree_trips; } - of_ops->get_crit_temp = of_ops->get_crit_temp ? : of_thermal_get_crit_temp; of_ops->bind = thermal_of_bind; of_ops->unbind = thermal_of_unbind; -- 2.34.1