Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp5107544rwb; Wed, 21 Sep 2022 03:20:31 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7viHcS4rSrP5GleiDPdqMnxdOqI7lI4g+ul8/w2Eg3QBilPT0XcDGx81zVapXpDH5cEEL9 X-Received: by 2002:a17:906:9bdc:b0:77e:1ed1:b12 with SMTP id de28-20020a1709069bdc00b0077e1ed10b12mr20339877ejc.661.1663755631650; Wed, 21 Sep 2022 03:20:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663755631; cv=none; d=google.com; s=arc-20160816; b=jI23cA0NWgJz2eRHb3biupesRt6OncY90sTZLYJ32usyhNqTB8NuVUAZJm3iFVi8+j zdI/PgctkhTIjCXcxM2JUo5snUT3xP495pyqKQ0nhoIhqxPHk9oFQFlz6qecq9wIcrng AqV6qArLb31OPEkeEE7Mu6OD5whITHv9vlSUOI2EVZTtQSc/lt0GT2kzSmGNdYnZ3oEK KAX5laMWHQktklFBkKSLiwGlRChp/9zJMTtRUUXMvoDtlbPljQWxhNWEZba8vHEtjAMj ZHU1gLf3kzXGMzSmVXF7cY1Nk7o8volA5dHKsC3rabQxhjBR6lWcHUXUKBK0fmyX6GU5 a/OQ== 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=X3YcEGq/dp+ZJRJrnHSzRBx3ZMFowrni6S4WK1LWfePrrdCPi9IuwClk409L8WF9Tb b3tNLwEw7TzEvHIB+Lg2nOoXUevYSQ6A+jVI5miRwG14JR24TJJ5hm5wo8ZCOFHFs+fZ Vpy/j9K/4sfakAk90sHFsoYMaislp5F7CwHt23kvnT6WLjNznoieDQvLufcVm/nbzQHZ /SKJL+jUWpWJQeJ9EPddyOIoyd4jmdg/zXlEqSfgNElsM5gbP2XPVA7P2KCR4bis66W+ S9+lJjqEVE/Hvs0AWZ1mDCGZmoTufl48G2GfVyzHHZi72MKHp/fBgSHlZCx0wiBd4sjq G64Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NspiL8xB; 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 hb12-20020a170907160c00b007414886601asi1828439ejc.25.2022.09.21.03.20.06; Wed, 21 Sep 2022 03:20:31 -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=NspiL8xB; 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 S231875AbiIUJpj (ORCPT + 99 others); Wed, 21 Sep 2022 05:45:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44362 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230115AbiIUJnw (ORCPT ); Wed, 21 Sep 2022 05:43:52 -0400 Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 039CF92F69 for ; Wed, 21 Sep 2022 02:43:51 -0700 (PDT) Received: by mail-wr1-x435.google.com with SMTP id bq9so8932140wrb.4 for ; Wed, 21 Sep 2022 02:43:50 -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=NspiL8xBWtxFZk4xO58c4h8PCilOME2upvEL2MDhBVpLETfcOqoi+Tb4f2jIc0frbg 6CvUC/Djm2URTXlqK22pC3SOrZai+bKjOcd1ZKAz5Y6p1Na5C7EQ+EdY3vdBvKHD6Yup A5O582+buH0igDPx/lC5xvqBL+Qf7GMkMd7iUNFuNR/Yq8GgV14nj5g/9sYElgaqTGVn SPDw0+8m7mJTBgL9O7GbHk1xUZPhjL98pO8sZCYTFS5RTHIeowE+qqB0mtZvHiPTqxUy im2qFrc8GqmhvDdFlUmhly6UlrAsUJXot3g/Esm+Xb9oaDuzeJhX9bOpzUyQu6MDWIUM UIxw== 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=2/pz7Ax6RExU2QsxW1mt5/hok5kXSzNICxsElJYfOnsVIXkNIbUkqVQxv3X5NxCgXf opRtXpQfP7A/u5hAyZgMYRJns1TXGOhZhoQFlfDwrgbHXd7IQf6qzc6QZ7/kIR1PNBGI YNyyO06ABHj7+0BCHrmkPJhZElLjdGDYCGGBE4AtfV3B3A1K6JzY/bz1aCItU6lcl9hk 6IoCMFXFRSRc2s1O6SsF4mom57MjCpYjGt7T+/QLPdWtoOvwIoEsaqYOvNKHOtjVGUyL 7xPNfEHRq6FdkHmgmuO708Mlq6/fY5l5DoW+PfpV4xH8UTNbQf06HsEiyl55ydRPir0I 1pMQ== X-Gm-Message-State: ACrzQf0WO7nfSGRIPV98FUbNkOuCpCrnwoyyaGyUmgk2lWvlpIyI0NsY qYxpqoiNNdnLwgwdQOhwOLMw7Q== X-Received: by 2002:a5d:64e5:0:b0:22a:3cae:93bf with SMTP id g5-20020a5d64e5000000b0022a3cae93bfmr16811393wri.323.1663753429413; Wed, 21 Sep 2022 02:43:49 -0700 (PDT) Received: from mai.. (146725694.box.freepro.com. [130.180.211.218]) by smtp.gmail.com with ESMTPSA id r123-20020a1c2b81000000b003a62052053csm2763917wmr.18.2022.09.21.02.43.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Sep 2022 02:43:49 -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 v4 19/30] thermal/of: Remove of_thermal_set_trip_hyst() Date: Wed, 21 Sep 2022 11:42:32 +0200 Message-Id: <20220921094244.606948-20-daniel.lezcano@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220921094244.606948-1-daniel.lezcano@linaro.org> References: <20220921094244.606948-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