[U-Boot] [PATCH] arm:kirkwood See to it that sent data is 8-byte aligned

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Thu Aug 20 00:36:51 CEST 2009


On 12:48 Tue 18 Aug     , Simon Kagstrom wrote:
> Thanks for the review Prafulla!
> 
> On Tue, 18 Aug 2009 03:12:07 -0700
> Prafulla Wadaskar <prafulla at marvell.com> wrote:
> 
> > > v2: Malloc send buffer (comment from Stefan Roese)
> > Malloc will always be an overhead.
> 
> It's only allocated once (the first time a non-aligned buffer is
> passed), so the overhead is minimal.
> 
> > I strongly recommend- we should pass aligned buffers from upper layers
> > to avoid such rework in all low level drivers, (few are already
> > aligned).
> 
> We could put the same fix in eth_send instead. Then the issue is really
> just how we know what alignment requirement to go for. I guess one
> could add a field to the eth_device structure to store this and then
> fixup all drivers to supply this.
> 
> If the rest of you thinks this is a good idea, I can cook up a patch.
> Opinions?
some drivers would also have the possibility to have multiple receive buffer
specially when you use dma
so IMHO it make more sense to let each drivers handle it itself

Best Regards,
J.


More information about the U-Boot mailing list