summaryrefslogtreecommitdiffstats
path: root/sbin/fsck_ffs/pass1.c
Commit message (Collapse)AuthorAgeFilesLines
* Use the standardized CHAR_BIT constant instead of NBBY in userland.mike2002-09-251-3/+4
|
* Add support to fsck_ffs to account for storage for extendedmckusick2002-09-241-1/+19
| | | | | | attributes. Sponsored by: DARPA & NAI Labs.
* Add a source file where EXTATTR checks will happen and hook it in evenphk2002-09-161-0/+2
| | | | | | if it doesn't do anything yet. Sponsored by: DARPA & NAI Labs.
* s/filesystem/file system/g as discussed on -developerstrhodes2002-08-211-1/+1
|
* Fix a bunch of format string warnings which brokemux2002-07-311-13/+15
| | | | | | the sparc64 build. Tested on: sparc64, i386
* Warning cleanup.phk2002-07-301-3/+2
| | | | Format changes by peter
* Remove the kernel file-size limit for UFS2, so that only the limitiedowse2002-06-261-1/+4
| | | | | | | | | | imposed by the filesystem structure itself remains. With 16k blocks, the maximum file size is now just over 128TB. For now, the UFS1 file size limit is left unchanged so as to remain consistent with RELENG_4, but it too could be removed in the future. Reviewed by: mckusick
* Fix an integer overflow that causes fsck_ffs to crash when itiedowse2002-06-261-1/+1
| | | | | | encounters very large file sizes in the filesystem. Reviewed by: mckusick
* This commit adds basic support for the UFS2 filesystem. The UFS2mckusick2002-06-211-53/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | filesystem expands the inode to 256 bytes to make space for 64-bit block pointers. It also adds a file-creation time field, an ability to use jumbo blocks per inode to allow extent like pointer density, and space for extended attributes (up to twice the filesystem block size worth of attributes, e.g., on a 16K filesystem, there is space for 32K of attributes). UFS2 fully supports and runs existing UFS1 filesystems. New filesystems built using newfs can be built in either UFS1 or UFS2 format using the -O option. In this commit UFS1 is the default format, so if you want to build UFS2 format filesystems, you must specify -O 2. This default will be changed to UFS2 when UFS2 proves itself to be stable. In this commit the boot code for reading UFS2 filesystems is not compiled (see /sys/boot/common/ufsread.c) as there is insufficient space in the boot block. Once the size of the boot block is increased, this code can be defined. Things to note: the definition of SBSIZE has changed to SBLOCKSIZE. The header file <ufs/ufs/dinode.h> must be included before <ufs/ffs/fs.h> so as to get the definitions of ufs2_daddr_t and ufs_lbn_t. Still TODO: Verify that the first level bootstraps work for all the architectures. Convert the utility ffsinfo to understand UFS2 and test growfs. Add support for the extended attribute storage. Update soft updates to ensure integrity of extended attribute storage. Switch the current extended attribute interfaces to use the extended attribute storage. Add the extent like functionality (framework is there, but is currently never used). Sponsored by: DARPA & NAI Labs. Reviewed by: Poul-Henning Kamp <phk@freebsd.org>
* more file system > filesystemtrhodes2002-05-161-1/+1
|
* UFS2 preparation commit:phk2002-05-121-27/+0
| | | | | | | Remove support for converting old FFS formats to newer. Submitted by: mckusick Sponspored by: DARPA & NAI Labs.
* o __P removedimp2002-03-201-7/+4
| | | | | | | o ansi function prototypes o unifdef -D__STDC__ o __dead2 on usage prototype o remove now-bogus main prototype
* Remove 'register' keyword.obrien2002-03-201-4/+4
| | | | | | It does not help modern compilers, and some may take some hit from it. (I also found several functions that listed *every* of its 10 local vars with "register" -- just how many free registers do people think machines have?)
* Fix a large number of -Wall, -Wformat and -W compiler warnings.iedowse2001-11-171-6/+8
| | | | | | | | | These were mainly missing casts or wrong format strings in printf statements, but there were also missing includes, unused variables, functions and arguments. The choice of `long' vs `int' still seems almost random in a lot of places though.
* Additions to run checks on live filesystems. This change will notmckusick2001-03-211-4/+16
| | | | | | | | | affect current systems until fsck is modified to use these new facilities. To try out this change, set the fsck passno to zero in /etc/fstab to cause the filesystem to be mounted without running fsck, then run `fsck_ffs -p -B <filesystem>' after the system has been brought up multiuser to run a background cleanup on <filesystem>. Note that the <filesystem> in question must have soft updates enabled.
* Don't allow special devices of type NODEV (NOUDEV as seen from kernel).tegge2001-02-151-0/+5
| | | | | | They can't be created via mknod and the kernel crashes if it encounters such an inode. Approved by: mckusick
* Fsck_ffs did not properly range-check the inode 'di_size'iedowse2001-01-311-3/+6
| | | | | | | | | | | | | | | | | | | field, so it was possible for a filesystem marked clean by fsck_ffs to cause kernel crashes later when mounted. This could occur when fsck_ffs was used to repair a badly corrupted filesystem. As pointed out by bde, it is not sufficient to restrict di_size to just the superblock fs_maxfilesize limit. The use of 32-bit logical block numbers (both in fsck and the kernel) induces another file size limit which is usually lower than fs_maxfilesize. Also, the old 4.3BSD filesystem does not have fs_maxfilesize initialised. Following this change, fsck_ffs will enforce exactly the same file size limits as are used by the kernel. PR: kern/15065 Discussed with: bde Reviewed by: bde, mckusick
* Add a simple SIGINFO handler to fsck_ffs. Shortly after receipt ofiedowse2000-12-151-0/+6
| | | | | | | | a SIGINFO (normally via Ctrl-T), a line will be output indicating the current phase number and progress information relevant to the current phase. Approved by: mckusick
* added growfs(8) including ffsinfo(8) to the freebsd base systemtomsoft2000-12-091-1/+5
| | | | Reviewed by: grog
* Ensure that block and character devices as well as fifo's and socketsmckusick2000-07-121-0/+6
| | | | | | | | | all have zero length. A non-zero length panic's the kernel when one of these is deleted. PR: 19426 Submitted by: Ian Dowse <iedowse@maths.tcd.ie> Reviewed by: dwmalone@FreeBSD.org
* Teach fsck about snapshot files. These changes should have nomckusick2000-07-061-1/+20
| | | | | | | effect on operation of fsck on filesystems without snapshots. If you get compilation errors, be sure that you have copies of /usr/include/sys/mount.h (1.94), /usr/include/sys/stat.h (1.21), and /usr/include/ufs/ffs/fs.h (1.16) as of July 4, 2000 or later.
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* Cosmetic and documentation changes brought from earlier FreeBSD versions.julian1998-12-031-1/+4
| | | | (e.g. RCS Id:)
* Reviewed by: Don Lewis <Don.Lewis@tsc.tdk.com>julian1998-12-031-21/+89
| | | | | | | | | | | | Submitted by: Kirk McKusick <mckusick@McKusick.COM> Obtained from: Mckusick, BSDI and a host of others This exactly matches Kirks sources imported under the Tag MCKUSICK2. These are as supplied by kirk with one small change needed to compile under freeBSD. Some FreeBSD patches will be added back, though many have been added to Kirk's sources already.
* Restored rev.1.11, which I somehow clobbered in rev.1.12.bde1998-07-061-1/+4
|
* Fixed printf format errors.bde1998-06-281-8/+7
|
* Correct use of .Nm. Add rcsid. Remove unused #includes. Use err(3).charnier1998-06-151-1/+4
|
* Reviewed by: dyson@freebsd.org (john Dyson), dg@root.com (david greenman)julian1998-03-081-4/+12
| | | | | Submitted by: Kirk McKusick (mcKusick@mckusick.com) Obtained from: WHistle development tree
* Restore check for ridiculous directory sizes.peter1997-03-181-2/+2
|
* Finished (?) merging with Lite2: cleaned up #include mess.bde1997-03-121-3/+2
| | | | Fixed style bugs in FreeBSD changes.
* Merge from Lite2. Note that Lite2 has it's own filesystem clean checkpeter1997-03-111-20/+24
| | | | | skipping code that overrides ours sooner. One should be eliminated, but for now it works.
* Remove trailing whitespace.rgrimes1995-05-301-1/+1
|
* Submitted by: phk, added to by bdebde1995-04-021-4/+8
| | | | Fix all the warnings from `gcc -Wall'.
* Woops, last patch was by Wolfgang Solfrank.dg1994-09-091-1/+1
|
* Two fixes from the NetBSD group (Charles Hannum):dg1994-09-091-2/+3
| | | | | | | 1) dir.c: get byte order right in mkentry() 2) pass1.c: When doing -c2 conversion, do secsize reads for a symlink - not doing so was causing the conversion to fail because the device driver can't deal with short reads.
* Fixed so that it can grok old style "fastlinks".dg1994-08-021-1/+1
|
* BSD 4.4 Lite sbin Sourcesrgrimes1994-05-261-0/+314
Note: XNSrouted and routed NOT imported here, they shall be imported with usr.sbin.
OpenPOWER on IntegriCloud