Re: type safe lists (was Re: PATCH: type safe(r) list_entry repacement: generic_out_cast)
Linus Torvalds (torvalds@transmeta.com)
Wed, 24 Jul 2002 21:00:05 +0000 (UTC)
In article <p73d6tdtg2s.fsf@oldwotan.suse.de>, Andi Kleen <ak@suse.de> wrote:
>>
>> As long as your pointers are 32bit this seems to be ok. But on
>> 64bit implementations pointers are not (unsigned long) so this cast
>> seems to be wrong.
>
>A pointer fits into unsigned long on all 64bit linux ports.
>The kernel very heavily relies on that.
Not just the kernel, afaik. I think it's rather tightly integrated into
gcc internals too (ie pointers are eventually just converted to SI
inside the compiler, and making a non-SI pointer would be hard).
Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/