Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp2753370imw; Sun, 10 Jul 2022 14:31:18 -0700 (PDT) X-Google-Smtp-Source: AGRyM1t1JPuP2fNTX8/RiQpYj+sLGC5BYNp7D7rN7yvIwD8RopMi39ip6wiMNa3+7GYR0J6B+UtE X-Received: by 2002:a17:907:2807:b0:72b:4530:29d5 with SMTP id eb7-20020a170907280700b0072b453029d5mr6012485ejc.69.1657488678537; Sun, 10 Jul 2022 14:31:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1657488678; cv=none; d=google.com; s=arc-20160816; b=VSA0299SqbavbbNVzm02zP+bGdeFTFiZQyKcC15eorDePgsZauPUpvYThOafQsAnOj 7iaaZWrV6g2FPDllDA+oWuBP41F25VHcv3XzYkxRfON9HsmouaiO+Y4chtAdUICXJWHO aAURXW2TkVDpi56Npu2fIMJ5hIhVHTjpyJC89FkMgOzc5FCIxrwWGEPq4mIuEleKuW85 qZXbmRQ5LX9lXHwt0BRY6CDooz6atBNyfpk5P5/Spus8p+k1Sc/N48pPsIKjCFzArnEL 80TYfvwrSLcxcwAUrT4P85N4ws7Oq851OplPCg7Xm7U84cipE12IH3kMEd84og10FN+5 5bLA== 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=JHt96uT4Q7BwS4NdRXSU1MVIN9ZQRmgKBYoUqlA70sg=; b=e0TkpBZs8mnjAIBVfuLN7ht+GidCTpH78kJjPbpLFdQ4ubC1Xinq0aGyVHtsprVZdZ qvi09dQoO5XooWzSkl2gWsGk2DxHaAT89B1FYkztvy/7fFfoapQjUe5LpkaCLVfO/P/e JqAexcVys8AmbLyogGUaS56CnzTMNCb+6aNr+Ou2YKGOib0RrVmi3ikLqGsgFFdFyjDb GntuLt3u0NfD3DO/FnzhkFIjaZHeHzJq3gOKNVJiJBQ0BpeHEsT55397GkQZ2US8DdCu IdKSwSEB/I033eyrmuUdBwuY/KhVOI/AgJcsGo89Vb+G0LhO3zvEpRDMb7J/kISd0RsM RZOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linexp-org.20210112.gappssmtp.com header.s=20210112 header.b=FTmtHevb; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h13-20020a05640250cd00b0043acccd89dbsi4221142edb.597.2022.07.10.14.30.54; Sun, 10 Jul 2022 14:31:18 -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=fail header.i=@linexp-org.20210112.gappssmtp.com header.s=20210112 header.b=FTmtHevb; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229817AbiGJV1K (ORCPT + 99 others); Sun, 10 Jul 2022 17:27:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46196 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229814AbiGJV0W (ORCPT ); Sun, 10 Jul 2022 17:26:22 -0400 Received: from mail-wr1-x431.google.com (mail-wr1-x431.google.com [IPv6:2a00:1450:4864:20::431]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EBDFA17063 for ; Sun, 10 Jul 2022 14:25:36 -0700 (PDT) Received: by mail-wr1-x431.google.com with SMTP id v14so4766850wra.5 for ; Sun, 10 Jul 2022 14:25:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linexp-org.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=JHt96uT4Q7BwS4NdRXSU1MVIN9ZQRmgKBYoUqlA70sg=; b=FTmtHevb/2lCiduv1bxN2jNSRFQIRp1jQ/TUsaCdBwAW/diJI+MM6X5FtZpJwCzVf3 xFWyF1+0v3PX7grCleGiUZm577zgV6OCoxe/iNYb6agevNc8T+GA5VXWgMU5cpaWYEBF 7FDYF6mc+ZQkiaNF9fOgCkXuuWuHDE3v6XnFCI0Lfr/ViYuHr7P9EZThxmTbJYEqO7Lc 3kEoa0C2AA2hLg3U7vfgE7HgyBpa1NzcFta7EJPcXQvO8K+9vcDp834AfTGXBZ0+eZqT D/ZCenPS+afAUNbazuch9U8MPl56fezX+Sfhj2+98avOEg11/9H4dBRFDs+0XsBTrxTT nMfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JHt96uT4Q7BwS4NdRXSU1MVIN9ZQRmgKBYoUqlA70sg=; b=2LSj+rZCDRyGSROSoA9iDWYzJsW/g75iOUafr0PuXqdoLlqJ4VvIwjy4Uu6Bg/odIZ bMhaDQ/xMaJszumRaJKNuUYy4CD6jwxnaw1vKTytyJOzR96rRUQwfKvgeh8k7xSLV0rM Kt1qOWYjEUIYRbxpYDh7W4j9a+aRzl7dX+czAMcRmx0yVEfUNIqKIWETzYnOeRXorS9E S461lNUwjZzHCWUWOjKzh/M6wbNnCu6EbsC3wGRfev55oI9KkFoVGEkbr3AHo3bYJrf5 6olyP2SqrIG+zfL60wyJqJTedhmvJ6HX6ZLcdt9ogbhubzNjmP5Ciz//Og3fxyMoF3Do Masg== X-Gm-Message-State: AJIora9d+5TJgxyPcTzVLo3fTAYfs6MFC3CNQqCtqAthfHqx/mRabDUd HgkqxSBuXFU1JFJsFCiW/DUZjQ== X-Received: by 2002:a5d:6d0d:0:b0:21d:7ae5:22ee with SMTP id e13-20020a5d6d0d000000b0021d7ae522eemr13289006wrq.152.1657488321495; Sun, 10 Jul 2022 14:25:21 -0700 (PDT) Received: from mai.box.freepro.com ([2a05:6e02:1041:c10:c7c0:6823:f3ce:2447]) by smtp.gmail.com with ESMTPSA id m19-20020a05600c3b1300b003a2dd0d21f0sm7142759wms.13.2022.07.10.14.25.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 Jul 2022 14:25:21 -0700 (PDT) From: Daniel Lezcano To: daniel.lezcano@linaro.org, rafael@kernel.org Cc: rui.zhang@intel.com, khilman@baylibre.com, abailon@baylibre.com, amitk@kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Dmitry Torokhov , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , linux-input@vger.kernel.org (open list:INPUT (KEYBOARD, MOUSE, JOYSTICK , TOUCHSCREEN)...), linux-arm-kernel@lists.infradead.org (moderated list:ARM/Allwinner sunXi SoC support), linux-sunxi@lists.linux.dev (open list:ARM/Allwinner sunXi SoC support) Subject: [PATCH v1 28/33] input/drivers/touchscreen_sun4i: Switch to new of thermal API Date: Sun, 10 Jul 2022 23:24:18 +0200 Message-Id: <20220710212423.681301-29-daniel.lezcano@linexp.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220710212423.681301-1-daniel.lezcano@linexp.org> References: <20220710212423.681301-1-daniel.lezcano@linexp.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE 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 OF code has a new API allowing to migrate the OF initialization to a simpler approach. Use this new API. Signed-off-by: Daniel Lezcano --- drivers/input/touchscreen/sun4i-ts.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/input/touchscreen/sun4i-ts.c b/drivers/input/touchscreen/sun4i-ts.c index 742a7e96c1b5..7cee09504e34 100644 --- a/drivers/input/touchscreen/sun4i-ts.c +++ b/drivers/input/touchscreen/sun4i-ts.c @@ -192,12 +192,12 @@ static int sun4i_get_temp(const struct sun4i_ts_data *ts, int *temp) return 0; } -static int sun4i_get_tz_temp(void *data, int *temp) +static int sun4i_get_tz_temp(struct thermal_zone_device *tz, int *temp) { - return sun4i_get_temp(data, temp); + return sun4i_get_temp(tz->devdata, temp); } -static const struct thermal_zone_of_device_ops sun4i_ts_tz_ops = { +static struct thermal_zone_device_ops sun4i_ts_tz_ops = { .get_temp = sun4i_get_tz_temp, }; @@ -356,8 +356,8 @@ static int sun4i_ts_probe(struct platform_device *pdev) if (IS_ERR(hwmon)) return PTR_ERR(hwmon); - thermal = devm_thermal_zone_of_sensor_register(ts->dev, 0, ts, - &sun4i_ts_tz_ops); + thermal = devm_thermal_of_zone_register(ts->dev, 0, ts, + &sun4i_ts_tz_ops); if (IS_ERR(thermal)) return PTR_ERR(thermal); -- 2.25.1