MCF5272 Network Driver Problems - Solved with reservations?

Brett Swimley brett.swimley at
Tue May 7 04:20:58 UTC 2002

Eric and all-

I did mean that my Init function calls rtems_task_delete(RTEMS_SELF).

I Figured it out!.... Turns out it was in the idle task, which wasn't
executing when I stubbed in my new task as I decribed previously.

The network stack is working well.

The problem with the idle task code is that it executes the stop #2000
instruction. I had patched this code several months back because the
standard tight loop did not interact well with the BDM pod polling the
processor (which I was using to spit console output via gdb).

I suggested either:

while (1)
	asm volatile ("	nop");
	asm volatile ("	nop");


while (1)
	asm volatile ("	stop #0x2000");

The consensus was to use the stop instruction, which I implemented.

Seems that if we get into the idle task which executes the stop instruction
while the FEC is trying to transmit, something goes haywire.  I changed the
idle task back to the nops - and everything works wonderfully.

I'm not seeing anything in the Coldfire 5272 reference manual that precludes
executing the stop instruction, but obviously there's something going on
here.  I'm gonna fire off a note to the Coldfire list to see if there are
any workarounds on the 5272 that would allow the idle task to keep the stop

Thanks again for all of the comments.



> -----Original Message-----
> From: Eric Norum [mailto:e.norum at]
> Sent: Monday, May 06, 2002 6:44 PM
> To: brett.swimley at
> Subject: Re: MCF5272 Network Driver Problems - Solved with
> reservations?
> On Monday, May 6, 2002, at 05:12 PM, Brett Swimley wrote:
> > Hi All,
> >
> > While stubbing in another task into my application, I
> discovered that
> > just
> > having another task active, even doing nothing but yielding the
> > processor,
> > causes my Fast Ethernet Controller driver to work correctly.
> >
> > Previously, my Init task initialized the network and then exited.
> What do you mean by `exited'?   Did the task call
> rtems_task_delete(RTEMS_SELF) or did it just return?
> >
> > Now, as a test, I have my Init task only yielding the
> processor after
> > perfoming the network initialization.
> >
> > for (;;) {
> > 	rtems_task_wake_after( RTEMS_YIELD_PROCESSOR );
> > }
> >
> > Would one still suspect my network driver or could this be
> indicative
> > of an
> > issue with the network code?
> >
> --
> Eric Norum <e.norum at>
> Saskatoon, Saskatchewan, CANADA

More information about the users mailing list