Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/bouyer-quota2]: src/sys/ufs Various build fixes
details: https://anonhg.NetBSD.org/src/rev/c4eeb7a7e2db
branches: bouyer-quota2
changeset: 761141:c4eeb7a7e2db
user: bouyer <bouyer%NetBSD.org@localhost>
date: Wed Feb 09 11:18:29 2011 +0000
description:
Various build fixes
diffstat:
sys/ufs/files.ufs | 3 ++-
sys/ufs/lfs/lfs_vfsops.c | 21 ++++-----------------
sys/ufs/ufs/quota.h | 3 +--
sys/ufs/ufs/quota1.h | 3 ++-
sys/ufs/ufs/ufs_quota.c | 16 ++++++++++++++--
sys/ufs/ufs/ufs_quota.h | 13 ++-----------
sys/ufs/ufs/ufs_quota2.c | 14 ++++++++++++--
7 files changed, 37 insertions(+), 36 deletions(-)
diffs (225 lines):
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/files.ufs
--- a/sys/ufs/files.ufs Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/files.ufs Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: files.ufs,v 1.24.6.1 2011/01/20 14:25:01 bouyer Exp $
+# $NetBSD: files.ufs,v 1.24.6.2 2011/02/09 11:18:29 bouyer Exp $
deffs FFS
deffs EXT2FS
@@ -63,6 +63,7 @@
file ufs/ufs/ufs_quota1.c quota & (ffs | lfs | mfs | ext2fs)
file ufs/ufs/ufs_quota2.c quota2 & (ffs | lfs | mfs | ext2fs)
file ufs/ufs/quota2_subr.c quota2 & (ffs | lfs | mfs | ext2fs)
+file ufs/ufs/quota2_prop.c (quota | quota2) & (ffs | lfs | mfs | ext2fs)
file ufs/ufs/ufs_vfsops.c ffs | lfs | mfs | ext2fs
file ufs/ufs/ufs_vnops.c ffs | lfs | mfs | ext2fs
file ufs/ufs/ufs_wapbl.c ffs & wapbl
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/lfs/lfs_vfsops.c
--- a/sys/ufs/lfs/lfs_vfsops.c Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/lfs/lfs_vfsops.c Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lfs_vfsops.c,v 1.287 2010/06/24 13:03:19 hannken Exp $ */
+/* $NetBSD: lfs_vfsops.c,v 1.287.4.1 2011/02/09 11:18:29 bouyer Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2003, 2007, 2007
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: lfs_vfsops.c,v 1.287 2010/06/24 13:03:19 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: lfs_vfsops.c,v 1.287.4.1 2011/02/09 11:18:29 bouyer Exp $");
#if defined(_KERNEL_OPT)
#include "opt_lfs.h"
@@ -1123,21 +1123,8 @@
mutex_exit(&lfs_lock);
#ifdef QUOTA
- if (mp->mnt_flag & MNT_QUOTA) {
- int i;
- error = vflush(mp, fs->lfs_ivnode, SKIPSYSTEM|flags);
- if (error)
- return (error);
- for (i = 0; i < MAXQUOTAS; i++) {
- if (ump->um_quotas[i] == NULLVP)
- continue;
- quotaoff(l, mp, i);
- }
- /*
- * Here we fall through to vflush again to ensure
- * that we have gotten rid of all the system vnodes.
- */
- }
+ if ((error = quota1_umount(mp, flags)) != 0)
+ return (error);
#endif
if ((error = vflush(mp, fs->lfs_ivnode, flags)) != 0)
return (error);
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/ufs/quota.h
--- a/sys/ufs/ufs/quota.h Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/ufs/quota.h Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: quota.h,v 1.25.64.2 2011/01/31 15:19:21 bouyer Exp $ */
+/* $NetBSD: quota.h,v 1.25.64.3 2011/02/09 11:18:29 bouyer Exp $ */
/*
* Copyright (c) 1982, 1986, 1993
@@ -59,7 +59,6 @@
#define INITQFNAMES { \
"user", /* USRQUOTA */ \
"group", /* GRPQUOTA */ \
- "undefined", \
}
/* definition of limits types for each quota */
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/ufs/quota1.h
--- a/sys/ufs/ufs/quota1.h Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/ufs/quota1.h Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: quota1.h,v 1.1.2.2 2011/01/28 23:31:16 bouyer Exp $ */
+/* $NetBSD: quota1.h,v 1.1.2.3 2011/02/09 11:18:30 bouyer Exp $ */
/*
* Copyright (c) 1982, 1986, 1993
@@ -93,6 +93,7 @@
};
/* quota1_subr.c */
+struct quota2_entry;
void dqblk2q2e(const struct dqblk *, struct quota2_entry *);
void q2e2dqblk(const struct quota2_entry *, struct dqblk *);
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/ufs/ufs_quota.c
--- a/sys/ufs/ufs/ufs_quota.c Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/ufs/ufs_quota.c Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_quota.c,v 1.68.4.9 2011/02/08 20:00:53 bouyer Exp $ */
+/* $NetBSD: ufs_quota.c,v 1.68.4.10 2011/02/09 11:18:30 bouyer 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.68.4.9 2011/02/08 20:00:53 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ufs_quota.c,v 1.68.4.10 2011/02/09 11:18:30 bouyer Exp $");
#if defined(_KERNEL_OPT)
#include "opt_quota.h"
@@ -60,6 +60,18 @@
kmutex_t dqlock;
kcondvar_t dqcv;
+const char *quotatypes[MAXQUOTAS] = INITQFNAMES;
+
+/*
+ * Code pertaining to management of the in-core dquot data structures.
+ */
+#define DQHASH(dqvp, id) \
+ (((((long)(dqvp)) >> 8) + id) & dqhash)
+static LIST_HEAD(dqhashhead, dquot) *dqhashtbl;
+static u_long dqhash;
+static pool_cache_t dquot_cache;
+
+
static int quota_handle_cmd_get_version(struct mount *, struct lwp *,
prop_dictionary_t, prop_array_t);
static int quota_handle_cmd_get(struct mount *, struct lwp *,
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/ufs/ufs_quota.h
--- a/sys/ufs/ufs/ufs_quota.h Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/ufs/ufs_quota.h Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_quota.h,v 1.1.2.7 2011/02/08 20:09:56 bouyer Exp $ */
+/* $NetBSD: ufs_quota.h,v 1.1.2.8 2011/02/09 11:18:30 bouyer Exp $ */
/*
* Copyright (c) 1982, 1986, 1990, 1993, 1995
@@ -100,16 +100,7 @@
/*
* Quota name to error message mapping.
*/
-static const char *quotatypes[] = INITQFNAMES;
-
-/*
- * Code pertaining to management of the in-core dquot data structures.
- */
-#define DQHASH(dqvp, id) \
- (((((long)(dqvp)) >> 8) + id) & dqhash)
-static LIST_HEAD(dqhashhead, dquot) *dqhashtbl;
-static u_long dqhash;
-static pool_cache_t dquot_cache;
+const char *quotatypes[MAXQUOTAS];
int getinoquota(struct inode *);
int dqget(struct vnode *, u_long, struct ufsmount *, int, struct dquot **);
diff -r 4de5d56396d1 -r c4eeb7a7e2db sys/ufs/ufs/ufs_quota2.c
--- a/sys/ufs/ufs/ufs_quota2.c Wed Feb 09 10:55:13 2011 +0000
+++ b/sys/ufs/ufs/ufs_quota2.c Wed Feb 09 11:18:29 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_quota2.c,v 1.1.2.10 2011/02/08 20:00:53 bouyer Exp $ */
+/* $NetBSD: ufs_quota2.c,v 1.1.2.11 2011/02/09 11:18:30 bouyer Exp $ */
/*-
* Copyright (c) 2010 Manuel Bouyer
* All rights reserved.
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ufs_quota2.c,v 1.1.2.10 2011/02/08 20:00:53 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ufs_quota2.c,v 1.1.2.11 2011/02/09 11:18:30 bouyer Exp $");
#include <sys/buf.h>
#include <sys/param.h>
@@ -80,7 +80,9 @@
getq2h(struct ufsmount *ump, int type,
struct buf **bpp, struct quota2_header **q2hp, int flags)
{
+#ifdef FFS_EI
const int needswap = UFS_MPNEEDSWAP(ump);
+#endif
int error;
struct buf *bp;
struct quota2_header *q2h;
@@ -134,7 +136,9 @@
uint64_t *offp, int flags, void *a,
int (*func)(struct ufsmount *, uint64_t *, struct quota2_entry *, uint64_t, void *))
{
+#ifdef FFS_EI
const int needswap = UFS_MPNEEDSWAP(ump);
+#endif
daddr_t off = ufs_rw64(*offp, needswap);
struct buf *bp, *obp = hbp;
int ret = 0, ret2 = 0;
@@ -576,7 +580,9 @@
uint64_t off, void *v)
{
struct dq2clear_callback *c = v;
+#ifdef FFS_EI
const int needswap = UFS_MPNEEDSWAP(ump);
+#endif
uint64_t myoff;
if (ufs_rw32(q2e->q2e_uid, needswap) == c->id) {
@@ -770,7 +776,9 @@
{
struct getuids *gu = v;
uid_t *newuids;
+#ifdef FFS_EI
const int needswap = UFS_MPNEEDSWAP(ump);
+#endif
if (gu->nuids == gu->size) {
newuids = realloc(gu->uids, gu->size + PAGE_SIZE, M_TEMP,
@@ -866,7 +874,9 @@
struct dq2get_callback *c = v;
daddr_t lblkno;
int blkoff;
+#ifdef FFS_EI
const int needswap = UFS_MPNEEDSWAP(ump);
+#endif
if (ufs_rw32(q2e->q2e_uid, needswap) == c->id) {
KASSERT(mutex_owned(&c->dq->dq_interlock));
Home |
Main Index |
Thread Index |
Old Index