netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fs_enet: fix freescale FCC ethernet dp buffer alignment
@ 2011-06-17  8:30 Holger Brunck
  2011-06-17  9:09 ` 答复: " 杨勇
  2011-06-17 19:21 ` David Miller
  0 siblings, 2 replies; 5+ messages in thread
From: Holger Brunck @ 2011-06-17  8:30 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Clive Stubbings, Holger Brunck, Pantelis Antoniou, Vitaly Bordug,
	netdev

From: Clive Stubbings <clive.stubbings@xentech.co.uk>

The RIPTR and TIPTR  (receive/transmit internal temporary data pointer),
used by microcode as a temporary buffer for data, must be 32-byte aligned
according to the RM for MPC8247.

Tested on mgcoge.

Signed-off-by: Clive Stubbings <clive.stubbings@xentech.co.uk>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Pantelis Antoniou <pantelis.antoniou@gmail.com>
cc: Vitaly Bordug <vbordug@ru.mvista.com>
cc: netdev@vger.kernel.org
---
This fixes a kernel crash on mgcoge when using SPI on CPM2 and
ethernet over FCC. Now fixed because the fcc driver now allocates
the space he really needs.

 drivers/net/fs_enet/mac-fcc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/fs_enet/mac-fcc.c b/drivers/net/fs_enet/mac-fcc.c
index 7a84e45..7583a95 100644
--- a/drivers/net/fs_enet/mac-fcc.c
+++ b/drivers/net/fs_enet/mac-fcc.c
@@ -105,7 +105,7 @@ static int do_pd_setup(struct fs_enet_private *fep)
 		goto out_ep;
 
 	fep->fcc.mem = (void __iomem *)cpm2_immr;
-	fpi->dpram_offset = cpm_dpalloc(128, 8);
+	fpi->dpram_offset = cpm_dpalloc(128, 32);
 	if (IS_ERR_VALUE(fpi->dpram_offset)) {
 		ret = fpi->dpram_offset;
 		goto out_fcccp;
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-06-20  4:01 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-17  8:30 [PATCH] fs_enet: fix freescale FCC ethernet dp buffer alignment Holger Brunck
2011-06-17  9:09 ` 答复: " 杨勇
2011-06-17 10:16   ` David Laight
2011-06-20  4:01     ` ??: " ??
2011-06-17 19:21 ` David Miller

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).