diff options
| author | Peter Wemm <peter@FreeBSD.org> | 2001-11-17 00:42:02 +0000 |
|---|---|---|
| committer | Peter Wemm <peter@FreeBSD.org> | 2001-11-17 00:42:02 +0000 |
| commit | 1b27b1ad082f8852528ac4d4d6415e31523176b8 (patch) | |
| tree | f86797b8c4d298e13cd9b0f65828a7a0a0a3597b | |
| parent | 4584bbf55565ae23b67a44d1c194bb1abca83845 (diff) | |
Notes
| -rw-r--r-- | sys/kern/kern_mtxpool.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/kern/kern_mtxpool.c b/sys/kern/kern_mtxpool.c index cc856bc700c4..32670231ab08 100644 --- a/sys/kern/kern_mtxpool.c +++ b/sys/kern/kern_mtxpool.c @@ -51,7 +51,10 @@ static __inline struct mtx * _mtx_pool_find(void *ptr) { - return(&mtx_pool_ary[((int)ptr ^ ((int)ptr >> 6)) & MTX_POOL_MASK]); + uintptr_t p; + + p = (uintptr_t)ptr; + return(&mtx_pool_ary[(p ^ (p >> 6)) & MTX_POOL_MASK]); } static void |
