Re: [RFC V3] test bit before clear files_struct bits
From: Andrew Morton
Date: Wed Feb 18 2015 - 16:27:21 EST
On Sun, 15 Feb 2015 16:27:27 +0800 "Wang, Yalin" <Yalin.Wang@xxxxxxxxxxxxxx> wrote:
> + * __*_if_need version is used in cases that you don't want write a bit which
> + * have been set / clear, to avoid dirty cacheline.
> + */
> +static inline void __set_bit_if_need(int nr, volatile unsigned long *addr)
"if_need" is gramatically incorrect - it should be "if_needed".
And __set_bit_if_needed is too long. But I can't think of anything
shorter, unless we do something lame like __set_bit2().
__set_bit_if_clear() isn't too bad?
Also, your changelog still doesn't include the results of the
quantitative testing which you performed to demonstrate that these code
sites will benefit from this conversion. Please copy all that info
into the changelog!
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/