Use size_t in place of voff_t in puffs_setrootinfo(3)
Chuck Silvers pointed out that voff_t was also supposed to be kernel-only. The correct type to use in userland would be off_t, but since changing vsize_t to either voff_t or off_t is an ABI change on 32-bit platforms, we use size_t knowing that it is technically incorrect.
This commit is contained in:
parent
52a1252312
commit
f347108ede
|
@ -1,4 +1,4 @@
|
|||
.\" $NetBSD: puffs.3,v 1.65 2021/12/03 14:00:59 pho Exp $
|
||||
.\" $NetBSD: puffs.3,v 1.66 2021/12/03 17:12:17 pho Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 2006, 2007, 2008 Antti Kantee. All rights reserved.
|
||||
.\"
|
||||
|
@ -55,7 +55,7 @@
|
|||
.Fn puffs_setroot "struct puffs_usermount *pu" "struct puffs_node *node"
|
||||
.Ft void
|
||||
.Fo puffs_setrootinfo
|
||||
.Fa "struct puffs_usermount *pu" "enum vtype vt" "voff_t vsize" "dev_t rdev"
|
||||
.Fa "struct puffs_usermount *pu" "enum vtype vt" "size_t vsize" "dev_t rdev"
|
||||
.Fc
|
||||
.Ft struct puffs_node *
|
||||
.Fn puffs_getroot "struct puffs_usermount *pu"
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: puffs.c,v 1.126 2021/12/03 14:00:59 pho Exp $ */
|
||||
/* $NetBSD: puffs.c,v 1.127 2021/12/03 17:12:17 pho Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2005, 2006, 2007 Antti Kantee. All Rights Reserved.
|
||||
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <sys/cdefs.h>
|
||||
#if !defined(lint)
|
||||
__RCSID("$NetBSD: puffs.c,v 1.126 2021/12/03 14:00:59 pho Exp $");
|
||||
__RCSID("$NetBSD: puffs.c,v 1.127 2021/12/03 17:12:17 pho Exp $");
|
||||
#endif /* !lint */
|
||||
|
||||
#include <sys/param.h>
|
||||
|
@ -265,7 +265,7 @@ puffs_getroot(struct puffs_usermount *pu)
|
|||
|
||||
void
|
||||
puffs_setrootinfo(struct puffs_usermount *pu, enum vtype vt,
|
||||
voff_t vsize, dev_t rdev)
|
||||
size_t vsize, dev_t rdev)
|
||||
{
|
||||
struct puffs_kargs *pargs = pu->pu_kargp;
|
||||
|
||||
|
@ -275,7 +275,7 @@ puffs_setrootinfo(struct puffs_usermount *pu, enum vtype vt,
|
|||
}
|
||||
|
||||
pargs->pa_root_vtype = vt;
|
||||
pargs->pa_root_vsize = vsize;
|
||||
pargs->pa_root_vsize = (voff_t)vsize;
|
||||
pargs->pa_root_rdev = rdev;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: puffs.h,v 1.129 2021/12/03 14:00:59 pho Exp $ */
|
||||
/* $NetBSD: puffs.h,v 1.130 2021/12/03 17:12:17 pho Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2005, 2006, 2007 Antti Kantee. All Rights Reserved.
|
||||
|
@ -503,7 +503,7 @@ void puffs_setroot(struct puffs_usermount *,
|
|||
struct puffs_node *);
|
||||
struct puffs_node *puffs_getroot(struct puffs_usermount *);
|
||||
void puffs_setrootinfo(struct puffs_usermount *,
|
||||
enum vtype, voff_t, dev_t);
|
||||
enum vtype, size_t, dev_t);
|
||||
|
||||
void *puffs_getspecific(struct puffs_usermount *);
|
||||
void puffs_setspecific(struct puffs_usermount *, void *);
|
||||
|
|
Loading…
Reference in New Issue