This is the mail archive of the ecos-patches@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PPC40x serial_init fix


On Fri, 2 Sep 2005, Gary Thomas wrote:

On Fri, 2005-09-02 at 16:34 +0200, Markus Schade wrote:
serial initialization failed to set UART Divisor in DCR register
when calculation baud clock.
added calculation for PPC405EP

What is this "CFG_BASE_BAUD" all about? How can you know that value is correct for all platforms? The code I wrote uses the actual settings in the CPU to calculate these and should work for any platform. If it does not, let's fix it, but correctly.

That is something I got from the linux kernel or u-boot bootloader. take arch/ppc/platforms/4xx/cpci405.h or any other.

You just took the value from the CPU without actually setting the UART
divisor. That means, you never really modified the divisor depending on CPU speed and desired baud rate, which is necessary (besides setting
the DLM and DLL registers).


Regards,
Markus


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]