Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp6136981rwp; Mon, 17 Jul 2023 15:53:13 -0700 (PDT) X-Google-Smtp-Source: APBJJlHYtVtzRIhlBCgsOGtqEE7nxIWtGeKNHI02xQPW4AhAv2gsk+ae7SXYgmQ52fhYjjnbcqpF X-Received: by 2002:a17:90a:7103:b0:263:f68d:adca with SMTP id h3-20020a17090a710300b00263f68dadcamr11011990pjk.20.1689634393245; Mon, 17 Jul 2023 15:53:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689634393; cv=none; d=google.com; s=arc-20160816; b=Jsc1Qag3lpzIQPap1oV6ZSjh1IOeI/q+QjjlYKlG609tY2wdynTJqv/7HHTAbk9NmA 9qgZa1kvw96CbV1ri6IPzXc5OoP+q7ehWXfxz4GP7SnT6ee8oKjoIYewxbK0BeNhmciv EPYlGWw7SEJIpnnOj0qnyx/+YpMDU1V+ZAVOCGUs48kBEMJ0MYoypXO+2HIYXKWtn+Cf OeqTv/E7sO5jpjCY4y1Q6EXhAv8GK31HHJE1Q9N1No8x+MvSHI2fm/uLi28yDZtB3QJh F9TmJY/wsxpwSyN+eMrZDg5tEDmPA0J1g/zbGdhhzcT8IfQZVkro1+lwPb0Jv+7oJ1bK DJzQ== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=H8+m1PD1OV/T4vMth1o/3b8d3uLDURVNRPW6GjP1Nfs=; fh=h793OaUni30alKFb4D+hGQdzb3dwmJ62PCcOI4idbnU=; b=SDdemTvwNzmuZ1+07RVNHWBBXyRAxwtBJ/bGPtY2jP5ZKX/2w9l20n0PvMlDQMhJ3s 48lM+nHWgy1rVJNvWwNy0ajVfYEpnFW1nP333cbN6WkYLQzJKSBZFtP8X/5qYEQMuiAw 2X/yxkWTpY3DNBy2xM8BKQIw9nvKt61DgKae0fc+Csj6OSwiOkmcreVq2eccamJJweEQ LnldgXVR/i2v1SE8ZoSoj9plAbjkGN3kFbYKBFbfvZFRF7/TGxq664P6jdN1g0ZFZv7j RXoqPM77zRURgS5T6THLd7Yt4yNByXJxRvIXdjzoJPECE4TrT8fxIZteY+8M9YuLSmPd 7idA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=TDebd7yP; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c14-20020a17090ad90e00b0026384c02c03si548845pjv.140.2023.07.17.15.53.00; Mon, 17 Jul 2023 15:53:13 -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=@gmail.com header.s=20221208 header.b=TDebd7yP; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229984AbjGQWZl (ORCPT + 99 others); Mon, 17 Jul 2023 18:25:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40634 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229517AbjGQWZj (ORCPT ); Mon, 17 Jul 2023 18:25:39 -0400 Received: from mail-ot1-x32a.google.com (mail-ot1-x32a.google.com [IPv6:2607:f8b0:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E4289AD; Mon, 17 Jul 2023 15:25:38 -0700 (PDT) Received: by mail-ot1-x32a.google.com with SMTP id 46e09a7af769-6b9c5362a51so1959589a34.0; Mon, 17 Jul 2023 15:25:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689632738; x=1692224738; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=H8+m1PD1OV/T4vMth1o/3b8d3uLDURVNRPW6GjP1Nfs=; b=TDebd7yPRGqPxaM5ODAw7ZQJy48JGvV0rw0DfVAXn2C6meWRSrVMVJDmWiIbeqUiV7 XxjcZqULoUkkl9g7Z83ez/BprYj/3IoAGNede/r6FGS/DCc7GYQK/THKGJGMomyygkcS kboyn2Xzj0Gn17uZ1zreypTjKKgeeQ8apmmZHk9GZ2/EEuYKtcV5b9UXBWaVaUI5O8Dq 0d+2NycV/hXszI8s24d1ZBbKd+6f1jKbKiqjFcNw2sg07tWRpI104SJqqJu2mxxbyl1n lblYGKB4HEs50hF1XTWHH0Uko3gSA99VTd1SnpJhV2X3+0Unh4cIwWeCx5VPh6igCLFb U3xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689632738; x=1692224738; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=H8+m1PD1OV/T4vMth1o/3b8d3uLDURVNRPW6GjP1Nfs=; b=P67ty9yssiWmLRLKDWIYUi1l6M047VjbahpDQnuRMcrknfZLk3/tRLsvKy6rfPKVUr rq8wQku6UkE3Wtd1xUCSYhw2So9n1vg5ih/lEf9uMW2xT17+CqB7y6EmIPwTjzhTjxSi 5C7ErE9jVvVjVr/7pcNXX+u+0hVuyib0aJtW9+P333pMpaUFL8yQAFEQTdG296FlMEAs y8XvAdYD+tzyDSrGq5Z38TiTdXzlxjGG/8JUolZU6Ba0QirqIslF64AKvpgINEXQjdeg 6Qd75ouOSR5aRuLS54vMq4iSqBwjvMlqvpV1vFthLov/AmQSC8sx3QWjMsTs7vUb7Vzt z99g== X-Gm-Message-State: ABy/qLY53nUqrQbnpiXh/iPUTW+puGXRHH1URWA2MkElMk/z9ENoQOyq 1KNv7lYiwSqY/Sz4oEaIswQ= X-Received: by 2002:a05:6870:589b:b0:1b3:eec8:fa94 with SMTP id be27-20020a056870589b00b001b3eec8fa94mr13299018oab.7.1689632738096; Mon, 17 Jul 2023 15:25:38 -0700 (PDT) Received: from smeagol.fibertel.com.ar ([201.235.4.68]) by smtp.gmail.com with ESMTPSA id a7-20020a056870374700b001ba72480f2fsm385553oak.43.2023.07.17.15.25.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Jul 2023 15:25:37 -0700 (PDT) From: =?UTF-8?q?Joaqu=C3=ADn=20Ignacio=20Aramend=C3=ADa?= To: linux@roeck-us.net Cc: =?UTF-8?q?Joaqu=C3=ADn=20Ignacio=20Aramend=C3=ADa?= , linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org Subject: [PATCH v2 0/2] hwmon: (oxp-sensors) Refactor probe() and init() and remove devm_add_groups() Date: Mon, 17 Jul 2023 19:25:14 -0300 Message-ID: <20230717222526.229984-1-samsagax@gmail.com> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 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,FREEMAIL_FROM, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 Remove the use of devm_add_groups() in favour of dev_groups in platform driver structure. This will allow for removal of the function as it was intended in Greg's email[1]. Also move board detection to the init() instead of probe() function so we don't instantiate the driver if the detection fails. V2 drops the 3rd patch that removed the probe() function. [1] Link: https://lore.kernel.org/linux-hwmon/ZKW7WuP0T9QdCR+G@google.com/ Joaquín Ignacio Aramendía (2): hwmon: (oxp-sensors) Move tt_toggle attribute to dev_groups hwmon: (oxp-sensors) Move board detection to the init function drivers/hwmon/oxp-sensors.c | 67 +++++++++++++++++++++---------------- 1 file changed, 39 insertions(+), 28 deletions(-) -- 2.41.0