From: "Davey" <daveywu@transengines.com>
To: <linuxppc-embedded@lists.linuxppc.org>
Subject: patch for ibm 405ep emac driver in linux-2.4.22 and 2.4.23
Date: Tue, 23 Dec 2003 15:10:21 +0800 [thread overview]
Message-ID: <001d01c3c923$db2ca3c0$5100a8c0@davey> (raw)
In-Reply-To: 1072105831.4163.15.camel@localhost.localdomain
[-- Attachment #1: Type: text/plain, Size: 1841 bytes --]
stefan, Matt,
Some time ago Stefan and I had reported that both ethernet interfaces cannot work well together. Sorry I have lost all old mails when I reinstall my computer.
We have find that this problem is caused by that the base address of eht1 is wrong set. Follow by my patch for linux-2.4.22 and linux-2.4.23. I have test the patch and it work well.
Davey Wu
2003-12-23
-----------------------------------------------------------------------------------------------------------------
diff -Nur /home/davey/linuxppc/drivers/net/ibm_emac/ibm_ocp_enet.c ibm_emac/ibm_ocp_enet.c
--- /home/davey/linuxppc/drivers/net/ibm_emac/ibm_ocp_enet.c 2003-11-24 16:07:49.000000000 +0800
+++ ibm_emac/ibm_ocp_enet.c 2003-12-21 15:59:26.000000000 +0800
@@ -1151,7 +1151,7 @@
rc = request_irq(dev->irq, emac_mac_irq, 0, "OCP EMAC MAC", dev);
if (rc != 0)
goto bail;
- rc = request_irq(fep->wol_irq, emac_wakeup_irq, 0, "OCP EMAC Wakeup", dev);
+ rc = request_irq(fep->wol_irq, emac_wakeup_irq, SA_SHIRQ, "OCP EMAC Wakeup", dev);
if (rc != 0) {
free_irq(dev->irq, dev);
goto bail;
@@ -1237,6 +1237,9 @@
struct net_device *mdio_ndev = NULL;
int commac_reg = 0;
u32 phy_map;
+ // add by larry porter
+ static int emac_index = 0;
+ //////////////////////////////////
emacdata = (struct ocp_func_emac_data *)ocpdev->def->additions;
if (emacdata == NULL) {
@@ -1292,6 +1295,14 @@
if (rc != 0)
goto bail;
commac_reg = 1;
+
+ //add by larry porter
+ emac_index += 1;
+ if(emac_index == 2)
+ {
+ ocpdev->def->paddr = 0xef600900;
+ }
+ //////////////////////////////////////
/* Map our MMIOs */
ep->emacp = (volatile emac_t *)ioremap(ocpdev->def->paddr, sizeof (emac_t));
------------------------------------------------------------------------------------------------
[-- Attachment #2: ibm_emac.patch --]
[-- Type: application/octet-stream, Size: 1240 bytes --]
diff -Nur /home/davey/linuxppc/drivers/net/ibm_emac/ibm_ocp_enet.c ibm_emac/ibm_ocp_enet.c
--- /home/davey/linuxppc/drivers/net/ibm_emac/ibm_ocp_enet.c 2003-11-24 16:07:49.000000000 +0800
+++ ibm_emac/ibm_ocp_enet.c 2003-12-21 15:59:26.000000000 +0800
@@ -1151,7 +1151,7 @@
rc = request_irq(dev->irq, emac_mac_irq, 0, "OCP EMAC MAC", dev);
if (rc != 0)
goto bail;
- rc = request_irq(fep->wol_irq, emac_wakeup_irq, 0, "OCP EMAC Wakeup", dev);
+ rc = request_irq(fep->wol_irq, emac_wakeup_irq, SA_SHIRQ, "OCP EMAC Wakeup", dev);
if (rc != 0) {
free_irq(dev->irq, dev);
goto bail;
@@ -1237,6 +1237,9 @@
struct net_device *mdio_ndev = NULL;
int commac_reg = 0;
u32 phy_map;
+ // add by larry porter
+ static int emac_index = 0;
+ //////////////////////////////////
emacdata = (struct ocp_func_emac_data *)ocpdev->def->additions;
if (emacdata == NULL) {
@@ -1292,6 +1295,14 @@
if (rc != 0)
goto bail;
commac_reg = 1;
+
+ //add by larry porter
+ emac_index += 1;
+ if(emac_index == 2)
+ {
+ ocpdev->def->paddr = 0xef600900;
+ }
+ //////////////////////////////////////
/* Map our MMIOs */
ep->emacp = (volatile emac_t *)ioremap(ocpdev->def->paddr, sizeof (emac_t));
next prev parent reply other threads:[~2003-12-23 7:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-19 20:23 Free ppc linux configuation tool? Kerl, John
2003-12-19 23:42 ` listmember
2003-12-22 15:10 ` Jeff Angielski
2003-12-23 7:10 ` Davey [this message]
2003-12-23 10:12 ` patch for ibm 405ep emac driver in linux-2.4.22 and 2.4.23 Mark Powell
2003-12-23 17:10 ` Matt Porter
2003-12-24 2:30 ` Davey
2003-12-25 5:49 ` Eugene Surovegin
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='001d01c3c923$db2ca3c0$5100a8c0@davey' \
--to=daveywu@transengines.com \
--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).