]> git.baikalelectronics.ru Git - kernel.git/commit
bitops: protect variables in set_mask_bits() macro
authorMiklos Szeredi <mszeredi@redhat.com>
Mon, 15 Oct 2018 13:43:06 +0000 (15:43 +0200)
committerMiklos Szeredi <mszeredi@redhat.com>
Mon, 15 Oct 2018 13:43:06 +0000 (15:43 +0200)
commit784b75b082cd89b61f06550e9642699ca135f300
tree3d54b865f04f8a707cbca858c75c80065ac4a6ec
parentee5c1978c0091635664373239ac2de86774441f8
bitops: protect variables in set_mask_bits() macro

Unprotected naming of local variables within the set_mask_bits() can easily
lead to using the wrong scope.

Noticed this when "set_mask_bits(&foo->bar, 0, mask)" behaved as no-op.

Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Fixes: 9215b7e810db ("ext4: atomically set inode->i_flags in ext4_set_inode_flags()")
Cc: Theodore Ts'o <tytso@mit.edu>
include/linux/bitops.h