[U-Boot] [PATCH] arm: Kirkwood: Add memory barriers to kwgbe_send/recv
Prafulla Wadaskar
prafulla at marvell.com
Wed Jul 1 18:57:10 CEST 2009
> -----Original Message-----
> From: u-boot-bounces at lists.denx.de
> [mailto:u-boot-bounces at lists.denx.de] On Behalf Of Simon Kagstrom
> Sent: Wednesday, July 01, 2009 8:46 PM
> To: U-Boot ML
> Subject: [U-Boot] [PATCH] arm: Kirkwood: Add memory barriers
> to kwgbe_send/recv
>
> Add memory barriers to kwgbe_send/recv
>
> kwgbe_send/recv both have loops waiting for the hardware to
> set a bit.
> GCC 4.3.3 cleverly optimizes this to ... a while(1); loop.
Struct used is defined as volatile here.
Is this not sufficient?
Regards..
Prafulla . .
> This patch introduces memory barriers to force re-loading of
> the transmit descriptor.
>
> mb() wasn't defined for arm, but perhaps it should?
More information about the U-Boot
mailing list