summaryrefslogtreecommitdiff
path: root/sys/ufs
diff options
context:
space:
mode:
authorBob Beck <beck@cvs.openbsd.org>2023-07-05 15:13:29 +0000
committerBob Beck <beck@cvs.openbsd.org>2023-07-05 15:13:29 +0000
commit558d8e8fbf2be958e31a189dec47abe2eb0fbc5b (patch)
treea19dbfe4ae07a6494e5e4d536f661d0a92645265 /sys/ufs
parent0f4abbd043963de02ccbc56816aac8ab1dbc08cf (diff)
Make softdep mounts a no-op
Softdep is a significant impediment to progressing in the vfs layer so we plan to get it out of the way. It is too clever for us to continue maintaining as it is. ok kettenis@ kn@ tobhe@ and most of the g2k23 room except bluhm@
Diffstat (limited to 'sys/ufs')
-rw-r--r--sys/ufs/ffs/ffs_softdep.c4
-rw-r--r--sys/ufs/ffs/ffs_vfsops.c18
2 files changed, 7 insertions, 15 deletions
diff --git a/sys/ufs/ffs/ffs_softdep.c b/sys/ufs/ffs/ffs_softdep.c
index 15017537b41..e4d56ebc42b 100644
--- a/sys/ufs/ffs/ffs_softdep.c
+++ b/sys/ufs/ffs/ffs_softdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ffs_softdep.c,v 1.151 2023/04/11 00:45:09 jsg Exp $ */
+/* $OpenBSD: ffs_softdep.c,v 1.152 2023/07/05 15:13:28 beck Exp $ */
/*
* Copyright 1998, 2000 Marshall Kirk McKusick. All Rights Reserved.
@@ -1224,6 +1224,8 @@ softdep_mount(struct vnode *devvp, struct mount *mp, struct fs *fs,
struct buf *bp;
int error, cyl;
+ KASSERTMSG(1, "softdep_mount should not have been called");
+
/*
* When doing soft updates, the counters in the
* superblock may have gotten out of sync, so we have
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c
index ffe78ef140f..8c780d5340b 100644
--- a/sys/ufs/ffs/ffs_vfsops.c
+++ b/sys/ufs/ffs/ffs_vfsops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ffs_vfsops.c,v 1.194 2023/04/14 22:41:28 mbuhl Exp $ */
+/* $OpenBSD: ffs_vfsops.c,v 1.195 2023/07/05 15:13:28 beck Exp $ */
/* $NetBSD: ffs_vfsops.c,v 1.19 1996/02/09 22:22:26 christos Exp $ */
/*
@@ -213,12 +213,10 @@ ffs_mount(struct mount *mp, const char *path, void *data,
int error = 0, flags;
int ronly;
-#ifndef FFS_SOFTUPDATES
+ /* Ask not for whom the bell tolls */
if (mp->mnt_flag & MNT_SOFTDEP) {
- printf("WARNING: soft updates isn't compiled in\n");
mp->mnt_flag &= ~MNT_SOFTDEP;
}
-#endif
/*
* Soft updates is incompatible with "async",
@@ -284,8 +282,6 @@ ffs_mount(struct mount *mp, const char *path, void *data,
if (mp->mnt_flag & MNT_FORCE)
flags |= FORCECLOSE;
error = softdep_flushfiles(mp, flags, p);
-#elif FFS_SOFTUPDATES
- mp->mnt_flag |= MNT_SOFTDEP;
#endif
}
/*
@@ -459,10 +455,7 @@ success:
free(fs->fs_contigdirs, M_UFSMNT, fs->fs_ncg);
}
if (!ronly) {
- if (mp->mnt_flag & MNT_SOFTDEP)
- fs->fs_flags |= FS_DOSOFTDEP;
- else
- fs->fs_flags &= ~FS_DOSOFTDEP;
+ fs->fs_flags &= ~FS_DOSOFTDEP;
}
ffs_sbupdate(ump, MNT_WAIT);
#if 0
@@ -923,10 +916,7 @@ ffs_mountfs(struct vnode *devvp, struct mount *mp, struct proc *p)
}
fs->fs_fmod = 1;
fs->fs_clean = 0;
- if (mp->mnt_flag & MNT_SOFTDEP)
- fs->fs_flags |= FS_DOSOFTDEP;
- else
- fs->fs_flags &= ~FS_DOSOFTDEP;
+ fs->fs_flags &= ~FS_DOSOFTDEP;
error = ffs_sbupdate(ump, MNT_WAIT);
if (error == EROFS)
goto out;