Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp34057rwb; Mon, 26 Sep 2022 08:59:27 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6lesDSx1ZqBx3XuQ/kUb4bmtwkAlvnugI3ONBJaN/NDC82DnhbZJDkVeQrX92qi+cb/ZhA X-Received: by 2002:a17:90a:fe90:b0:202:a345:b7a6 with SMTP id co16-20020a17090afe9000b00202a345b7a6mr25398802pjb.14.1664207967333; Mon, 26 Sep 2022 08:59:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664207967; cv=none; d=google.com; s=arc-20160816; b=zEywmUS2dVEyqxH0dRPliEA7ZKVewd3KaUElLmypHJMNaKB786QuryV/bYFdjYMqcz o4/76K2WGxlT8oyKh9JWgmYEV9yQKSjufRYna//9jxBTaa7YcaTE+/QHpbgK9cXig2yO +BkWSFkCFVSVLeOH0OkLwbFL9js51cDAvHcQjhuTEKI9458uR1Q1qyCOQBMozXqbzYPI ZIguVtjXQo5cFJoeMFvRzUv8ilCH6/he1ryLBI/HV+fAQ4dWEvHa3ydJA6nO8KzNktEb IaXvGayMB0bx0hHi9El5Pf8VT6TnAieiULPAJB6NdMpE1zePenU2qfNjYbi9Rc6armdU B+Mw== 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=NlMrb8k3KbFu0IxiYFrpYXm/5h7w4qFadLnJUaJBwjV1wpxsemo494ftHyAkqZ31gp gyLyHblxXORaLdurpC/Y6n+Qv2lZ+TnIENqcw3AKzSDczVqi3r7lDMzbC/JJ1yrlz7tc SHpm7zUL0LTj3ZFKG67qu1BWd5c99znAWfvCMkCgWz7yCmBxFPnWr/HSIR5N+uYj6RVB WKiB8EccxNIv3b6WvyKe1muQVd1n5IlnVWP73rwGn1DKfX3/tH1gFtxFEoR8RXywOc+e IwAGSsDOyL9NFmYHAWIQ23DwQrWE9HKi3Qe78o8EUGHCGtwRxKOXe/bMtAGdzJLUYRD6 7S7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=EpvKvHSw; 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 u1-20020a170902e80100b0016ca4b6f18fsi13887950plg.63.2022.09.26.08.59.14; Mon, 26 Sep 2022 08:59:27 -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=EpvKvHSw; 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 S235823AbiIZPVM (ORCPT + 99 others); Mon, 26 Sep 2022 11:21:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49390 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235661AbiIZPTW (ORCPT ); Mon, 26 Sep 2022 11:19:22 -0400 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D38983060 for ; Mon, 26 Sep 2022 07:06:45 -0700 (PDT) Received: by mail-wm1-x334.google.com with SMTP id o5so4603881wms.1 for ; Mon, 26 Sep 2022 07:06:44 -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=EpvKvHSwStgMICfq57+AHEBgNTsZCGHu4zDwSNFuBuPQ2UEKfocQK/30SpAMYBT1F9 GCSYXU5+D4iBDFg7NUeec7imLqJ82HssPSs/tIv0TLYebUEQT0kqYQAauZ3iGIAkL6LS QsFBYx71/vqTlKvlVQIHddyArmUbT5QHln/Ld/kmDubpbo+lYkpkXvPKiWcZ4pmoY5ss ILtGblkDQxADV8Wb6oYOrVeDR3cmBDH565RIp/7DOcoKVk33Tjw0LEzfeemw1uiiStvj 21Bsg/z72x6H7GcotuoMIYjMu6IIQ7H5/l+30+rVBCh3RKg4Wu9cvQDlCDoB+wgMM3MB CQXg== 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=UKY5VCk/gDf6W6ryp/f/5rLoKfkQR8Thm/xInSOsP7vIvghesFL4L544wehQNzTPZm D2xN4DF7srbtqI9GKAMsroRS8zurWKZGJxQ2Dxe2vi46vD2BJOYdX4RIvfFRIohDgzjf j5GfI1w2k5JbicxcJuvHsja6fHlpeMvqpyYAyf/RRvv4jU+gLtU0e3wF178eBpTQ2rcO n5rhZe79T2eS2Q4xtBaTxjecx67N39BA/vNPkkQiHCKyjeB+DSr1xBBAfz95D3n8ChhY MalwMaD9JOYzwj87bI5lN8o2YuzYyauUyBUmjgVfDUZFas4q0bGn0F4y1kRdPZ2Zcrbe ayww== X-Gm-Message-State: ACrzQf29IfEYoLduLJZTEGNTnLzBy79CH2RJXY5aPTvFpr+bNvdIO0i7 zJFk0ByXjqMFy1uJGcMBwRmNuZTkROKyWw== X-Received: by 2002:a05:600c:23ca:b0:3b4:6199:8ab9 with SMTP id p10-20020a05600c23ca00b003b461998ab9mr21728823wmb.20.1664201203569; Mon, 26 Sep 2022 07:06:43 -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.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Sep 2022 07:06:43 -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 19/30] thermal/of: Remove of_thermal_set_trip_hyst() Date: Mon, 26 Sep 2022 16:05:53 +0200 Message-Id: <20220926140604.4173723-20-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=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 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