From: Alexandre Belloni <alexandre.belloni@bootlin.com>
To: "Miclaus, Antoniu" <Antoniu.Miclaus@analog.com>
Cc: Guenter Roeck <linux@roeck-us.net>,
Alessandro Zummo <a.zummo@towertech.it>,
Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Conor Dooley <conor+dt@kernel.org>,
Jean Delvare <jdelvare@suse.com>,
"linux-rtc@vger.kernel.org" <linux-rtc@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-hwmon@vger.kernel.org" <linux-hwmon@vger.kernel.org>
Subject: Re: [PATCH 2/2] drivers: rtc: max31335: initial commit
Date: Tue, 31 Oct 2023 14:54:32 +0100 [thread overview]
Message-ID: <202310311354329a21a9d0@mail.local> (raw)
In-Reply-To: <CY4PR03MB339979DBB7ADBFC3872156019BA0A@CY4PR03MB3399.namprd03.prod.outlook.com>
On 31/10/2023 11:23:49+0000, Miclaus, Antoniu wrote:
> > > + if (status != MAX31335_STATUS1_DEFAULT)
> > > + dev_err_probe(&client->dev, -EINVAL,
> > > + "Unable to read from device.\n");
> > > +
> >
> > That is misleading. The device returned an unexpected status.
> > I don't know if this really reflects a problem, but it is not
> > "Unable to read from device".
> >
>
> Since the device lacks an ID register, I found this as a suitable
> replacement for checking that the communication with the
> device actually works before the probe function finishes
> successfully.
>
> I will be more specific in the dev_err_probe message in the
> upcoming patch version.
>
What if this is a transient bus error and the device is actually present
and working?
don't like this kind of check, they are not usually useful.
--
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
next prev parent reply other threads:[~2023-10-31 13:54 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-30 11:50 [PATCH 0/2] Add support for RTC MAX31335 Antoniu Miclaus
2023-10-30 11:50 ` [PATCH 1/2] dt-bindings: rtc: max31335: add max31335 bindings Antoniu Miclaus
2023-10-30 17:24 ` Krzysztof Kozlowski
2023-10-31 9:36 ` Miclaus, Antoniu
2023-10-31 10:29 ` Miclaus, Antoniu
2023-10-31 13:53 ` Krzysztof Kozlowski
2023-10-31 14:44 ` Miclaus, Antoniu
2023-10-31 12:06 ` Rob Herring
2023-10-30 11:50 ` [PATCH 2/2] drivers: rtc: max31335: initial commit Antoniu Miclaus
2023-10-30 17:28 ` Krzysztof Kozlowski
2023-10-30 18:11 ` Guenter Roeck
2023-10-31 11:23 ` Miclaus, Antoniu
2023-10-31 13:54 ` Alexandre Belloni [this message]
2023-10-31 14:43 ` Miclaus, Antoniu
2023-10-31 13:58 ` Guenter Roeck
2023-10-31 11:36 ` Christophe JAILLET
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=202310311354329a21a9d0@mail.local \
--to=alexandre.belloni@bootlin.com \
--cc=Antoniu.Miclaus@analog.com \
--cc=a.zummo@towertech.it \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jdelvare@suse.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rtc@vger.kernel.org \
--cc=linux@roeck-us.net \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox