From: Eugene Surovegin <ebs@innocent.com>
To: linuxppc-embedded@lists.linuxppc.org
Cc: David Gibson <david@gibson.dropbear.id.au>,
Armin Kuster <akuster@dslextreme.com>
Subject: [PATCH] correct initialization sequence in ppc405_enet_open
Date: Wed, 20 Nov 2002 21:47:34 -0800 [thread overview]
Message-ID: <5.1.0.14.2.20021120212220.00aebfa0@pop.prodigy.net> (raw)
Hi!
This patch fixes problem in drivers/net/ibm_ocp/ibm_ocp_enet.c.
Ring buffers initialization (init_rings) is called _after_ enabling MAL rx
channel.
If a packet arrives just after MAL was enabled but before init_rings
initialized buffers, you can see random crashes during EMAC open or receive
descriptor error interrupt.
This bug affects all systems that use drivers/net/ibm_ocp/ibm_ocp_enet.c
(405GP based, 440GP based, etc).
This patch is against current devel_2_4, but I think should apply without
any problems to devel_2_5 also.
Thanks.
===== drivers/net/ibm_ocp/ibm_ocp_enet.c 1.55 vs edited =====
--- 1.55/drivers/net/ibm_ocp/ibm_ocp_enet.c Thu Aug 22 11:29:32 2002
+++ edited/drivers/net/ibm_ocp/ibm_ocp_enet.c Wed Nov 20 21:34:30 2002
@@ -375,13 +375,15 @@
request_irq(BL_MAL_RXEOB,ppc405_eth_rxeob,0,"OCP EMAC RX
EOB",dev);
}
- /* enable all MAL transmit and receive channels */
+ /* init buffer descriptors rings */
+ init_rings(dev);
+ /* enable all MAL transmit and receive channels */
enable_mal_chan(fep);
/* set transmit and receive enable */
out_be32(&emacp->em0mr0, EMAC_M0_TXE | EMAC_M0_RXE);
- init_rings(dev);
+
netif_start_queue(dev);
printk(KERN_NOTICE "%s: IBM EMAC: open completed\n\n", dev->name);
Eugene Surovegin <mailto:ebs@innocent.com>
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
next reply other threads:[~2002-11-21 5:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-11-21 5:47 Eugene Surovegin [this message]
2002-11-21 15:47 ` [PATCH] correct initialization sequence in ppc405_enet_open Matt Porter
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=5.1.0.14.2.20021120212220.00aebfa0@pop.prodigy.net \
--to=ebs@innocent.com \
--cc=akuster@dslextreme.com \
--cc=david@gibson.dropbear.id.au \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.