From a23d65bfc81ba69197bec5dcc814e36783f02f46 Mon Sep 17 00:00:00 2001 From: Bruce Evans Date: Wed, 15 Jul 1998 02:32:35 +0000 Subject: Cast pointers to uintptr_t/intptr_t instead of to u_long/long, respectively. Most of the longs should probably have been u_longs, but this changes is just to prevent warnings about casts between pointers and integers of different sizes, not to fix poorly chosen types. --- sys/fs/nullfs/null_subr.c | 4 ++-- sys/fs/procfs/procfs_mem.c | 4 ++-- sys/fs/specfs/spec_vnops.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'sys/fs') diff --git a/sys/fs/nullfs/null_subr.c b/sys/fs/nullfs/null_subr.c index 7244d0565352..e4d49b6430cb 100644 --- a/sys/fs/nullfs/null_subr.c +++ b/sys/fs/nullfs/null_subr.c @@ -35,7 +35,7 @@ * * @(#)null_subr.c 8.7 (Berkeley) 5/14/95 * - * $Id: null_subr.c,v 1.16 1998/02/06 12:13:36 eivind Exp $ + * $Id: null_subr.c,v 1.17 1998/02/09 06:09:45 eivind Exp $ */ #include "opt_debug_nullfs.h" @@ -60,7 +60,7 @@ */ #define NULL_NHASH(vp) \ - (&null_node_hashtbl[(((u_long)vp)>>LOG2_SIZEVNODE) & null_node_hash]) + (&null_node_hashtbl[(((uintptr_t)vp)>>LOG2_SIZEVNODE) & null_node_hash]) static LIST_HEAD(null_node_hashhead, null_node) *null_node_hashtbl; static u_long null_node_hash; diff --git a/sys/fs/procfs/procfs_mem.c b/sys/fs/procfs/procfs_mem.c index 27cb4f5205b2..c1012f1cb253 100644 --- a/sys/fs/procfs/procfs_mem.c +++ b/sys/fs/procfs/procfs_mem.c @@ -37,7 +37,7 @@ * * @(#)procfs_mem.c 8.5 (Berkeley) 6/15/94 * - * $Id: procfs_mem.c,v 1.32 1998/05/19 00:00:14 tegge Exp $ + * $Id: procfs_mem.c,v 1.33 1998/06/07 17:11:57 dfr Exp $ */ /* @@ -159,7 +159,7 @@ procfs_rwmem(curp, p, uio) fill_eproc (p, &p->p_addr->u_kproc.kp_eproc); /* locate the in-core address */ - tkva = (u_long)p->p_addr + uva - VM_MAXUSER_ADDRESS; + tkva = (uintptr_t)p->p_addr + uva - VM_MAXUSER_ADDRESS; /* transfer it */ error = uiomove((caddr_t)tkva, len, uio); diff --git a/sys/fs/specfs/spec_vnops.c b/sys/fs/specfs/spec_vnops.c index cb9a1209866d..7f05eb213663 100644 --- a/sys/fs/specfs/spec_vnops.c +++ b/sys/fs/specfs/spec_vnops.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)spec_vnops.c 8.14 (Berkeley) 5/21/95 - * $Id: spec_vnops.c,v 1.65 1998/07/04 22:30:23 julian Exp $ + * $Id: spec_vnops.c,v 1.66 1998/07/11 07:45:48 bde Exp $ */ #include @@ -430,7 +430,7 @@ spec_ioctl(ap) ap->a_fflag, ap->a_p)); case VBLK: - if (ap->a_command == 0 && (long)ap->a_data == B_TAPE) + if (ap->a_command == 0 && (intptr_t)ap->a_data == B_TAPE) if ((bdevsw[major(dev)]->d_flags & D_TYPEMASK) == D_TAPE) return (0); -- cgit v1.2.3