From 5d48cd523c9ab3385534cb37dc88d763188d4383 Mon Sep 17 00:00:00 2001 From: Mark Vitale Date: Fri, 17 Mar 2023 16:24:20 -0400 Subject: [PATCH] SOLARIS: Change K&R declarations to ANSI in osi_inode.c Fix a few functions that were declared without a return type, or were using old-style K&R declarations. [mmeffie: Update commit message.] Change-Id: Ia1f27202cc59e7471899790b37c14054a16bd8ea Reviewed-on: https://gerrit.openafs.org/15359 Tested-by: BuildBot Reviewed-by: Mark Vitale Reviewed-by: Michael Meffie --- src/afs/SOLARIS/osi_inode.c | 64 ++++++++++++++++++++----------------- 1 file changed, 34 insertions(+), 30 deletions(-) diff --git a/src/afs/SOLARIS/osi_inode.c b/src/afs/SOLARIS/osi_inode.c index 2852eee489..67e18e0544 100644 --- a/src/afs/SOLARIS/osi_inode.c +++ b/src/afs/SOLARIS/osi_inode.c @@ -34,13 +34,13 @@ extern int (*ufs_iallocp) (), (*ufs_iupdatp) (), (*ufs_igetp) (), #define AFS_ITIMES_NOLOCK(ip) \ (*ufs_itimes_nolockp)(ip); -getinode(vfsp, dev, inode, ipp, credp, perror) - struct vfs *vfsp; - afs_ucred_t *credp; - struct inode **ipp; - dev_t dev; - ino_t inode; - int *perror; +afs_int32 +getinode(struct vfs *vfsp, + dev_t dev, + ino_t inode, + struct inode **ipp, + afs_ucred_t *credp, + int *perror) { struct inode *ip; afs_int32 code; @@ -75,13 +75,13 @@ getinode(vfsp, dev, inode, ipp, credp, perror) } /* get an existing inode. Common code for iopen, iread/write, iinc/dec. */ -igetinode(vfsp, dev, inode, ipp, credp, perror) - afs_ucred_t *credp; - struct inode **ipp; - struct vfs *vfsp; - dev_t dev; - ino_t inode; - int *perror; +int +igetinode(struct vfs *vfsp, + dev_t dev, + ino_t inode, + struct inode **ipp, + afs_ucred_t *credp, + int *perror) { struct inode *pip, *ip; extern struct osi_dev cacheDev; @@ -135,12 +135,15 @@ igetinode(vfsp, dev, inode, ipp, credp, perror) int CrSync = 1; -afs_syscall_icreate(dev, near_inode, param1, param2, param3, param4, rvp, - credp) - rval_t *rvp; - afs_ucred_t *credp; - long near_inode, param1, param2, param3, param4; - dev_t dev; +int +afs_syscall_icreate(dev_t dev, + long near_inode, + long param1, + long param2, + long param3, + long param4, + rval_t *rvp, + afs_ucred_t *credp) { int dummy, err = 0; struct inode *ip, *newip; @@ -225,11 +228,12 @@ afs_syscall_icreate(dev, near_inode, param1, param2, param3, param4, rvp, return (code); } -afs_syscall_iopen(dev, inode, usrmod, rvp, credp) - rval_t *rvp; - afs_ucred_t *credp; - int inode, usrmod; - dev_t dev; +int +afs_syscall_iopen(dev_t dev, + int inode, + int usrmod, + rval_t *rvp, + afs_ucred_t *credp) { struct file *fp; struct inode *ip; @@ -301,11 +305,11 @@ afs_syscall_iopen(dev, inode, usrmod, rvp, credp) int IncSync = 1; -afs_syscall_iincdec(dev, inode, inode_p1, amount, rvp, credp) - rval_t *rvp; - afs_ucred_t *credp; - int inode, inode_p1, amount; - dev_t dev; +int +afs_syscall_iincdec(dev_t dev, + int inode, int inode_p1, int amount, + rval_t *rvp, + afs_ucred_t *credp) { int dummy; struct inode *ip;