mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Mika Westerberg <mika.westerberg@linux.intel.com>,
	Jan Kiszka <jan.kiszka@siemens.com>
Cc: linux-iio@vger.kernel.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Sascha Weisenberger <sascha.weisenberger@siemens.com>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	Rob Herring <robh@kernel.org>
Subject: Re: [PATCH v3] iio: adc: Add support for TI ADC108S102 and ADC128S102
Date: Fri, 5 May 2017 19:50:31 +0100	[thread overview]
Message-ID: <92acddc4-47d7-2739-9a9b-6831c226369a@kernel.org> (raw)
In-Reply-To: <20170505104026.GS2697@lahna.fi.intel.com>

On 05/05/17 11:40, Mika Westerberg wrote:
> On Fri, May 05, 2017 at 12:23:26PM +0200, Jan Kiszka wrote:
>>>> +	} else {
>>>> +		st->reg = devm_regulator_get(&spi->dev, "vref");
>>>> +		if (IS_ERR(st->reg))
>>>> +			return PTR_ERR(st->reg);
>>>
>>> This should be an optional regulator and in case of ACPI you just don't
>>> have it.
>>
>> It's mandatory for this DT case, so I will not change that.
> 
> Well, it would be better if you don't need to deviate in the driver like
> this. And it clearly is optional because in case of ACPI you don't need
> it.
> 
> Not my call, though.
> 
I'd keep it as mandatory. The ACPI case is more of a workaround of
a lack of information than anything.  The only way you could make it optional
would be to simply not provide the scale if it wasn't there.
(to do that have two channel sets and switch between them depending on its
presence).

We'd do it as optional if there was an existing binding defined where it wasn't
specified (not much use having the fake regulator show up but be unable to
answer the what voltage question ;)

Jonathan

  reply	other threads:[~2017-05-05 18:50 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-05  6:31 Jan Kiszka
2017-05-05  9:40 ` Mika Westerberg
2017-05-05 10:23   ` Jan Kiszka
2017-05-05 10:40     ` Mika Westerberg
2017-05-05 18:50       ` Jonathan Cameron [this message]
2017-05-05  9:54 ` Andy Shevchenko
2017-05-05 10:39   ` Jan Kiszka
2017-05-05 18:52     ` Jonathan Cameron
2017-05-05 20:09       ` Jan Kiszka
2017-05-05 20:32         ` Andy Shevchenko
2017-05-07 11:19           ` Jonathan Cameron
2017-05-05 18:55 ` Jonathan Cameron
2017-05-05 19:09   ` Andy Shevchenko
2017-05-07 11:17     ` 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=92acddc4-47d7-2739-9a9b-6831c226369a@kernel.org \
    --to=jic23@kernel.org \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=jan.kiszka@siemens.com \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=pmeerw@pmeerw.net \
    --cc=robh@kernel.org \
    --cc=sascha.weisenberger@siemens.com \
    /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

all inboxes | Powered by JetHome®