| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* 'cramfs' of https://github.com/kerolasa/lelux-utiliteetit:
include: move fsck return values to exitcodes.h
include: move disk-utils/mkfs.h -> include/exitcodes.h
mkfs.cramfs: coding style
mkfs.cramfs: include-what-you-use header check
mkfs.cramfs: error printing fixes
mkfs.cramfs: convert spaces to tabs
mkfs.cramfs: validate numeric user inputs
mkfs.cramfs: few symbolic exit codes where missing
md5: use symbolical digest length
mkfs.cramfs: use program_invocation_short_name
mkfs.cramfs: use xalloc.h
fsck.cramfs: add missed strings to translation
fsck.cramfs: coding style
fsck.cramfs: use xalloc.h
fsck.cramfs: retire die function
cramfs.h: coding style
cramfs: use stdint.h instead of u{8,16,32}
cramfs_common: coding style
Conflicts:
disk-utils/Makefile.am
Signed-off-by: Karel Zak <kzak@redhat.com>
|
| |
| |
| |
| | |
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
| |
| |
| |
| | |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
| |
| |
| |
| |
| |
| | |
... and remove some tailing whitespaces.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
| |
| |
| |
| | |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Global variables and inline functions are moved from minix.h to
minix_programs.h which is included in mkfs.minix and fsck.minix.
The minix.h will have only struct definitions etc generic
contents which is reasonable to share with utilities and
libraries.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|/
|
|
|
|
|
|
|
|
| |
In the minix.h two definitions where renamed, so that the single
definition is reusable in fsck.minix, mkfs.minix and libblkid.
BLOCK_SIZE_BITS -> MINIX_BLOCK_SIZE_BITS
BLOCK_SIZE -> MINIX_BLOCK_SIZE
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
|
|
|
|
| |
For v3 minix superblocks the state flag (s_state) has been removed, so drop it
from the structure in accordance with the kernel's representation.
Reported-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We can now create minix v3 filesystems. Support for this fs was added a few
years ago in the Linux kernel. One of the most important benefits is the
ability to handle file names up to 60 characters long. With this change we
also introduce the -3 option which naturally indicates which version to create.
Version 1 is still left as the default one for backwards compatibility reasons.
[kzak@redhat.com: - fix gcc warnings:
mkfs.minix.c: In function ‘super_set_state_ptr’:
mkfs.minix.c:174:1: warning: no return statement in function returning non-void [-Wreturn-type]
mkfs.minix.c: In function ‘write_tables’:
mkfs.minix.c:182:7: warning: unused variable ‘state’ [-Wunused-variable]
mkfs.minix.c: At top level:
mkfs.minix.c:111:27: warning: ‘blksz’ defined but not used [-Wunused-variable]
]
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
| |
Produce a warning if the device is misaligned.
[kzak@redhat.com: - use it for block devices only]
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
| |
Like the original minix mkfs, add the -1 and -2 argument options to specify the
version of the filesystem to create.
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
|
|
|
|
|
|
|
|
| |
Because of the dependence of fs_version, some superblock attributes will vary,
so simplify the logic of assigning values to maxsize and the amount of zones
related to each filesystem, thus making setup_tables() more readable.
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
|
|
|
|
|
|
|
| |
Use a common function for creating the root and bad inode, without worring
about the fs version.
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
|
|
|
|
| |
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
|
|
|
|
|
|
|
|
|
|
|
| |
Get rid of this function and use errx(3) instead. This patch also
introduces a mkfs.h header and defines general purpose mkfs related
exit codes.
[kzak@redhat.com: - fix "warning: too many arguments for format" errors]
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
| |
This patch provides some minor code fixes: add/remove some macros and close the device after usage.
Also modifies usage() and changes main()'s indentation to 8-characters.
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
|
|
|
|
| |
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This bug has been introduced by commit
95356e8b744439336925eeb36f01399f1ee8a5e9.
The fsck.minix code assumes that isset() macro returns boolean,
unfortunately the generic implementation from libc returns integer.
This patch also add a fallback for the bitmap macros to include/bitops.h.
Reported-by: "Andries E. Brouwer" <Andries.Brouwer@cwi.nl>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
| |
Those became unused with the switch to the blkdev functions.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
|
|
|
|
|
|
| |
We needn't to duplicate stuff from <sys/param.h>.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
| |
This patch renames bitops.h to minix_bitops.h to avoid possible
collisions with global include/bitops.h file.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
| |
blkdev_get_size returns size in bytes, so BLOCKS has to be
calculated accordingly.
Use stat value for size if device is not a block device.
Signed-off-by: Matthias Koenig <mkoenig@suse.de>
|
|
|
|
|
|
|
|
|
| |
no longer use deprecated alias.
helps compiling util-linux-ng against klibc.
add pathnames.h include, where _PATH_MOUNTED is defined.
Signed-off-by: maximilian attems <max@stro.at>
|
|
|
|
|
|
| |
mkfs.minix.c:199: warning: ‘count_blocks’ defined but not used
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
| |
Use blkdev_get_size() function and some size related cleanup.
Signed-off-by: Matthias Koenig <mkoenig@suse.de>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Minix filesystem until version 2 has a fixed blocksize of 1024 bytes.
If you try to create a filsystem on a device with a physical sectorsize
larger than 1024 bytes, this resulting minix fs cannot be mounted,
because the physical sectorsize must be smaller than the filesystem
blocksize.
This patch adds a check for this and will refuse to create a filesystem
if the sectorsize is bigger than the blocksize.
Signed-off-by: Matthias Koenig <mkoenig@suse.de>
|
|
|
|
|
|
|
|
|
|
|
|
| |
* clean up code, gcc warnings
(try compilation with "-Wall -Wp,-D_FORTIFY_SOURCE=2")
Builds cleanly on x86_32 and x86_64.
mkfs.minix.c:595: warning: ignoring return value of 'fscanf', declared with attribute warn_unused_result
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Let mkswap, mkfs.bfs, mkfs.minix open with O_EXCL if
used on block devices to prevent writing to the device
even if they are busy (mounted).
Unfortunately, O_EXCL has zero effect for 2.4 kernels where
in-kernel code doesn't use O_EXCL-like access locks. (Tested
on RHEL3.)
Signed-off-by: Matthias Koenig <mkoenig@suse.de>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|