devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Daney <ddaney-M3mlKVOIwJVv6pq1l3V1OdBPR1lH4CV8@public.gmane.org>
To: devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org
Subject: How to handle software controlled bus switches in the device tree?
Date: Wed, 06 Apr 2011 09:08:12 -0700	[thread overview]
Message-ID: <4D9C8FEC.8020602@caviumnetworks.com> (raw)

I have some boards that have I2C controlled switches that are used to 
control the connection of Ethernet PHY devices to their MDIO busses.

There are two MDIO busses, and the PHY can be attached to one or the 
other based on the setting of the switch.

I can describe the presence of the switch on the I2C bus, but boot 
software or an operating system needs to set the switch to realize a 
PHY/MDIO bus topology.

Currently we are hard-coding the switch initialization in the bootloader 
and then assuming a fixed PHY topology based on that initialization.

It would be nice to somehow be able to specify the configuration in the 
device tree, but there are some dependencies.

The I2C bus and switch driver would have to be initialized to set the 
switches to the proper values before the MDIO/PHY drivers were started.

Any ideas about how to approach this problem?

Thanks in advance,
David Daney

                 reply	other threads:[~2011-04-06 16:08 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=4D9C8FEC.8020602@caviumnetworks.com \
    --to=ddaney-m3mlkvoiwjvv6pq1l3v1odbpr1lh4cv8@public.gmane.org \
    --cc=devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@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).