Re: [PATCH] [8/7] oprofile - dcookies need to use u32

David S. Miller (davem@redhat.com)
Tue, 15 Oct 2002 19:00:19 -0700 (PDT)


From: Ulrich Weigand <weigand@immd1.informatik.uni-erlangen.de>
Date: Wed, 16 Oct 2002 03:56:10 +0200 (MET DST)

+ return (u32)dentry;

Um, isn't this supposed to uniquely identify the dentry?
On a platform with 64-bit pointers there's now the theoretical
possibility of different dentries getting the same cookie ...

That's true.

We dealt with this (trying to use a kernel pointer as a cache held by
userspace) in tcp_diag by making the actual object opaque. It was
actually two u32's, and that way it worked independant of kernel
vs. user word size.

-
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/