
In message 200710010541.29574.vapier@gentoo.org you wrote:
While it's not a strict requirement, I would expect that you wait until the charatcer has been sent. You have toi add some wait anway - either at the start or at the end of the function, and from the debugging point of view it makes more sense to wait for completion before continuing. Performancewise there will be no difference, I think.
the optimal performance method would be at the start of serial_putc(), spin until a byte has opened up in the hardware fifo, and then queue it up and
Maybe. But in reality, you won;t be able to see a differecne in performance.
But the code will be more complicated and have a higher footprint, which both is a con.
then in the serial_setbrg() function (what does "brg" stand for anyways?),
Baud Rate Generator. This origins from the initial implementation on MPC8xx systems...
the current Blackfin serial driver posts a character into the fifo and then spins until both the fifo and the transmit register is empty ... if there is
I like this implementation. It's simple and straightforward, and you can rely on that the user has seen the caratcer on the line before the function returns. That's a good thing for initial debugging (board bring up).
no higher level API dictacting the requirement (and my quick tests here seem to back that up), then i'll just scrub the code and gain a little bit of
Please don't.
speed and lose a few bytes in code size :)
Reduce code size? To me it seems the changes you described above would take more code.
Best regards,
Wolfgang Denk