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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090708145740.0e5e4b07@feng-desktop>
Date:	Wed, 8 Jul 2009 14:57:40 +0800
From:	Feng Tang <feng.tang@...el.com>
To:	Stephen Rothwell <sfr@...b.auug.org.au>
CC:	"sfi-devel@...plefirmware.org" <sfi-devel@...plefirmware.org>,
	"linux-next@...r.kernel.org" <linux-next@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [SFI-devel] linux-next: sfi tree build warning

On Wed, 8 Jul 2009 14:44:00 +0800
Stephen Rothwell <sfr@...b.auug.org.au> wrote:

> Hi all,
> 
> Today's linux-next build (x86_64 allmodconfig) produced this warning:
> 
> arch/x86/kernel/sfi.c: In function 'sfi_init_memory_map':
> arch/x86/kernel/sfi.c:99: warning: cast to pointer from integer of
> different size arch/x86/kernel/sfi.c:100: warning: cast to pointer
> from integer of different size
> 
Hi Stephen,

Thanks for the finding. Could you help to test the following quick patch?
it should works for both x86_32 and x86_64. thanks

- Feng 

diff --git a/arch/x86/kernel/sfi.c b/arch/x86/kernel/sfi.c
index a96ea0f..b23e489 100644
--- a/arch/x86/kernel/sfi.c
+++ b/arch/x86/kernel/sfi.c
@@ -96,8 +96,9 @@ int __init sfi_init_memory_map(void)
	/* walk through the syst to search the mmap table */
	mmapt = NULL;
	for (i = 0; i < tbl_cnt; i++) {
-		if (!strncmp(SFI_SIG_MMAP, (char *)(u32)*pentry, 4)) {
-			mmapt = (struct sfi_table_simple *)(u32)*pentry;
+		if (!strncmp(SFI_SIG_MMAP, (char *)(unsigned long)*pentry, 4)) {
+			mmapt = (struct sfi_table_simple *)
+					(unsigned long)*pentry;
			break;
                }
		pentry++;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ