linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Dean Matsen <deanmatsen@earthlink.net>
To: linuxppc-embedded@lists.linuxppc.org
Subject: Ethernet PHY chip discovery not working on 855T with 971/972 chips
Date: Tue, 08 Jul 2003 19:17:12 -0700	[thread overview]
Message-ID: <3F0B7B28.7040902@earthlink.net> (raw)


To whomever maintains the file arch/ppc/8xx_io/fec.c:

I note the following code in mii_discover_phy() :

     fep = dev->priv;

     if ((phytype = (mii_reg & 0xffff)) != 0xffff) {

         /* Got first part of ID, now get remainder.
         */

In our devices, reading the first word with the wrong address yields the
value 0, not 0xFFFF.  This happens even if we play with it by hand.  The
search goes through address 0, 1, 2, .., and our chip is hard-coded at
address 1.  What happens is the kernel panics with something like
"Don't know what chip ID 0000FFFF is".  Anyway, I changed it to the
following, and it finds our PHY correctly now.

     fep = dev->priv;

     phytype = (mii_reg & 0xffff);
     if (phytype != 0xffff && phytype != 0x0000) {

         /* Got first part of ID, now get remainder.
         */

I am guessing that probably most devices have the PHY chip at address
zero, so nobody else has run into this problem because it finds their
chip in the first iteration.

You may also want to note in the file that it supports 972 chips (which
apparently look like 971 chips from the inside, 'cuz that's what the
kernel says it is).  Perhaps the printk() should be updated to say
"971/972" instead of just "971"?


Thanks
Dean Matsen


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

             reply	other threads:[~2003-07-09  2:17 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-09  2:17 Dean Matsen [this message]
2003-07-09  2:29 ` Ethernet PHY chip discovery not working on 855T with 971/972 chips Dean Matsen
2003-07-09  2:56   ` Eugene Surovegin
2003-07-09  5:21     ` Dan Malek
2003-07-09  5:50       ` Dean Matsen
2003-07-09 14:37         ` Dan Malek
2003-07-09 16:39           ` Dean Matsen
2003-07-09 20:54           ` Dean Matsen
2003-07-09 21:21             ` Wolfgang Denk
     [not found]               ` <20030711151834.GU17433@ip68-0-152-218.tc.ph.cox.net>
2003-07-11 15:43                 ` Wolfgang Denk
2003-07-11 15:52                   ` Tom Rini
2003-07-11 18:29                     ` Wolfgang Denk
2003-07-11 18:50                       ` Tom Rini
2003-07-11 19:18                         ` Wolfgang Denk
2003-07-11 19:34                           ` Tom Rini
2003-07-11 21:04                             ` Wolfgang Denk
2003-07-14  6:21                         ` Pantelis Antoniou
2003-07-14  7:58                           ` Wolfgang Denk
2003-07-14 14:31                             ` Tom Rini
2003-07-14 19:26                               ` Wolfgang Denk
2003-07-15 15:04                                 ` Tom Rini
2003-07-11 23:21                 ` Dean Matsen
2003-07-12  1:01                   ` Paul Mackerras
2003-07-12 21:13                     ` Dean Matsen
2003-07-12 21:54                       ` Wolfgang Denk
2003-07-14 14:52                       ` Tom Rini
2003-07-13 15:48                     ` Dan Malek
2003-07-13 16:29                       ` Roland Dreier
2003-07-14 20:49                         ` Matt Porter
2003-07-15  5:08                           ` Roland Dreier

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=3F0B7B28.7040902@earthlink.net \
    --to=deanmatsen@earthlink.net \
    --cc=linuxppc-embedded@lists.linuxppc.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).