linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Laxman Dewangan <ldewangan@nvidia.com>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: "linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>
Subject: Re: Query about Open drain flag with active LOW
Date: Tue, 28 Mar 2017 19:28:46 +0530	[thread overview]
Message-ID: <58DA6C16.2000307@nvidia.com> (raw)
In-Reply-To: <CACRpkda5jFraJsd5CtjQkxo_nUYLnhsfSwMfacPnJYenwCP=VA@mail.gmail.com>


On Tuesday 28 March 2017 06:38 PM, Linus Walleij wrote:
> On Tue, Mar 28, 2017 at 11:03 AM, Laxman Dewangan <ldewangan@nvidia.com> wrote:
>
>
>
> I think it should be
>          if (of_flags & OF_GPIO_SINGLE_ENDED) {
>                  if (of_flags & OF_GPIO_ACTIVE_LOW)
>                          *flags |= GPIO_OPEN_SOURCE;
>                  else
>                          *flags |= GPIO_OPEN_DRAIN;
>          }
>
>
> Similar change is needed in the dtbinding gpio header also to invert the
> ACTIVE state with open drain/source.
> OK I think there are no real users of this feature yet, so it would be great if
> you could send a patch, especially if you also have hardware so you can test it.
>

Thinking more, active low/high for line is independent of the open 
drain/source behavior.
Per my understanding, Active low/high depends on the how external device 
provides signal or glue logic designed. Open drain/source is kind of 
setting pin state between GND or VDD or high impedance.

Let me send patch on decoupling the active HIGH/LOW with open 
drain/source and discuss more in the patch.


Thanks,
Laxman




-----------------------------------------------------------------------------------
This email message is for the sole use of the intended recipient(s) and may contain
confidential information.  Any unauthorized review, use, disclosure or distribution
is prohibited.  If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
-----------------------------------------------------------------------------------

      reply	other threads:[~2017-03-28 14:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-27 15:21 Query about Open drain flag with active LOW Laxman Dewangan
2017-03-28  9:06 ` Linus Walleij
2017-03-28  9:03   ` Laxman Dewangan
2017-03-28 13:08     ` Linus Walleij
2017-03-28 13:58       ` Laxman Dewangan [this message]

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=58DA6C16.2000307@nvidia.com \
    --to=ldewangan@nvidia.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.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;
as well as URLs for NNTP newsgroup(s).