All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: "Matyas, Daniel" <Daniel.Matyas@analog.com>
Cc: Jean Delvare <jdelvare@suse.com>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Jonathan Corbet <corbet@lwn.net>,
	"linux-hwmon@vger.kernel.org" <linux-hwmon@vger.kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>
Subject: Re: [PATCH 1/3] hwmon: max31827: Add PEC support
Date: Mon, 18 Dec 2023 08:26:50 -0800	[thread overview]
Message-ID: <5baa93fe-bd08-4f11-9c5c-42060e89930c@roeck-us.net> (raw)
In-Reply-To: <PH0PR03MB6771B89E4D3291BA0B1B5ABF8990A@PH0PR03MB6771.namprd03.prod.outlook.com>

On 12/18/23 06:55, Matyas, Daniel wrote:
[ ... ]
>> On top of that, it is not clear why regmap can't be used in the first place.
>> It seems that the major change is that one needs to read the configuration
>> register after a write to see if there was a PEC error. It is not immediately
>> obvious why that additional read (if indeed necessary) would require
>> regmap support to be dropped.
>>
> 
> I tried out writing and and reading with regmap, but it is not working properly. Even if I modify the client flag, I still receive only 2 bytes of data (a word). I should be receiving 2+1 bytes = data + CRC-8.
> 
> With i2c_smbus reads and writes, when I set the flag, I receive the 2+1 bytes, as expected.
> 

The SMBus code in drivers/i2c/i2c-core-smbus.c is supposed to check
if the received PEC is correct for SMBus transfers. Are you saying
that this doesn't work, or that regmap doesn't use SMBus functions
to communicate with the chip ?

Thanks,
Guenter


  reply	other threads:[~2023-12-18 16:26 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-14 14:36 [PATCH 1/3] hwmon: max31827: Add PEC support Daniel Matyas
2023-12-14 14:36 ` Daniel Matyas
2023-12-14 14:36 ` [PATCH 2/3] bindings: hwmon: Add adi,adaq4224_temp as compatible string Daniel Matyas
2023-12-14 14:36   ` Daniel Matyas
2023-12-14 15:15   ` Guenter Roeck
2023-12-14 15:39     ` Conor Dooley
2023-12-15  8:49   ` Krzysztof Kozlowski
2023-12-15 16:03     ` Guenter Roeck
2023-12-18  9:08       ` Matyas, Daniel
2023-12-18 17:22         ` Guenter Roeck
2023-12-19 16:47           ` Conor Dooley
2023-12-14 14:36 ` [PATCH 3/3] hwmon: max31827: Compatible for adaq4224 Daniel Matyas
2023-12-14 14:36   ` Daniel Matyas
2023-12-14 15:14   ` Guenter Roeck
2023-12-14 16:10 ` [PATCH 1/3] hwmon: max31827: Add PEC support Guenter Roeck
2023-12-15 20:28   ` Matyas, Daniel
2023-12-16  1:32     ` Guenter Roeck
2023-12-18  9:12       ` Matyas, Daniel
2023-12-18 16:18         ` Guenter Roeck
2023-12-18 14:55   ` Matyas, Daniel
2023-12-18 16:26     ` Guenter Roeck [this message]
     [not found]       ` <PH0PR03MB6771CF6A95CB576E534C225F8990A@PH0PR03MB6771.namprd03.prod.outlook.com>
2023-12-18 19:01         ` Guenter Roeck
2023-12-20  1:49           ` Matyas, Daniel
2024-01-08 17:42             ` Guenter Roeck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5baa93fe-bd08-4f11-9c5c-42060e89930c@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=Daniel.Matyas@analog.com \
    --cc=conor+dt@kernel.org \
    --cc=corbet@lwn.net \
    --cc=devicetree@vger.kernel.org \
    --cc=jdelvare@suse.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.