2015-09-12 1:47 GMT+03:00 Andrew Morton :
> On Fri, 11 Sep 2015 10:02:29 +0800 Xishi Qiu wrote:
>> - if (likely(((addr + 7) & KASAN_SHADOW_MASK) >= 7))
>> + if (likely(IS_ALIGNED(addr, 8)))
>> return false;
>
> Wouldn't IS_ALIGNED(addr, KASAN_SHADOW_SC
On 2015/9/12 6:47, Andrew Morton wrote:
> On Fri, 11 Sep 2015 10:02:29 +0800 Xishi Qiu wrote:
>
>> Use IS_ALIGNED() to determine whether the shadow span two bytes.
>> It generates less code and more readable.
>>
>
> Please cc Andrey Ryabinin on kasan patches.
Sorry, my mistake.
>
>> --- a/mm
On Fri, 11 Sep 2015 10:02:29 +0800 Xishi Qiu wrote:
> Use IS_ALIGNED() to determine whether the shadow span two bytes.
> It generates less code and more readable.
>
Please cc Andrey Ryabinin on kasan patches.
> --- a/mm/kasan/kasan.c
> +++ b/mm/kasan/kasan.c
> @@ -120,7 +120,7 @@ static __alwa
Use IS_ALIGNED() to determine whether the shadow span two bytes.
It generates less code and more readable.
Signed-off-by: Xishi Qiu
---
mm/kasan/kasan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/kasan/kasan.c b/mm/kasan/kasan.c
index 7b28e9c..c6ddff1 100644
--- a/mm/
4 matches
Mail list logo