On Tue, 13 Nov 2007 18:30:30 +0100 (CET)
Tilman Schmidt <tilman@imap.cc> wrote:
that's pretty peculiar. We'd only expect to see atomics being used in
conjunction with atomic_add/sub/inc/etc. Here the driver is using an
atomic_t as a state variable. And here's the magic bit:
spin_lock_irqsave(&ucs->lock, flags);
state = atomic_read(&ucs->basstate);
atomic_set(&ucs->basstate, (state & ~clear) | set);
spin_unlock_irqrestore(&ucs->lock, flags);
I'm suspecting that a plain old `int' would be more appropriate here.
-