Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp1171353rwb; Wed, 28 Sep 2022 14:22:36 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6Rdrebt257vwDnwasdvIKRd4T9LR7QYrmpkgFeUII8wNWL7jcJdwrlNBoaQP34WNhNTe+9 X-Received: by 2002:a17:907:3205:b0:770:8554:c4ee with SMTP id xg5-20020a170907320500b007708554c4eemr29981871ejb.39.1664400156380; Wed, 28 Sep 2022 14:22:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664400156; cv=none; d=google.com; s=arc-20160816; b=S6hpTC/NTcwlAI2I9KXNSZU0RifaRKZYMjTfWbSJURXUhXNQLVDxJpfYsYXLQVv+Kk 1etJNpu0GqHDK3a/XacTkDPdALnVud+flJmy1Gx2ETZj1WXdaTdGhgrN2rjRGc8KVm+Q w0/GJkNTGE71kjas/gFawjLWUpDcV83y+VP2cgYK8mJQEEhRQfyFKXw6IC9GhJGQpS5m I+MUTL9Bi7g6S/CkPYizbWeICdlonW0TRHm4BfgAxMOsEeuzqZSiPKMiDJtnCPg5u8yM kc7hRYDNmQa9C7mBp+FATsYmRXJ7BcJYo48BODs7+ZLkIKW/zMQayEx6uavVuHfLTlY4 ghVg== 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=KY22MjtoUlIwWIKxWwfuHh0wn9QBG3Vjtz/Dduvf6bU=; b=fV9lgeDMvrt1cET/3koMIrUGKl9K4ZwwX9AfLnimvuHCdhRGDHFEKK+Vzve7BIOFHb NgPqL2Ee/wiDQkAq4HSDM/GOSOLYTT4gqrps3lPSX/wcjQiJnUzHbM5jsLs26Zpf/65Q OrGo8f/CWkFT/ry2h0pRUH1sUThtHmFRB05zmGoC8LlPe6oRPpAcLdqoq9mHTTKsRSGg +Qhj/3fqInjOq7kFhzh05ORKfouk+VrNCHGrL+1ZEUeiuFTUJt/KXjVFB0kn66vXSbF5 dEHzElH0iixJUWmj1VV5fANdxrgWWMIBCua1k9FL/be14J3O0gZyI1o4DvpZS70XdZeR ZPMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=WyUQmG+d; 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 e13-20020a50a68d000000b00453aa9656a3si5782081edc.466.2022.09.28.14.22.09; Wed, 28 Sep 2022 14:22:36 -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=WyUQmG+d; 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 S233906AbiI1VFy (ORCPT + 99 others); Wed, 28 Sep 2022 17:05:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234631AbiI1VEo (ORCPT ); Wed, 28 Sep 2022 17:04:44 -0400 Received: from mail-wr1-x42f.google.com (mail-wr1-x42f.google.com [IPv6:2a00:1450:4864:20::42f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E852EDF079 for ; Wed, 28 Sep 2022 14:02:10 -0700 (PDT) Received: by mail-wr1-x42f.google.com with SMTP id c11so21553114wrp.11 for ; Wed, 28 Sep 2022 14:02:10 -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=KY22MjtoUlIwWIKxWwfuHh0wn9QBG3Vjtz/Dduvf6bU=; b=WyUQmG+dikM/2KB56J+eG4Y/B0GNeeumoWKaKhxJmcGkJp547dIcc914gSP+T7Y5jh WdtE9db/kqIizzIp3NNCL2h/Yp6vsZcaOChwsZD7xcH3HLegIduohrZ3bhRh2DEw3v6i oDdQVM0kklN9XW3aFRMIXsX7LbR+tbJ22tfmj2fpPBte+6PruziVTxqfI5Wz3ARaIKcF bcoHLngWnbprMwjhDgPvqcnPqC1C43xHZ0Z5XPhMnaT8O0FQ6zOJteHtaSlX5QOSrTBf nkPRm0nPWAk6zhdt1LNavzCBHxFKzRgZ9oOAYP6nsCUP/xedkvuJz5mUwA63uONAUnIo EJLw== 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=KY22MjtoUlIwWIKxWwfuHh0wn9QBG3Vjtz/Dduvf6bU=; b=utQKgsXgKH8V+sZCnsPQ3r1pNwcpsDvl4VHiOk9ZU431wWiA4wMWc33558nw12Qz+6 Q9hVuBFXlYC6UTt6m09epEd2fq7fSDpqM8r/tOC990ElmT588divlO83ReVopdys0C+w aeel9OoDo93K3sFYA3eYjCkQXH5DSILtMTV+brmlYPZaxjWLZb80MjzinsEmBllsSpy6 YrwlYxo2yoxs8Ji+ZmV7rxgkpeVhto2hwUWgbRk2tsNYsnfMJgdlmDjnGqvXEAONTIy2 eIb2ibujLgk123FOfeA6H0iuMA1DV38I5yXEwQaDrLMe/Y94UrU3RUnN7piEvCNa0rs0 P9xQ== X-Gm-Message-State: ACrzQf0HyHfyoc5bkH7jmssPzqqjTpTIDx2Uf+CCvAFboPYlZb7Cx8Xv aoFpl2Ibx+SZ1woFzCOW/08DIw== X-Received: by 2002:a5d:64c2:0:b0:228:cb2b:f38d with SMTP id f2-20020a5d64c2000000b00228cb2bf38dmr22043755wri.491.1664398928756; Wed, 28 Sep 2022 14:02:08 -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.02.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Sep 2022 14:02:08 -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 18/29] thermal/of: Remove of_thermal_set_trip_hyst() Date: Wed, 28 Sep 2022 23:00:48 +0200 Message-Id: <20220928210059.891387-19-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=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 core is providing the generic thermal_zone_set_trip() function which does exactly what the OF ops function is doing. It is pointless to define our own version, just remove the ops and the thermal_zone_set_trip() will take care of it. Signed-off-by: Daniel Lezcano --- drivers/thermal/thermal_of.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/drivers/thermal/thermal_of.c b/drivers/thermal/thermal_of.c index 4e54d62720dc..494e9c319541 100644 --- a/drivers/thermal/thermal_of.c +++ b/drivers/thermal/thermal_of.c @@ -19,18 +19,6 @@ #include "thermal_core.h" -static int of_thermal_set_trip_hyst(struct thermal_zone_device *tz, int trip, - int hyst) -{ - if (trip >= tz->num_trips || trip < 0) - return -EDOM; - - /* thermal framework should take care of data->mask & (1 << trip) */ - tz->trips[trip].hysteresis = hyst; - - return 0; -} - static int of_thermal_get_crit_temp(struct thermal_zone_device *tz, int *temp) { @@ -541,7 +529,6 @@ struct thermal_zone_device *thermal_of_zone_register(struct device_node *sensor, goto out_kfree_trips; } - of_ops->set_trip_hyst = of_ops->set_trip_hyst ? : of_thermal_set_trip_hyst; 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