summaryrefslogtreecommitdiffstats
path: root/sbin/newfs/mkfs.c
Commit message (Collapse)AuthorAgeFilesLines
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* Don't print a "," after the last superblock.billf1999-08-211-3/+4
| | | | Submitted by: adrian
* Fix bug in mount_mfs whereby mount_mfs would sometimes return beforedillon1999-02-091-4/+27
| | | | | | | the mount is completely active, causing the next few commands attempting to manipulate data on the mount to fail. mount_mfs's parent now tries to wait for the mount point st_dev to change before returning, indicating that the mount has gone active.
* Use explicitly sized types when formatting cylinder groups.dfr1998-08-271-7/+7
|
* Forgot to remove a ';' in my previous commit.charnier1998-08-121-2/+2
|
* Add prototypes. Check malloc() return value. Use err(). Remove unused #includescharnier1998-07-151-50/+83
| | | | Do not \n nor dot terminate syslog()/err() messages. -Wall.
* Fixed printf format errors.bde1998-06-281-16/+18
|
* Fixed overflow in the calculation of the number of inodes per groupbde1998-05-311-1/+1
| | | | | | for filesystems with almost the maximum number of sectors. The maxiumum is 2^31, but overflow is common for that size, and overflow normally occurred here at size (2^31 - 4096).
* Don't create superblocks with size larger than SBSIZE (8192). Thebde1998-01-191-0/+4
| | | | | | | size was rounded up to a multiple of the fragment size, but this gave invalid file systems when the fragment size was > SBSIZE (fsck aborts early on them). Now a fragment size of 32768 seems to work (too-simple tests with fsck and iozone worked).
* Some tweaks to get this to cope with ELF where the address space startspeter1997-09-131-8/+18
| | | | | | | | | | higher up in memory (0x0800000 upwards) rather than near zero (0x1000 for our qmagic a.out format). The method that mount_mfs uses to allocate the memory within data size rlimits for the ram disk is entirely too much of a kludge for my liking. I mean, if it's run as root, surely it makes sense to just raise the resource limits to infinity or something, and if it's a non-root user mount (do these work? with mfs?) it could just fail if it's outside limits.
* Removed "hack to prevent overflow of a 32bit block number". Lite2 has abde1997-07-131-3/+1
| | | | | | | better hack in ffs_vfsops.c. The hack here restricted the maximum file size to 2^39 bytes (512GB). fs_bsize * 2^31 - 1 (16TB for the default blocksize of 8K) would have been better. There is no good way to remove this limit on old BSD4.4 file systems.
* Remove srandomdev fallbackache1997-06-141-2/+1
|
* Fix the mount_mfs case from the last cleanup. The code was (ab)usingpeter1997-03-311-1/+17
| | | | | | | | | | | it's internal malloc() implementation to try and avoid overstepping it's resource limits (yuk!). Remain using libc's malloc(), but check the resource limits right before trying to malloc the ramdisk space and leave some spare memory for libc. In Andrey's words, the internal malloc was "true evil".. Among it's sins is it's ability to allocate less memory than asked for and still return success. stdio would just love that. :-) Reviewed by: ache
* Cleanup STANDALONE stuffache1997-03-241-28/+43
| | | | | | Not replace malloc() family for non-standalone variant Pay attention on malloc() family return code now Use srandomdev() now for RNG initialization
* Add generation number randomization. Newly created filesystems wil nowguido1997-03-231-5/+38
| | | | | | | | | automatically have random generation numbers. The kenel way of handling those also changed. Further it is advised to run fsirand on all your nfs exported filesystems. the code is mostly copied from OpenBSD, with the randomization chanegd to use /dev/urandom Reviewed by: Garrett Obtained from: OpenBSD
* Merge from Lite2:peter1997-03-111-33/+70
| | | | | | - use new getvfsbyname() and mount(2) interface (mount_mfs) - use new fs include files - updated inode / cg layout calculations (?)
* Sweep through the tree fixing mmap() usage:alex1997-01-161-1/+1
| | | | | | | | | | | | - Use MAP_FAILED instead of the constant -1 to indicate failure (required by POSIX). - Removed flag arguments of '0' (required by POSIX). - Fixed code which expected an error return of 0. - Fixed code which thought any address with the high bit set was an error. - Check for failure where no checks were present. Discussed with: bde
* This update adds the support for != 512 byte sector SCSI devices tosos1996-12-011-1/+3
| | | | | | | | | | | | | | | | the sd & od drivers. There is also slight changes to fdisk & newfs in order to comply with different sectorsizes. Currently sectors of size 512, 1024 & 2048 are supported, the only restriction beeing in fdisk, which hunts for the sectorsize of the device. This is based on patches to od.c and the other system files by John Gumb & Barry Scott, minor changes and the sd.c patches by me. There also exist some patches for the msdos filesys code, but I havn't been able to test those (yet). John Gumb (john@talisker.demon.co.uk) Barry Scott (barry@scottb.demon.co.uk)
* ts_sec -> tv_secnate1996-09-201-3/+3
| | | | ts_nsec -> tv_nsec
* A better algorithm to place the numbers on the lines.joerg1996-01-301-17/+17
| | | | Submitted by: satoshi
* Make the numbers for the "superblock backups" fit nicely on the screen,joerg1996-01-251-1/+35
| | | | | even for larger partitions. Until now, partition sizes > 500 MB messed up the screen.
* Remove trailing whitespace.rgrimes1995-05-301-4/+4
|
* Flush stdout when writing out each superblock backup.dg1995-05-021-0/+1
|
* Restrict fs_maxfilesize to 2^40; this is part of a bug fix from Kirkdg1994-10-221-0/+2
| | | | | | | McKusick to work around problems in FFS related to the blkno of a 64bit offset not fitting into an int. Submitted by: Marshall Kirk McKusick
* Added '-F file' option of mount_mfs. This allows me to make floppy imagesphk1994-10-121-5/+39
| | | | | without waiting for my floppy-drive all the time :-) Might have other interesting uses too.
* Backed out part of the last change that prevents the rpos table fromdg1994-10-091-1/+1
| | | | | | being output if <= 1 rpos; there is a bug in the kernel which doesn't quite get along with this. Changed default #rpos to 1, and fixed up manual page. Converted nrpos to 1 if user specifies 0.
* 1) If nrpos <= 1, don't output rpos table (and set fs_cpc to 0) - disablingdg1994-10-011-1/+1
| | | | | | | | | the use of the rotational position table. 2) Allow specification of 0 rotational positions (disables function). 3) Make rotdelay=0 and nrpos=0 by default. The purpose of the above is to optimize for modern SCSI (and IDE) drives that do read-ahead/write-behind.
* Set fs_clean.dg1994-08-261-0/+1
|
* BSD 4.4 Lite sbin Sourcesrgrimes1994-05-261-0/+1227
Note: XNSrouted and routed NOT imported here, they shall be imported with usr.sbin.
OpenPOWER on IntegriCloud