Linux IIO development
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Petre Rodan <petre.rodan@subdimension.ro>,
	linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org,
	Lars-Peter Clausen <lars@metafoo.de>,
	Angel Iglesias <ang.iglesiasg@gmail.com>,
	Matti Vaittinen <mazziesaccount@gmail.com>,
	Andreas Klinger <ak@it-klinger.de>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
Subject: Re: [PATCH 2/2] iio: pressure: driver for Honeywell HSC/SSC series pressure sensors
Date: Sat, 25 Nov 2023 19:15:29 +0000	[thread overview]
Message-ID: <20231125191529.2ed1ddfb@jic23-huawei> (raw)
In-Reply-To: <ZV3b5sUrGEj5ZOF0@smile.fi.intel.com>

> 
> > > > +	ret = devm_regulator_get_enable_optional(dev, "vdd");
> > > > +	if (ret == -EPROBE_DEFER)
> > > > +		return -EPROBE_DEFER;  
> > > 
> > > Oh, boy, this should check for ENODEV or so, yeah, regulator APIs a bit
> > > interesting.  
> > 
> > since I'm unable to test this I'd rather remove the block altogether.
> > if I go the ENODEV route my module will never load since I can't see any
> > vdd-supply support on my devboard.  
> 
> No, what I meant is to have something like
> 
> 	if (ret) {
> 		if (ret != -ENODEV)
> 			return ret;
> 		...regulator is not present...
> 	}
> 
> This is how it's being used in dozens of places in the kernel. Just utilize
> `git grep ...` which should be a top-10 tool for the Linux kernel developer.

As per my very late reply to previous email. Nope. This regulator is never
not present. It's just a question of whether the firmware tells us what
it is, or it is supplied with a stub regulator.


  reply	other threads:[~2023-11-25 19:15 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-17 16:42 [PATCH 1/2] dt-bindings: iio: pressure: add honeywell,hsc030 Petre Rodan
2023-11-17 16:42 ` [PATCH 2/2] iio: pressure: driver for Honeywell HSC/SSC series pressure sensors Petre Rodan
2023-11-18  5:21   ` [PATCH v2 " kernel test robot
2023-11-20 12:35   ` [PATCH " Andy Shevchenko
2023-11-22  6:08     ` Petre Rodan
2023-11-22 10:45       ` Andy Shevchenko
2023-11-25 19:15         ` Jonathan Cameron [this message]
2023-11-25 19:13       ` Jonathan Cameron
2023-11-17 17:12 ` [PATCH 1/2] dt-bindings: iio: pressure: add honeywell,hsc030 Rob Herring
2023-11-17 19:22 ` [PATCH v2 " Petre Rodan
2023-11-17 20:13   ` Rob Herring
2023-11-19 13:49   ` Rob Herring
2023-11-19 20:14     ` Petre Rodan
2023-11-20 10:15       ` Krzysztof Kozlowski
2023-11-20 17:19       ` Rob Herring
2023-11-20 18:09         ` Petre Rodan
2023-11-20 10:21   ` Krzysztof Kozlowski
2023-11-20 13:42     ` Petre Rodan
2023-11-20 14:04       ` Krzysztof Kozlowski
2023-11-20 14:40         ` Petre Rodan
2023-11-20 17:39           ` Jonathan Cameron
2023-11-20 18:25             ` Petre Rodan
2023-11-25 19:21               ` Jonathan Cameron
2023-11-25 19:19   ` Jonathan Cameron

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=20231125191529.2ed1ddfb@jic23-huawei \
    --to=jic23@kernel.org \
    --cc=ak@it-klinger.de \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=ang.iglesiasg@gmail.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mazziesaccount@gmail.com \
    --cc=petre.rodan@subdimension.ro \
    --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