public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Michael Welling <mwelling@emacinc.com>
To: linux-kernel@vger.kernel.org
Cc: mwelling@emacinc.com, f.fainelli@gmail.com,
	grant.likely@linaro.org, linus.walleij@linaro.org,
	rjw@rjwysocki.net, gregkh@linuxfoundation.org
Subject: GPIO registration for external Ethernet PHY oscillator enable/disable
Date: Thu, 25 Sep 2014 14:17:22 -0500	[thread overview]
Message-ID: <20140925191722.GA2481@sysresccd> (raw)
In-Reply-To: <20140923215226.GA29000@sysresccd>

Looks like my original message got buried in the mailing list.

Lets try this again with a few key developers CC'd.

Original Message:
I have some questions that span multiple subsystems including
gpio/pinctrl, apm, and net subsystems.

On some of our system on module designs, we use a GPIO to toggle the
enable pin on external oscillators. In particular, we are using a 50Mhz
oscillator to drive a clock on a RMII Ethernet PHY.

Though I can configure the pin such that the Ethernet interface works we
are looking to disable the oscillator during APM sleep but after the PHY
is put into a low power mode.

How do I register a GPIO for use in the PHY suspend and resume code?
Can it be handled outside of the PHY driver?
If so how do ensure the appropriate suspend and resume sequencing?

For reference, we are using a Micrel KSZ8081 PHY connected to a
AT91SAMA5D35 processor.

Addendum:
I ran into another situation where a GPIO enabled oscillator was used.
The oscillator in this case drives the master clock for a audio codec.
In the old days (before device tree), I could initialize the GPIO in the
platform board file. Now with device tree I can setup the pin multipler
but the initial state of the GPIO I am not sure how to set.

Is there a way to directly change the state of a GPIO pin from a
devicetree entry?

  reply	other threads:[~2014-09-25 19:17 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-23 21:52 GPIO registration for external Ethernet PHY oscillator enable/disable Michael Welling
2014-09-25 19:17 ` Michael Welling [this message]
2014-09-25 19:56   ` Florian Fainelli
2014-09-26 16:59     ` Michael Welling
2014-09-26 17:16       ` Florian Fainelli
2014-09-26 17:32         ` Michael Welling
2014-09-26 20:04         ` Michael Welling
2014-10-07 14:09           ` Linus Walleij
2014-10-07 16:38             ` Michael Welling
2014-10-07 14:04   ` Linus Walleij
2014-10-07 16:30     ` Michael Welling

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=20140925191722.GA2481@sysresccd \
    --to=mwelling@emacinc.com \
    --cc=f.fainelli@gmail.com \
    --cc=grant.likely@linaro.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rjw@rjwysocki.net \
    /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