devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Phil Reid <preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
Cc: knaack.h-Mmb7MZpHnFY@public.gmane.org,
	lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org,
	pmeerw-jW+XmwGofnusTnJN9+BGXg@public.gmane.org,
	robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	mark.rutland-5wv7dgnIgG8@public.gmane.org,
	Michael.Hennerich-OyLXuOCK7orQT0dZR+AlfA@public.gmane.org,
	linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 2/2] iio: ad5272: Add support for Analog Devices digital potentiometers
Date: Sun, 14 Jan 2018 13:41:49 +0000	[thread overview]
Message-ID: <20180114134149.39313916@archlinux> (raw)
In-Reply-To: <17f90f57-e1a1-3c5e-4044-fc6673ff1cff-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>

On Thu, 11 Jan 2018 17:00:31 +0800
Phil Reid <preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org> wrote:
...

> > +static int ad5272_probe(struct i2c_client *client,
> > +			const struct i2c_device_id *id)
> > +{
> > +	struct device *dev = &client->dev;
> > +	struct gpio_desc *reset_gpio;
> > +	struct iio_dev *indio_dev;
> > +	struct ad5272_data *data;
> > +	int ret;
> > +
> > +	reset_gpio = devm_gpiod_get_optional(&client->dev, "reset",
> > +		GPIOD_OUT_LOW);  
> Reset line to the chip is active low, so I guess I should really be setting it to GPIOD_OUT_HIGH.
> Instead of having the DT define it as active-low?
> I'm not sure what makes the most sense.

As long as you are consistent it doesn't really matter.  This flexibility is
more relevant for generic code where we might need to make things work across
both options.

Jonathan


--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2018-01-14 13:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-10  6:17 [PATCH 0/2] iio: ad5272: Add support for Analog Devices digital potentiometers Phil Reid
     [not found] ` <1515565051-72535-1-git-send-email-preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
2018-01-10  6:17   ` [PATCH 1/2] dt-bindings: ad5272: Add bindings " Phil Reid
2018-01-10  6:17   ` [PATCH 2/2] iio: ad5272: Add support " Phil Reid
     [not found]     ` <1515565051-72535-3-git-send-email-preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
2018-01-11  9:00       ` Phil Reid
     [not found]         ` <17f90f57-e1a1-3c5e-4044-fc6673ff1cff-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
2018-01-14 13:41           ` Jonathan Cameron [this message]
2018-01-14 13:39       ` Jonathan Cameron
2018-01-15  8:47         ` Phil Reid
     [not found]           ` <7e5f624d-35a4-20a9-337d-8593542630f8-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
2018-01-20 15:25             ` 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=20180114134149.39313916@archlinux \
    --to=jic23-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
    --cc=Michael.Hennerich-OyLXuOCK7orQT0dZR+AlfA@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=knaack.h-Mmb7MZpHnFY@public.gmane.org \
    --cc=lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org \
    --cc=linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=pmeerw-jW+XmwGofnusTnJN9+BGXg@public.gmane.org \
    --cc=preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.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;
as well as URLs for NNTP newsgroup(s).