Davinci - Support PYHs with MDIO address != 0
PATCH 1/1 Davinci - Support PYHs with MDIO address != 0
Hello,
I'm trying to build the latest version of u-boot for the Hawkboard. In order to so this successfully, I had to make a small patch in order for u-boot to recognize the ethernet PHY.
I don't know if this is the proper way of solving this issue, but it is a working suggestion at least.
I tried to send this patch as an attachment but I got an auto-response saying that base64-encoded attachments were not allowed. So I will just paste the patch here realizing that I will probably introduce some whitespace errors.
PATCH 1/1 Davinci - Support PYHs with MDIO address != 0
Dear Tobias Knutsson,
Quoted 4 lines · In message <[email protected]> you…
I'm trying to build the latest version of u-boot for the Hawkboard. In order to so this successfully, I had to make a small patch in order for u-boot to recognize the ethernet PHY.
Hawkboard? I don't see support for any such board in mainline.
Quoted 4 lines
I tried to send this patch as an attachment but I got an auto-response saying that base64-encoded attachments were not allowed. So I will just paste the patch here realizing that I will probably introduce some whitespace errors.
Why don't you use "git send-email" then?
Quoted 8 lines
From
acf6164774e9d4440c644d1c04ccddb2e6adcc6fMon Sep 17 00:00:00 2001
From: Tobias Knutsson <[email protected]>
Date: Thu, 25 Mar 2010 14:17:12 +0100
Subject: [PATCH] [Davinci] Support PYHs with MDIO address !=3D 0Insert ifdef statement to allow board configuration to override default PHY MDIO address.
---
We need your Signed-off-by: line for a patch - please see
http://www.denx.de/wiki/U-Boot/Patches for details.
Review
Quoted 6 lines
/* PHY mask - set only those phy number bits where phy is/can be connected= */
(quoted diff) +2
-0+#ifndef EMAC_MDIO_PHY_NUM #define EMAC_MDIO_PHY_NUM 1 +#endif #define EMAC_MDIO_PHY_MASK (1 << EMAC_MDIO_PHY_NUM)
Not a single board in mainline defines EMAC_MDIO_PHY_NUM so this change does notreally make sense to me.
Which source tree is it supposed to be applid to?
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: [email protected] You don't have to worry about me. I might have been born yesterday... but I stayed up all night.
Paulraj
PATCH 1/1 Davinci - Support PYHs with MDIO address != 0
Quoted 7 lines
Subject: Re: [U-Boot] [PATCH] Davinci - Support PYHs with MDIO address != 0
Dear Tobias Knutsson,
Quoted 8 lines
In message <[email protected]>
Quoted 4 lines · you
I'm trying to build the latest version of u-boot for the Hawkboard. In order to so this successfully, I had to make a small patch in order for u-boot to recognize the ethernet PHY.
Hawkboard? I don't see support for any such board in mainline.
Yes that is correct
The Hawkboard is based on the OMAP L 138 and that board is not in mainline U-Boot.
PATCH 1/1 Davinci - Support PYHs with MDIO address != 0
In reply to Wolfgang DenkQuoted 9 lines · Wolfgang Denk
Dear Tobias Knutsson,
Quoted 4 lines · In message <[email protected]> you…
I'm trying to build the latest version of u-boot for the Hawkboard. In order to so this successfully, I had to make a small patch in order for u-boot to recognize the ethernet PHY.
Hawkboard? I don't see support for any such board in mainline.
No, there are no patches available for the latest version of U-boot. I'm working on a basic board patch aswell, but it might be that the developers of the board should provide this functionality, not me.
Quoted 7 lines
Quoted 5 lines
I tried to send this patch as an attachment but I got an auto-response saying that base64-encoded attachments were not allowed. So I will just paste the patch here realizing that I will probably introduce some whitespace errors.
Why don't you use "git send-email" then?
I'm located behind a corporate firewall which makes using that command non-trivial.
Quoted 13 lines
Quoted 9 lines
From
acf6164774e9d4440c644d1c04ccddb2e6adcc6fMon Sep 17 00:00:00 2001
From: Tobias Knutsson <[email protected]>
Date: Thu, 25 Mar 2010 14:17:12 +0100
Subject: [PATCH] [Davinci] Support PYHs with MDIO address !=3D 0Insert ifdef statement to allow board configuration to override default PHY MDIO address.
---We need your Signed-off-by: line for a patch - please see
http://www.denx.de/wiki/U-Boot/Patches for details.
Quoted 9 lines
Quoted 6 lines
?/* PHY mask - set only those phy number bits where phy is/can be connected= ?*/
+#ifndefEMAC_MDIO_PHY_NUM
?#defineEMAC_MDIO_PHY_NUM? ? ? ? ? 1
+#endif
?#defineEMAC_MDIO_PHY_MASK? ? ? ? ?(1 <<EMAC_MDIO_PHY_NUM)Not a single board in mainline defines
EMAC_MDIO_PHY_NUMso this change does notreally make sense to me.
Correct, none of the currently supported boards have to do this since their boards ethernet PHYs have an MDIO address of 0x0. The problem is that the general davinci assumes that all boards looks like this. This is not true, the PHY on the Hawkboard for example, has an address of 0x07. Without the ability to change this constant, that PHY will not be detected and no ethernet communication will be available.
When I noticed this, I figured that it might be of interest to other people out there working with davinci-based boards so I decided to supply a patch. Again, not sure this is the _proper_ fix, but it is _a_ fix.
Quoted 3 lines
Which source tree is it supposed to be applid to?
It should apply against the latest GIT-tree.
Quoted 11 lines
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, ? ? MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de You don't have to worry about me. I might have been born yesterday... but I stayed up all night.
Signature · 2 lines
H?lsningar/Regards Tobias Knutsson