Staging: meilhaus: Correct use of ! and &
authorJulia Lawall <julia@diku.dk>
Wed, 24 Dec 2008 15:23:37 +0000 (16:23 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 3 Apr 2009 21:53:27 +0000 (14:53 -0700)
commit530ddf8563df4d7af8f8bdd99fa478c63805d0e3
treee2b59daa26eac933b29a653ac56f9154f4754c64
parentc6f5af88438b3e22d56a6b2aafaee5ffc4bc030e
Staging: meilhaus: Correct use of ! and &

ME_IO_SINGLE_TYPE_WRITE_NONBLOCKING and ME_IO_STREAM_CONFIG_WRAPAROUND both
hanve 0 as the rightmost bit, and thus eg
!flags & ME_IO_SINGLE_TYPE_WRITE_NONBLOCKING is always 0.
I assume that !(flags & ME_IO_SINGLE_TYPE_WRITE_NONBLOCKING) and
!(flags & ME_IO_STREAM_CONFIG_WRAPAROUND) were intended.

The semantic patch that makes this change is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@@ expression E; constant C; @@
(
  !E & !C
|
- !E & C
+ !(E & C)
)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/meilhaus/me1600_ao.c
drivers/staging/meilhaus/me4600_ao.c
drivers/staging/meilhaus/me6000_ao.c