[U-Boot-Users] Port for M5329EVB ColdFire MCF5329 eval board - needs network!

Hi all,
I've been working on a port for the Freescale/LogicPD eval board with the ColdFire MCF5329 microcontroller. I've got it up and running from flash and all. No network yet - and I'm not sure how to proceed there. It seems from an example or two that U-Boot network drivers are usually fairly simple. Is it true that a simple polled driver is sufficient?
I'd like to get Ethernet working, but I have more pressing concerns right now, so I can't really spend a lot of time on it. However, I'd be interested in working with others, and certainly would welcome a bit more guidance; I haven't really found much in the way of an "Ethernet Driver How-To", and I've looked. Of course, I could have missed it...
On a different topic, I would like to submit my BSP. I don't know how interested people would be, given its current state - no Ethernet, and frankly, not extensively tested. I will be using it over the next few months, so I'd expect these to improve, but it's probably not really ready for formal inclusion. What does one do in such situations? What is the process for new BSPs, especially incomplete "beta" versions?
Thanks for your time, -Bob

Hi Robert, --- "Robert S. Grimes" rsg@alum.mit.edu wrote:
Hi all,
I've been working on a port for the Freescale/LogicPD eval board with the ColdFire MCF5329 microcontroller. I've got it up and running from flash and all. No network yet - and I'm not sure how to proceed there. It seems from an example or two that U-Boot network drivers are usually fairly simple. Is it true that a simple polled driver is sufficient?
Yes. Everything's polled. No interrupt funny business.
I'd like to get Ethernet working, but I have more pressing concerns right now, so I can't really spend a lot of time on it. However, I'd be interested in working with others, and certainly would welcome a bit more guidance; I haven't really found much in the way of an "Ethernet Driver How-To", and I've looked. Of course, I could have missed it...
I worked a bit with a Coldfire (5328 I think) a couple of years ago and remember that its Ethernet controller was very similar to the SCC/FCC/TSEC controllers that you find on 68360 and PowerQUICC chips. I have no personal experience here, but I would wager that it's also pretty similar to the FEC on the older MCF52x2 Coldfires. Bottom line - this should be a cut & paste job. Look in cpu/bcf52x2/fec.c, cpu/mpc8xx/fec.c, ...
On a different topic, I would like to submit my BSP. I don't know how interested people would be, given its current state - no Ethernet, and frankly, not extensively tested. I will be using it over the next few months, so I'd expect these to improve, but it's probably not really ready for formal inclusion. What does one do in such situations? What is the process for new BSPs, especially incomplete "beta" versions?
There's no point putting your BSP in the main tree until it's complete and tested. That said, you're always welcome to post code for review. Just clearly label it as such and be patient.
regards, Ben

Hi Ben,
Ben Warren wrote:
Yes. Everything's polled. No interrupt funny business.
Thanks, that's quite comforting to know.
I worked a bit with a Coldfire (5328 I think) a couple of years ago and remember that its Ethernet controller was very similar to the SCC/FCC/TSEC controllers that you find on 68360 and PowerQUICC chips. I have no personal experience here, but I would wager that it's also pretty similar to the FEC on the older MCF52x2 Coldfires. Bottom line - this should be a cut & paste job. Look in cpu/bcf52x2/fec.c, cpu/mpc8xx/fec.c, ...
That's what I would have thought, but I've heard this is not true, and I've seen some small differences myself. I would like to know which ColdFire variant it is closest to, or that is is so different that I should not bother and start from scratch.
I also grabbed Freescale's dBug sources last night, which has working drivers for the mcf532x. Does anyone know if those are interrupt-driven? (Yeah, I know, look at the source! Just, if someone already knows...)
There's no point putting your BSP in the main tree until it's complete and tested. That said, you're always welcome to post code for review. Just clearly label it as such and be patient.
Well, yes, there is a point - it would allow others to use it, or even better, work with me to improve it :-P . But of course, your are right that it shouldn't be in the main tree until it is ready. So if it is the operating convention here, I'm happy to comply.
So what do I do? Create a patch and post it?
Is that what all those "[PATCH]' messages are? I had thought those were enhancements/fixes for existing code.
Not big questions, and I would think I could make it clear enough on my own, but I don't want to make any troubles here.
regards, Ben

On Thu, 2007-06-14 at 07:24 -0400, Robert S. Grimes wrote:
Hi Ben,
Ben Warren wrote:
Yes. Everything's polled. No interrupt funny business.
Thanks, that's quite comforting to know.
I worked a bit with a Coldfire (5328 I think) a couple of years ago and remember that its Ethernet controller was very similar to the SCC/FCC/TSEC controllers that you find on 68360 and PowerQUICC chips. I have no personal experience here, but I would wager that it's also pretty similar to the FEC on the older MCF52x2 Coldfires. Bottom line - this should be a cut & paste job. Look in cpu/bcf52x2/fec.c, cpu/mpc8xx/fec.c, ...
That's what I would have thought, but I've heard this is not true, and I've seen some small differences myself. I would like to know which ColdFire variant it is closest to, or that is is so different that I should not bother and start from scratch.
I'm not saying they're identical, but the programming models are very similar. You should not have to start from scratch. The best thing to do is to download the datasheet for a chip that has a driver, and the datasheet for your chip. Compare the registers for the Ethernet controllers. You will see an eerie amount of similarity. Sure, some of the buffer descriptor bits may be different and the buffers may be in a different memory, but that's small stuff.
I also grabbed Freescale's dBug sources last night, which has working drivers for the mcf532x. Does anyone know if those are interrupt-driven? (Yeah, I know, look at the source! Just, if someone already knows...)
There's no point putting your BSP in the main tree until it's complete and tested. That said, you're always welcome to post code for review. Just clearly label it as such and be patient.
Well, yes, there is a point - it would allow others to use it, or even better, work with me to improve it :-P . But of course, your are right that it shouldn't be in the main tree until it is ready. So if it is the operating convention here, I'm happy to comply.
So what do I do? Create a patch and post it?
Is that what all those "[PATCH]' messages are? I had thought those were enhancements/fixes for existing code.
Messages with [PATCH] are exactly that - enhancements or bug fixes that are intended for inclusion. If you're looking for a code review, put something like [RFC] in the subject. There's no hard-and-fast rule, just make it clear that you want feedback.
regards, Ben

Robert,
I already have the port for MCF5329 with network controller. So far, I have not updated to the Denx git server yet.
The cpu polling network is sufficient enough for bootloader. Once it is in linux or other os, the network driver has to be interrupt base rather than polling.
Regards, TsiChung
-----Original Message----- From: u-boot-users-bounces@lists.sourceforge.net [mailto:u-boot-users-bounces@lists.sourceforge.net] On Behalf Of Robert S. Grimes Sent: Wednesday, June 13, 2007 9:15 PM To: Das U-Boot Mailing List Subject: [U-Boot-Users] Port for M5329EVB ColdFire MCF5329 eval board -needs network!
Hi all,
I've been working on a port for the Freescale/LogicPD eval board with the ColdFire MCF5329 microcontroller. I've got it up and running from flash and all. No network yet - and I'm not sure how to proceed there.
It seems from an example or two that U-Boot network drivers are usually fairly simple. Is it true that a simple polled driver is sufficient?
I'd like to get Ethernet working, but I have more pressing concerns right now, so I can't really spend a lot of time on it. However, I'd be interested in working with others, and certainly would welcome a bit more guidance; I haven't really found much in the way of an "Ethernet Driver How-To", and I've looked. Of course, I could have missed it...
On a different topic, I would like to submit my BSP. I don't know how interested people would be, given its current state - no Ethernet, and frankly, not extensively tested. I will be using it over the next few months, so I'd expect these to improve, but it's probably not really ready for formal inclusion. What does one do in such situations? What is the process for new BSPs, especially incomplete "beta" versions?
Thanks for your time, -Bob
------------------------------------------------------------------------ - This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ U-Boot-Users mailing list U-Boot-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/u-boot-users

Hello!
On 14 jun 2007, at 04:14, Robert S. Grimes wrote:
Hi all,
I've been working on a port for the Freescale/LogicPD eval board with the ColdFire MCF5329 microcontroller. I've got it up and running from flash and all. No network yet - and I'm not sure how to proceed there. It seems from an example or two that U-Boot network drivers are usually fairly simple. Is it true that a simple polled driver is sufficient?
Yes it is sufficient. I have actually quite recently made a U-Boot port to the Cobra5329-board, working with flash, serial and ethernet network.. The whole package is not quite in a submittable state right now, but I will do it as soon as I find the time.
I'd like to get Ethernet working, but I have more pressing concerns right now, so I can't really spend a lot of time on it. However, I'd be interested in working with others, and certainly would welcome a bit more guidance; I haven't really found much in the way of an "Ethernet Driver How-To", and I've looked. Of course, I could have missed it...
I could assemble a patch with the ethernet stuff pretty soon.
Best regards, Thomas
participants (4)
-
Ben Warren
-
Liew Tsi Chung-r5aahp
-
Robert S. Grimes
-
Thomas Jansson