Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp2585190pxm; Mon, 28 Feb 2022 01:58:32 -0800 (PST) X-Google-Smtp-Source: ABdhPJysVG1/eQrYGbZPXBEMb/3uS5BCQ5gPicpActordrwody00aeP8aqEAFPzCwZT6nP6Y+E6/ X-Received: by 2002:a17:902:ed8e:b0:151:449d:4c33 with SMTP id e14-20020a170902ed8e00b00151449d4c33mr11098943plj.138.1646042312508; Mon, 28 Feb 2022 01:58:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646042312; cv=none; d=google.com; s=arc-20160816; b=d9zIXxIwBOQJ1VGBsyqg79iUFIAGdZ2aiWQvNn0Uw+iyJeV58sJnkSHiKziJ7/oCUI RjXsnv9cFMzRn/80Xu76W1bEs96EhERLR+JUEbDjQBnZ+6dVMJvEo8gZfdlro8K9OIqY BTJClxwHyyhHZn4/ot/xB1tPGOcRa7fSsvHPbCflMXCQQJzbYdMgfdOKjq2tslZ3mYyH Zu4ulNlJ8EV6r3ekhUDE4bzonvV+Dr688A4j5ipuDkuOxJQdvL9XGApsderTvZCHBTmC nhIWKZAhBQZgELGuFD+7UOgJN16W5DtvC5zRsqp6ewxYVyiesGrgyqweeUQz9sJfy1PG qyqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=CCCJGLwREFudXAQ71006Rww33yHRQbbj3lk5h/iUP7I=; b=KP5YC/+wWsXiO0SulN3RqNuVGVNLsJnAELLoN5v3wEVo7Qavod8ASMMFrha3jis4q4 Z/ad32M4HZxYcOwh2WPMfe1qoyLMyQuB1aSLWkbq9x9AGXu2HlqIh13vkRyIUuMTQpO5 TYDzssIZIAO2juek09TnbHdickWcXBKrF4b017YXBTWjhpPczSnlBxW27yPGGx3JBYJV U7XDpzWjPt/ncKmtccT1dCsSmGj0TpSH6kyptDVLWLJ6340flC6NhpgaiepOAem9lgui r7VO/59jdAjLFNUrrE5NJXxCchWpcGaIc1iHiY2AmMV3o42WtmQoPjbYln0MgN00IJWd Z+Gw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bewilderbeest.net header.s=thorn header.b=DSLlx5cp; 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=bewilderbeest.net Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u14-20020a170902e5ce00b0014d5a132a35si9710006plf.619.2022.02.28.01.58.18; Mon, 28 Feb 2022 01:58:32 -0800 (PST) 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=@bewilderbeest.net header.s=thorn header.b=DSLlx5cp; 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=bewilderbeest.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234011AbiB1IdF (ORCPT + 99 others); Mon, 28 Feb 2022 03:33:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40938 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233963AbiB1IdE (ORCPT ); Mon, 28 Feb 2022 03:33:04 -0500 Received: from thorn.bewilderbeest.net (thorn.bewilderbeest.net [IPv6:2605:2700:0:5::4713:9cab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 16DC021AA; Mon, 28 Feb 2022 00:32:24 -0800 (PST) Received: from hatter.bewilderbeest.net (174-21-187-98.tukw.qwest.net [174.21.187.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: zev) by thorn.bewilderbeest.net (Postfix) with ESMTPSA id AA922586; Mon, 28 Feb 2022 00:32:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bewilderbeest.net; s=thorn; t=1646037144; bh=CCCJGLwREFudXAQ71006Rww33yHRQbbj3lk5h/iUP7I=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=DSLlx5cpu6/a3Z/YK5BUN+3pKJVP2HvMkrVnWDg5ngfiReScKDSrUrRYagxb8EEAV xlTlmYlbiISSanrSe/gT5KWmFVlnlIxpwqWTPLSgGkA6JG9Z7UkN3ha1pckO11vYyY 9ttb1mGvnXpmAnThWty/HDef4OFb6Ngeo8xXY20E= Date: Mon, 28 Feb 2022 00:32:23 -0800 From: Zev Weiss To: Guenter Roeck Cc: linux-hwmon@vger.kernel.org, Jean Delvare , Renze Nicolai , openbmc@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 3/5] hwmon: (nct6775) Split core and platform driver Message-ID: References: <20220227154447.GA766647@roeck-us.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20220227154447.GA766647@roeck-us.net> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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 On Sun, Feb 27, 2022 at 07:44:47AM PST, Guenter Roeck wrote: >On Sat, Feb 26, 2022 at 05:30:45AM -0800, Zev Weiss wrote: >> This splits the nct6775 driver into an interface-independent core and >> a separate platform driver that wraps inb/outb port I/O (or asuswmi >> methods) around that core. >> >> Signed-off-by: Zev Weiss > >I think it would be much better to convert the entire driver to regmap >and not just use regmap for i2c. This way all register read/write >operations can be hidden behind regmap, and the read/write callbacks >are unnecessary. The tmp401 driver gives an example how to do this - >essentially implement reg_read and reg_write functions in struct >regmap_config, then handle all register accesses through regmap. > >Couple of additional comments inline. > Alright, that sounds reasonable -- I'll work on an entirely regmap-based v2 (and address the other points as well). Thanks, Zev