Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys QUOTACTL_CLEAR -> QUOTACTL_DELETE to match intended API ...
details: https://anonhg.NetBSD.org/src/rev/605f790c0202
branches: trunk
changeset: 773187:605f790c0202
user: dholland <dholland%NetBSD.org@localhost>
date: Sun Jan 29 06:54:34 2012 +0000
description:
QUOTACTL_CLEAR -> QUOTACTL_DELETE to match intended API and user API.
diffstat:
sys/kern/vfs_quotactl.c | 28 ++++++++++++++--------------
sys/sys/quotactl.h | 10 +++++-----
sys/ufs/ufs/ufs_quota.c | 24 ++++++++++++------------
sys/ufs/ufs/ufs_quota.h | 4 ++--
sys/ufs/ufs/ufs_quota2.c | 6 +++---
5 files changed, 36 insertions(+), 36 deletions(-)
diffs (208 lines):
diff -r c829253d3d6d -r 605f790c0202 sys/kern/vfs_quotactl.c
--- a/sys/kern/vfs_quotactl.c Sun Jan 29 06:53:35 2012 +0000
+++ b/sys/kern/vfs_quotactl.c Sun Jan 29 06:54:34 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_quotactl.c,v 1.18 2012/01/29 06:53:35 dholland Exp $ */
+/* $NetBSD: vfs_quotactl.c,v 1.19 2012/01/29 06:54:34 dholland Exp $ */
/*
* Copyright (c) 1991, 1993, 1994
@@ -80,7 +80,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_quotactl.c,v 1.18 2012/01/29 06:53:35 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_quotactl.c,v 1.19 2012/01/29 06:54:34 dholland Exp $");
#include <sys/mount.h>
#include <sys/quota.h>
@@ -491,22 +491,22 @@
defaultq = 0;
}
- args.qc_type = QCT_CLEAR;
- args.u.clear.qc_idtype = q2type;
- args.u.clear.qc_id = id;
- args.u.clear.qc_defaultq = defaultq;
- args.u.clear.qc_objtype = QUOTA_OBJTYPE_BLOCKS;
- error = VFS_QUOTACTL(mp, QUOTACTL_CLEAR, &args);
+ args.qc_type = QCT_DELETE;
+ args.u.delete.qc_idtype = q2type;
+ args.u.delete.qc_id = id;
+ args.u.delete.qc_defaultq = defaultq;
+ args.u.delete.qc_objtype = QUOTA_OBJTYPE_BLOCKS;
+ error = VFS_QUOTACTL(mp, QUOTACTL_DELETE, &args);
if (error) {
goto err;
}
- args.qc_type = QCT_CLEAR;
- args.u.clear.qc_idtype = q2type;
- args.u.clear.qc_id = id;
- args.u.clear.qc_defaultq = defaultq;
- args.u.clear.qc_objtype = QUOTA_OBJTYPE_FILES;
- error = VFS_QUOTACTL(mp, QUOTACTL_CLEAR, &args);
+ args.qc_type = QCT_DELETE;
+ args.u.delete.qc_idtype = q2type;
+ args.u.delete.qc_id = id;
+ args.u.delete.qc_defaultq = defaultq;
+ args.u.delete.qc_objtype = QUOTA_OBJTYPE_FILES;
+ error = VFS_QUOTACTL(mp, QUOTACTL_DELETE, &args);
if (error) {
goto err;
}
diff -r c829253d3d6d -r 605f790c0202 sys/sys/quotactl.h
--- a/sys/sys/quotactl.h Sun Jan 29 06:53:35 2012 +0000
+++ b/sys/sys/quotactl.h Sun Jan 29 06:54:34 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: quotactl.h,v 1.16 2012/01/29 06:53:35 dholland Exp $ */
+/* $NetBSD: quotactl.h,v 1.17 2012/01/29 06:54:34 dholland Exp $ */
/*-
* Copyright (c) 2011 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -44,15 +44,15 @@
#define QUOTACTL_GET 3
#define QUOTACTL_PUT 4
#define QUOTACTL_GETALL 5
-#define QUOTACTL_CLEAR 6
+#define QUOTACTL_DELETE 6
/* Argument encoding. */
enum vfs_quotactl_argtypes {
- QCT_PROPLIB, /* quotaon/off, get, set, getall, clear */
+ QCT_PROPLIB, /* quotaon/off, getall */
QCT_GETVERSION, /* getversion */
QCT_GET, /* get */
QCT_PUT, /* put */
- QCT_CLEAR, /* clear */
+ QCT_DELETE, /* delete */
};
struct vfs_quotactl_args {
enum vfs_quotactl_argtypes qc_type;
@@ -78,7 +78,7 @@
id_t qc_id;
int qc_defaultq;
int qc_objtype;
- } clear;
+ } delete;
} u;
};
diff -r c829253d3d6d -r 605f790c0202 sys/ufs/ufs/ufs_quota.c
--- a/sys/ufs/ufs/ufs_quota.c Sun Jan 29 06:53:35 2012 +0000
+++ b/sys/ufs/ufs/ufs_quota.c Sun Jan 29 06:54:34 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_quota.c,v 1.90 2012/01/29 06:53:35 dholland Exp $ */
+/* $NetBSD: ufs_quota.c,v 1.91 2012/01/29 06:54:34 dholland Exp $ */
/*
* Copyright (c) 1982, 1986, 1990, 1993, 1995
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ufs_quota.c,v 1.90 2012/01/29 06:53:35 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ufs_quota.c,v 1.91 2012/01/29 06:54:34 dholland Exp $");
#if defined(_KERNEL_OPT)
#include "opt_quota.h"
@@ -79,7 +79,7 @@
struct vfs_quotactl_args *args);
static int quota_handle_cmd_getall(struct mount *, struct lwp *,
struct vfs_quotactl_args *args);
-static int quota_handle_cmd_clear(struct mount *, struct lwp *,
+static int quota_handle_cmd_delete(struct mount *, struct lwp *,
struct vfs_quotactl_args *args);
static int quota_handle_cmd_quotaon(struct mount *, struct lwp *,
struct vfs_quotactl_args *args);
@@ -178,8 +178,8 @@
case QUOTACTL_GETALL:
error = quota_handle_cmd_getall(mp, l, args);
break;
- case QUOTACTL_CLEAR:
- error = quota_handle_cmd_clear(mp, l, args);
+ case QUOTACTL_DELETE:
+ error = quota_handle_cmd_delete(mp, l, args);
break;
default:
panic("Invalid quotactl operation %d\n", op);
@@ -312,7 +312,7 @@
}
static int
-quota_handle_cmd_clear(struct mount *mp, struct lwp *l,
+quota_handle_cmd_delete(struct mount *mp, struct lwp *l,
struct vfs_quotactl_args *args)
{
struct ufsmount *ump = VFSTOUFS(mp);
@@ -322,11 +322,11 @@
int objtype;
int error;
- KASSERT(args->qc_type == QCT_CLEAR);
- idtype = args->u.clear.qc_idtype;
- id = args->u.clear.qc_id;
- defaultq = args->u.clear.qc_defaultq;
- objtype = args->u.clear.qc_objtype;
+ KASSERT(args->qc_type == QCT_DELETE);
+ idtype = args->u.delete.qc_idtype;
+ id = args->u.delete.qc_id;
+ defaultq = args->u.delete.qc_defaultq;
+ objtype = args->u.delete.qc_objtype;
if ((ump->um_flags & UFS_QUOTA2) == 0)
return EOPNOTSUPP;
@@ -339,7 +339,7 @@
goto err;
#ifdef QUOTA2
if (ump->um_flags & UFS_QUOTA2) {
- error = quota2_handle_cmd_clear(ump, idtype, id,
+ error = quota2_handle_cmd_delete(ump, idtype, id,
defaultq, objtype);
} else
#endif
diff -r c829253d3d6d -r 605f790c0202 sys/ufs/ufs/ufs_quota.h
--- a/sys/ufs/ufs/ufs_quota.h Sun Jan 29 06:53:35 2012 +0000
+++ b/sys/ufs/ufs/ufs_quota.h Sun Jan 29 06:54:34 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_quota.h,v 1.12 2012/01/29 06:53:35 dholland Exp $ */
+/* $NetBSD: ufs_quota.h,v 1.13 2012/01/29 06:54:34 dholland Exp $ */
/*
* Copyright (c) 1982, 1986, 1990, 1993, 1995
@@ -127,7 +127,7 @@
struct quotaval *);
int quota2_handle_cmd_put(struct ufsmount *, const struct quotakey *,
const struct quotaval *);
-int quota2_handle_cmd_clear(struct ufsmount *, int, int, int, int);
+int quota2_handle_cmd_delete(struct ufsmount *, int, int, int, int);
int quota2_handle_cmd_getall(struct ufsmount *, int, prop_array_t);
int q2sync(struct mount *);
int dq2get(struct vnode *, u_long, struct ufsmount *, int, struct dquot *);
diff -r c829253d3d6d -r 605f790c0202 sys/ufs/ufs/ufs_quota2.c
--- a/sys/ufs/ufs/ufs_quota2.c Sun Jan 29 06:53:35 2012 +0000
+++ b/sys/ufs/ufs/ufs_quota2.c Sun Jan 29 06:54:34 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_quota2.c,v 1.13 2012/01/29 06:53:36 dholland Exp $ */
+/* $NetBSD: ufs_quota2.c,v 1.14 2012/01/29 06:54:34 dholland Exp $ */
/*-
* Copyright (c) 2010 Manuel Bouyer
* All rights reserved.
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ufs_quota2.c,v 1.13 2012/01/29 06:53:36 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ufs_quota2.c,v 1.14 2012/01/29 06:54:34 dholland Exp $");
#include <sys/buf.h>
#include <sys/param.h>
@@ -708,7 +708,7 @@
return 0;
}
int
-quota2_handle_cmd_clear(struct ufsmount *ump, int idtype, int id,
+quota2_handle_cmd_delete(struct ufsmount *ump, int idtype, int id,
int defaultq, int objtype)
{
int error, i, canfree;
Home |
Main Index |
Thread Index |
Old Index