[lkml]   [2006]   [Jul]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [patch] spinlocks: remove 'volatile'

On Thu, 6 Jul 2006, Jan Engelhardt wrote:
> >
> > You need to exclude "asm volatile", which is a completely different thing.
> 10077.

Yeah, way too many.

That said, at least _some_ of them are:

- casts to volatile inside arch-specific code serquences (ie the _good_
kind of volatile - associated with _code_ rather than data).

See for example include/asm-i386/io.h for 100% valid examples of this
kind of usage.

- function argument values for functions that need to be able to take an
arbitrary pointer ("const volatile void *" is the most permissive
argument type - anything else the compiler can complain about you
dropping qualifiers)

See include/asm-i386/bitops.h for examples of this kind of volatile.

So I'd expect that maybe one percent of them are actually valid ;)

And I suspect that a huge majority of the truly crapola ones are in
drivers. Oh, well..

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2009-11-18 23:46    [W:0.090 / U:15.964 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site