lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Sat, 11 Jun 2022 10:46:10 +0100
From:   Catalin Marinas <catalin.marinas@....com>
To:     Patrick Wang <patrick.wang.shcn@...il.com>
Cc:     akpm@...ux-foundation.org, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org, yee.lee@...iatek.com
Subject: Re: [PATCH v3 3/3] mm: kmemleak: check physical address when scan

On Sat, Jun 11, 2022 at 11:46:27AM +0800, Patrick Wang wrote:
> I've received an auto build test WARNING from kernel test robot:
> 
>    mm/kmemleak.c: In function 'scan_object':
>   >> arch/powerpc/include/asm/page.h:215:42: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
>        215 | #define __va(x) ((void *)(unsigned long)((phys_addr_t)(x) + VIRT_PHYS_OFFSET))
>            |                                          ^
>      mm/kmemleak.c:1403:19: note: in expansion of macro '__va'
>       1403 |                   __va((void *)object->pointer) :
>            |                   ^~~~

Ah, yes, arm32 has the same issue with phys_addr_t defined as u64 in
some configurations while long is 32-bit.

> So I will replace __va((void *)object->pointer)
> to __va((phys_addr_t)object->pointer) for fixing this warning,

It makes sense.

-- 
Catalin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ