[U-Boot] [PATCH 01/28] net: Remove volatile from all of net except the eth driver interface

Joe Hershberger joe.hershberger at gmail.com
Tue Feb 7 18:41:14 CET 2012


Hi Mike,

On Fri, Feb 3, 2012 at 5:44 AM, Mike Frysinger <vapier at gentoo.org> wrote:
> in general, i like this.  my only concern would be the drivers that might
> break due to incorrect cache management (which the volatile markers happen to
> work around for them).
>
> having the API accept a volatile but then casting it away puts us in a worse
> place i think.  on one hand, our API is saying "we treat it as volatile" when
> we really don't, so any drivers that call it with a volatile don't get build
> warnings.  i'd just drop it from all of the net API so that the drivers which
> do call with a volatile pointer get a build warning -- now the driver
> maintainer knows they have to at least look at something.
> -mike

I'm fine with that... it was my first approach, in fact.  However, I
was concerned that if I submitted a patch that added warnings to every
Ethernet-enabled board, that would be frowned upon.  I think it is the
correct thing to do, but don't have a good feeling for how open people
are to changing an interface like that.  I also did not want to
attempt to revise every net driver in this series.

Wolfgang,

Would you approve of changing the net driver API to not use volatile
buffer pointers and have the driver file warn until the driver
maintainer addresses the warnings?

Thanks,
-Joe


More information about the U-Boot mailing list