Commit Graph

2051 Commits

Author SHA1 Message Date
martin
6a2419fedf Turn a few __unused into __diagused 2013-10-25 11:35:55 +00:00
christos
a6ac3a3be5 remove unused 2013-10-20 17:18:38 +00:00
htodd
05bca19fed Definining needswap where needed. 2013-10-20 00:29:10 +00:00
christos
3b10767488 always declare needswap 2013-10-20 00:20:53 +00:00
christos
f0a3fd2aff always declare needswap 2013-10-20 00:00:51 +00:00
mrg
34287b30e3 convert ufs_rw{16,32,64}() into real inline functions in all cases,
so that they consume their second arguments properly.
2013-10-19 20:12:18 +00:00
martin
2af58edbe2 Mark a potentially unused variable 2013-10-19 19:29:59 +00:00
martin
e13fb3704a Mark unused (in the !FFS_EI case) variables as such. 2013-10-19 19:28:13 +00:00
martin
4618c726c3 Eliminate a variable only used in diagnostic kernels 2013-10-19 19:20:50 +00:00
martin
b59cd17e74 Mark a potentially unused (ifndef FFS_EI) variable 2013-10-19 16:30:57 +00:00
christos
230e69d821 move code inside ifdef 2013-10-18 19:55:37 +00:00
christos
b626e2d9e6 fix unused variable warnings 2013-10-18 19:45:40 +00:00
christos
7f0942b36f use __USE() in the right place, instead of (void)var. 2013-10-18 15:15:22 +00:00
christos
cae86aa949 - remove unused variables
- add debug ifdefs for debugging variables
- __USE() where appropriate.
2013-10-17 21:01:08 +00:00
dholland
31c7ba91f6 Remove stray KERNEL_UNLOCK_ONE() in error path of lfs_markv().
From Wolfgang Stukenbrock in PR 44370.

This error path is only reachable if lfs_markv is handed an out of
range inode number, so it's unlikely that it gets tickled very often.

It isn't clear to me that we need the kernel lock in here at all, as
the path to lfs_markv that's actually used at this point (via fcntl)
doesn't take it. But, one thing at a time.
2013-10-07 05:19:23 +00:00
hannken
3881f4f3f9 Replace macro v_specmountpoint with two functions spec_node_getmountedfs()
and spec_node_setmountedfs() to manage the file system mounted on a device.
Assert the device is a block device.

Welcome to 6.99.24

Discussed on tech-kern@ some time ago.

Reviewed by: David Holland <dholland@netbsd.org>
2013-09-30 18:57:59 +00:00
hannken
18e8787ae5 Function ffs_reload() works on a read-only mount, so remove the call
to ffs_snapshot_mount() as it would panic later with "already on list"
when remounting read-write.

Should fix PR kern/48211 (Unclean shutdown with active snapshot causes
panic during reboot)
2013-09-16 12:36:54 +00:00
martin
7df3c226a1 Remove unused variables 2013-09-15 15:32:18 +00:00
martin
d78264e0ce Remove unused variable 2013-09-15 15:07:06 +00:00
joerg
b3d66acd27 Kill unused function ib_assign. 2013-09-13 20:15:33 +00:00
martin
097ec72497 #ifdef a variable just like their use 2013-09-12 20:00:15 +00:00
dholland
7763dff664 Add the FS_SUJ flag for journaled softupdates from FreeBSD.
This conflicts with our flag for FS_INDEXDIRS. Apparently FreeBSD
changed that arbitrarily on their end when implementing journaled
softupdates, so follow their lead.

Unfortunately, the new value they use for FS_INDEXDIRS conflicts with
our flag FS_DOQUOTA2 for 64-bit quotas. Since the only thing in our
tree that knows about FS_INDEXDIRS is dumpfs (for printing it), leave
FS_INDEXDIRS commented out.

Also add FS_NFS4ACLS from FreeBSD, commented out because it conflicts
with our FS_DOWAPBL, and FS_TRIM.

(We could honor FS_TRIM as we have code for doing that; however I'm
not sure why FreeBSD chose to make it an on-disk flag instead of e.g.
a mount option and it seems problematic to me. In any case, not in
this commit.)

Also see a post I just made in tech-kern about the flag conflicts.
2013-09-03 02:24:01 +00:00
dholland
199aad004d Kill off uo_unmark_vnode/UFS_UNMARK_VNODE as it's now a leftover. 2013-08-11 04:36:17 +00:00
dholland
3b7bdca759 Fix build both with and without options LFS_EI. 2013-07-29 16:40:46 +00:00
dholland
c482f134e6 Revert previous; it is wrong. 2013-07-29 16:39:37 +00:00
pgoyette
3776d454bb Remove more unused variables to unbreak the build. 2013-07-28 04:49:03 +00:00
pgoyette
637c4ef150 Remove unused variable to fix the build. 2013-07-28 04:24:44 +00:00
dholland
ba91b8b1fa Merge the extattr VOPs from ffs.
As these do nothing besides dispatch to ulfs_extattr.c it wasn't
exactly hard.

This might just make extended attributes work on lfs...
2013-07-28 01:27:02 +00:00
dholland
1c11495e64 Merge in some of the stuff for supporting the extended attributes code. 2013-07-28 01:26:13 +00:00
dholland
26f16a77a6 Add more of the bits for supporting quotas. 2013-07-28 01:25:05 +00:00
dholland
8848af09e1 Bring in a copy of ffs_quota2_mount() for reference.
Add stuff to struct lfs that it needs to initialize.
Clear these fields in mount as there's no on-disk support for quota2;
but this increases the chances of being able to add it (or something
like it) in the future.
2013-07-28 01:22:55 +00:00
dholland
d3cfc0d3d4 Migrate the miscellaneous ulfs-level info from struct ulfsmount to
struct lfs.

Put them inside #ifdef _KERNEL there. They are not the only such
members, gross as that is. Unfortunately, moving struct lfs to
lfs_kernel.h does not work.
2013-07-28 01:10:49 +00:00
dholland
5bc8cc2b1c Add lfs_kernel.h for declarations that don't need to be exposed to userland.
lfs currently has the following headers:
   lfs.h - on-disk structures and stuff needed for userlevel tools
   lfs_inode.h - additional restricted materials for userlevel tools
                 that operate the fs (newfs_lfs, fsck_lfs, lfs_cleanerd)
   lfs_kernel.h - stuff needed only in the kernel

and the following legacy headers that are expected to be mopped up and
folded into one of the above:
   lfs_extern.h - function prototypes
   ulfs_bswap.h - endian-independent support
   ulfs_dinode.h - now contains very little
   ulfs_dirhash.h - dirhash support
   ulfs_extattr.h - extattr support
   ulfs_extern.h - more function prototypes
   ulfs_inode.h - assorted kernel-only declarations
   ulfs_quota.h - quota support
   ulfs_quota1.h - more quota support
   ulfs_quota2.h - more quota support
   ulfs_quotacommon.h - more quota support
   ulfsmount.h - legacy copy of ufsmount material
2013-07-28 01:05:52 +00:00
dholland
62ec15fbc5 Remove the now-pointless ulfs ops macros. 2013-07-28 00:37:07 +00:00
dholland
933722845b Remove ulfsspec_close and ulfsfifo_close as they're not used. 2013-07-28 00:31:54 +00:00
dholland
88d53bfd92 Get rid of the ulfs_ops table as we only have one fs in here now. 2013-07-28 00:29:18 +00:00
dholland
a0792c8328 Improve comments in struct ulfsmount.
Also rearrange it to group related items together.
2013-07-28 00:28:33 +00:00
dholland
5e4138d300 Prune unused stuff from struct ulfsmount. 2013-07-28 00:28:05 +00:00
dholland
b7e188bc2a Merge logic from ulfs_close(), ulfs_getattr(), and ulfs_strategy()
into the preexisting lfs_*() versions of these functions, and delete
the unused ulfs copies.
2013-07-21 00:01:22 +00:00
dholland
f15a6faedc Remove ulfs_mknod, which is not used. 2013-07-20 22:16:02 +00:00
dholland
f59e924a8b Merge ulfs_mknod into lfs_mknod, which was missing some bits. 2013-07-20 22:14:49 +00:00
dholland
2aee89e8d5 G/C unused pieces. 2013-07-20 20:01:24 +00:00
dholland
0e93cfc3cb Collect the pieces of lfs rename into lfs_rename.c, and sprinkle static. 2013-07-20 19:59:31 +00:00
matt
ee9af514b0 Remove duplicate define of LFS_MAXNAMLEN 2013-06-28 16:14:06 +00:00
dholland
75571afd93 Stick ffs_ in front of the following macros:
fragstoblks()
   blkstofrags()
   fragnum()
   blknum()

to finish the job of distinguishing them from the lfs versions, which
Christos renamed the other day.

I believe this is the last of the overtly ambiguous exported symbols
from ffs... or at least, the last of the ones that conflicted with lfs.
ffs still pollutes the C namespace very broadly (as does ufs) and this
needs quite a bit more cleanup.

XXX: boo on macros with lowercase names. But I'm not tackling that just yet.
2013-06-23 22:03:34 +00:00
dholland
e1610ba4cb Stick ffs_, ext2_, chfs_, filecore_, cd9660_, or mfs_ in front of
the following symbols so as to disambiguate fully. (Christos already
did the lfs ones.)

   lblkno
   lblktosize
   lfragtosize
   numfrags
   blkroundup
   fragroundup
2013-06-23 07:28:36 +00:00
dholland
9f0b5be4ef typo in comment 2013-06-23 02:07:04 +00:00
dholland
2737439da3 fsbtodb() -> FFS_FSBTODB(), EXT2_FSBTODB(), or MFS_FSBTODB()
dbtofsb() -> FFS_DBTOFSB() or EXT2_DBTOFSB()

(Christos already did the lfs ones a few days back)
2013-06-23 02:06:04 +00:00
dholland
bc706cd48f blkoff -> chfs_blkoff
blksize -> chfs_blksize
2013-06-19 18:15:35 +00:00
dholland
de893df3a9 blkoff() -> ffs_blkoff() stragglers 2013-06-19 18:02:21 +00:00