Received: by 2002:a05:6359:6284:b0:131:369:b2a3 with SMTP id se4csp450813rwb; Fri, 4 Aug 2023 15:57:23 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE43kNO5gchO4W5wLNEMoXOgl2ZcJVPTO1OK2Stv2JXrhXHsZXj/UZQeWyvBt6uhENoiGWW X-Received: by 2002:a17:907:2bf0:b0:991:d05c:f065 with SMTP id gv48-20020a1709072bf000b00991d05cf065mr2523507ejc.52.1691189842857; Fri, 04 Aug 2023 15:57:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691189842; cv=none; d=google.com; s=arc-20160816; b=iByhAGNtbZzG45lnQLuvQDth/zw6/yL4AvOX+1VWb4dcDDOK0whrHDiOZztLLvYEU0 PaITVE3+ECYn6Y6ePZIl2daVBR9ZZNiuSUWSppMB9zXpFapmck2CI4ZklenA9r5gpYBS EFjVQcNjjsrNO5XbE3Qp5TKYO6W1OybMS7XurHLPxcTgHrCxUN5SfJI8KG113f6+8J5e im/BMAzbpyjCx1g5Zg2+jvF0R9T3HIoFn37nOaTFONocQMi4n7wnLLqyQE2gQFtI+N8O C7w365ZL5q2DY4YbZH1bPgpVUh8qGIal4QZ3logyv/6qHTAtaBmV2V25Xz5YbEL66fwu h7CQ== 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=PE4QZNuuu7C0bSqFySHaBYQN1XQz2ilfd/lPvByw4oA=; fh=EIL8NAWS/Sv4+Mlu61OoEnfLURX8VcMTqwy5Ab2hync=; b=zQ+oPm8/t+/wdRqifE3o0jOpu+kB1OmXkLtLLQfEZiplhYt7fMrVFsfMtizUzLMUqX Z/NzY2XhCOft6Ay21MDHxuKvKURII6Dnb/53c8pTuaDrf7z1gMbOvXpWExcGvPYHtfGb 7siWS7z61+bCzXfy+Yig1qph0orRQPyUencFRqUPT4XKlDS79zpajYw/3NCi29nz88Kx fJpFq8lsnRxVHHZo+occy44dMPJ+UsstXy2g3Ry5JbeRiv+0Cc4dxwuU0iL7d/HQhg3M EMJwcRHymatcxsMdSbtYwzyODpVpzeHPH8lL1E1G6h4v1RtqHxQtR5NC6yiLXOS6HxI9 /QQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=fljTr62Q; 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 w3-20020a1709067c8300b00992ee6da4b2si2351875ejo.683.2023.08.04.15.56.57; Fri, 04 Aug 2023 15:57:22 -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=fljTr62Q; 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 S230359AbjHDWR2 (ORCPT + 99 others); Fri, 4 Aug 2023 18:17:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35972 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230092AbjHDWR0 (ORCPT ); Fri, 4 Aug 2023 18:17:26 -0400 Received: from mail-pl1-x629.google.com (mail-pl1-x629.google.com [IPv6:2607:f8b0:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A1776170D; Fri, 4 Aug 2023 15:17:18 -0700 (PDT) Received: by mail-pl1-x629.google.com with SMTP id d9443c01a7336-1b8ad8383faso22690265ad.0; Fri, 04 Aug 2023 15:17:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691187438; x=1691792238; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=PE4QZNuuu7C0bSqFySHaBYQN1XQz2ilfd/lPvByw4oA=; b=fljTr62Qp0eBVEhKJWUVlRWTmGhmLxy7KMtkV9HjZr5dZEC+fJfM/W1p3i9yBPc3s7 U1qrW5yVOzDFoXqHfUpJqu8l946Y0lBC7ElENxJxwmV6NbKVLgBNlUyWK4sasocfBD/1 THT7NHsGy4Wx/64r0cG+V212cJ38fUYJW/+3YmOHV7kqE1CQEDmrf/AYwnkmyEhxg9U3 VaQfrmpiEtkFI1PNZHNjPH+yJ+a/wWcjmdOEdLWsXP3boNAUYZBez8bUutfcY08ZkoH7 mtLq6FPSAz9a5Fmqc4TOfm1hyLrROVQyZT5DT4YiCeaMJXkH6F+DiL/OFMQYjs8aKImN +OSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691187438; x=1691792238; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=PE4QZNuuu7C0bSqFySHaBYQN1XQz2ilfd/lPvByw4oA=; b=XVtZ6PXUjBoCN48E0jfxVNDJE8lN/PAZaoFTVIlFMHspnvI9Si1Xgi8bdoIHIhPdp7 txgxIUdiJVrHnDYw2bdc789+bzqZdng1uHOY2aK4zTAXMjJT6OY/+YZmTIfIHGzz2u+9 VUMt6IAEVyysAga5u8n09r2e6uowX4JIyeIaXyGZ/Kov0mm3HFf8dvXCGeimHUlDFHPL jP21TuxDghiPVPapo7Lwx360vAFAgkbyVZienaibYWWhHhkYms7XLxNS1LKXcmhaouC0 uMeAtAn8i/GgmpNxVY6nWHTaIIL1HNJ3gP+ifUECO0ZiFouRPzjfmaDemw4dOmfsx25L I4tw== X-Gm-Message-State: AOJu0Yyi/kCX+Tsgf5F0hWO6vvw9zE6/+HROTnTL429LtavdAe7RmtdY K5b/kpVmYmmFSBciIfn7uXs= X-Received: by 2002:a17:903:18c:b0:1bc:532f:1bf8 with SMTP id z12-20020a170903018c00b001bc532f1bf8mr2242421plg.45.1691187437944; Fri, 04 Aug 2023 15:17:17 -0700 (PDT) Received: from taoren-fedora-PC23YAB4 ([76.132.59.39]) by smtp.gmail.com with ESMTPSA id ja4-20020a170902efc400b001b8013ed362sm2233229plb.96.2023.08.04.15.17.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Aug 2023 15:17:17 -0700 (PDT) Date: Fri, 4 Aug 2023 15:17:15 -0700 From: Tao Ren To: Guenter Roeck Cc: Jean Delvare , linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org, taoren@meta.com Subject: Re: [PATCH] hwmon: (pmbus/bel-pfe) Enable PMBUS_SKIP_STATUS_CHECK for pfe1100 Message-ID: References: <20230803235536.798166-1-rentao.bupt@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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 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 Hi Guenter, Thank you for the quick review, and I've addressed your comments in v2. Cheers, Tao On Fri, Aug 04, 2023 at 08:19:40AM -0700, Guenter Roeck wrote: > On 8/3/23 16:55, rentao.bupt@gmail.com wrote: > > From: Tao Ren > > > > Enable PMBUS_SKIP_STATUS_CHECK flag for both pfe1100 and pfe3000 because > > the similar communication error is observed on pfe1100 devices. > > > > Signed-off-by: Tao Ren > > --- > > drivers/hwmon/pmbus/bel-pfe.c | 6 +++--- > > 1 file changed, 3 insertions(+), 3 deletions(-) > > > > diff --git a/drivers/hwmon/pmbus/bel-pfe.c b/drivers/hwmon/pmbus/bel-pfe.c > > index fa5070ae26bc..8280d274da3f 100644 > > --- a/drivers/hwmon/pmbus/bel-pfe.c > > +++ b/drivers/hwmon/pmbus/bel-pfe.c > > @@ -17,12 +17,12 @@ > > enum chips {pfe1100, pfe3000}; > > /* > > - * Disable status check for pfe3000 devices, because some devices report > > + * Disable status check for pfexxxx devices, because some devices report > > * communication error (invalid command) for VOUT_MODE command (0x20) > > * although correct VOUT_MODE (0x16) is returned: it leads to incorrect > > * exponent in linear mode. > > */ > > Rephrase to something like > > Disable status check because some devices ... linear mode. > This affects both pfe3000 and pfe1100. > > We don't know if other pfe devices will be supported by the driver in the > future, and we don't know if those will be affected, so we should not make > any claims about such devices. > > > -static struct pmbus_platform_data pfe3000_plat_data = { > > +static struct pmbus_platform_data pfe_plat_data = { > > .flags = PMBUS_SKIP_STATUS_CHECK, > > }; > > @@ -94,6 +94,7 @@ static int pfe_pmbus_probe(struct i2c_client *client) > > int model; > > model = (int)i2c_match_id(pfe_device_id, client)->driver_data; > > + client->dev.platform_data = &pfe_plat_data; > > /* > > * PFE3000-12-069RA devices may not stay in page 0 during device > > @@ -101,7 +102,6 @@ static int pfe_pmbus_probe(struct i2c_client *client) > > * So let's set the device to page 0 at the beginning. > > */ > > if (model == pfe3000) { > > - client->dev.platform_data = &pfe3000_plat_data; > > i2c_smbus_write_byte_data(client, PMBUS_PAGE, 0); > > } > > { } is no longer needed. > > Thanks, > Guenter >