| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
| |
The function is no longer in use.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
|
|
|
|
| |
[kzak@redhat.com: - fix msgctl() call,
move q_qbytes to ipc_msg_get_info]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
|
|
|
|
|
| |
And reindent the print_shm() function.
[kzak@redhat.com: move semctl(GET*...) calls to ipcutils.c]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
|
|
|
| |
And reindent the print_shm() function.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
| |
- don't expect maxid as argument in ipc_shm_get_info()
- if there is @id argument then use it everywhere in ipc_shm_get_info()
- don't call shmctl() if not necessary in do_shm()
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
| |
[kzak@redhat.com: - move to ipcutils.{c,h},
- fix datatypes to be arch independent]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some of the limit values are not dynamic. Like in kernel these values
are #defined.
[kzak@redhat.com: - use better names for functions,
- add ipcutils.{c,h}
- read also shmmax from /proc]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
| |
... and to have names compatible with lib/sysfs.c
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Without this table libmount will not resolve paths, meaning that
umounting by relative path will fail.
[kzak@redhat.com: - use mnt_context_get_cache() to make it sensitive
to --no-canonicalize cmdline option]
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
| |
In the umount --recursive we follow entries from mountinfo, but the
entries maybe already obsolete. Especially if the hierarchy of the
mountpoints contains shared subtrees and umount(2) for one entry may
generate umount for some other entry too.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
| |
- mark some options combinations mutually exclusive
- reset libmount context before next umount (this is important!)
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
| |
This allows unmounting of an entire tree of filesystems, which might be
of particular interest for a shutdown initramfs.
[kzak@redhat.com: - always return MOUNT_EX_* codes
- cosmetic changes on coding style]
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
read_basicinfo() relies on sysfs cpu directories
"/sys/devices/system/cpu/cpu%d" with assumption that cpu
logical number %d is always sequentially assigned for all
CPUs. However, this assumption is not correct with CPU
hot-remove operation since it removes a target sysfs cpu
directory after it is ejected. As a result, lscpu may not
recognize all CPUs.
The issue can be easily reproduced on KVM or VirtualBox,
which supports CPU eject operation, as follows.
1) The system has 4 CPUs
$ lscpu -a -e
CPU NODE SOCKET CORE L1d:L1i:L2 ONLINE
0 0 0 0 0:0:0 yes
1 0 1 1 1:1:1 yes
2 0 2 2 2:2:2 yes
3 0 3 3 3:3:3 yes
2) Eject cpu2
# echo 1 > /sys/bus/acpi/devices/LNXCPU:02/eject
3) lscpu no longer recognizes cpu3 after cpu2 is ejected
$ lscpu -a -e
CPU NODE SOCKET CORE L1d:L1i:L2 ONLINE
0 0 0 0 0:0:0 yes
1 0 1 1 1:1:1 yes
The following changes are made to address this issue.
- Use maxcpus to allocate and parse bitmaps.
- Set desc->ncpu from cpu/present, which includes both on-line
and off-line CPUs.
- Add is_cpu_present() to check if a CPU is present. Ejected
CPUs are not present.
[kzak@redhat.com: - read also /sys/devices/system/cpu/possible mask to
determine maximal number of CPUs,
- err() if possible mask is not found in /sys]
Signed-off-by: Toshi Kani <toshi.kani@hp.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The --list --all is the default output:
# losetup
NAME SIZE OFFSET AUTOCLEAR RO BACK-FILE
/dev/loop0 0 0 0 0 /home/fs-images/swap.img
/dev/loop1 0 100 0 0 /home/fs-images/disk.img
[kzak@redhat.com: - default to --all if no device specified,
- cleanup column names (add BACK- prefix)
- add MAJ:MIN to of the loopdev device]
Signed-off-by: Ondrej Oprala <ooprala@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
| |
# mount --fstab /path/my.fstab
has to support standard operations with paths.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
| |
To make it available everywhere in code.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
| |
Both index() and rindex() are legacy functions which may be withdrawn in
a future.
Reference: http://pubs.opengroup.org/onlinepubs/009695399/functions/index.html
Reference: http://pubs.opengroup.org/onlinepubs/009695399/functions/rindex.html
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
| |
[kzak@redhat.com: - update man page
- colorize critical messages too]
Signed-off-by: Karel Zak <kzak@redhat.com>
Signed-off-by: Ondrej Oprala <ooprala@redhat.com>
|
|
|
|
|
|
|
| |
The -L and -U flags both have long options too (--label and --uuid).
The usage() function will show them but the man page didn't list them.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
|
|
|
|
|
|
|
|
| |
The --no-canonicalize option can also be set using -c. The --help for
mount shows this option but the man page did not. Add -c to the man
page.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
|
|
|
|
|
|
|
| |
The compare option for hwclock was not listed in the man page. This
adds a simple decription of it.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
|
|
|
|
|
|
|
| |
sys-utils/swapon.c:677:2: error: 'for' loop initial declarations are
only allowed in C99 mode
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
|
|
|
| |
Value -1 is valid argument for -p, even though it might not make much
sense as the -1 is in use when priority is not specified at all.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
|
| |
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
| |
* Add spaces after dots (English spacing).
* Remove use of inline emphasis where possible.
* Use mail and url macros.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
|
|
|
|
| |
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
|
|
|
| |
Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=864227
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
commit f06ec64f dmesg; support level names (e.g. --console-level=alert)
introduced an off-by-one error. The kernel will print messages with
a *higher* level than the console-level. The bug made it impossible to
set the level for debugging, like it is documented in e.g
Documentation/networking/netconsole.txt :
nemi:/tmp# dmesg -n 8
dmesg: unknown level '8'
And attempting to set the "emerg" level would result in an invalid 0 value:
nemi:/tmp# dmesg -n emerg
dmesg: klogctl failed: Invalid argument
Restoring the old behaviour for numeric levels, and mapping the level
names so that "dmesg -n debug" behaves as expected: logging everything
at level "debug" and higher.
[kzak@redhat.com: - add comment to parse_level()]
Signed-off-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
| |
Nothing of note here.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
|
|
|
|
|
|
|
|
| |
GCC 4.1.2 on SLES 10.4:
sys-utils/ipcrm.c: In function ‘main’:
sys-utils/ipcrm.c:297: warning: ‘what_all’ may be used uninitialized in this function
* sys-utils/ipcrm.c: Initialize what_all to ALL.
Signed-off-by: Bernhard Voelker <mail@bernhard-voelker.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
blkdiscard is used to discard device sectors. This is useful for
solid-state drivers (SSDs) and thinly-provisioned storage. Unlike
fstrim this command is used directly on the block device.
blkkdiscard uses BLKDISCARD ioctl or BLKSECDISCARD ioctl for the secure
discard.
All data in the discarded region on the device will be lost!
Signed-off-by: Lukas Czerner <lczerner@redhat.com>
|
|
|
|
|
|
|
| |
This was only attempt as alternative implementation, unfortunately
pushed publicly... sorry.
This reverts commit c84ed54cefdcaa07f3d1f40a65434c9d4277da08.
|
|
|
|
|
|
|
|
|
|
|
| |
Add to fstrim(8) code to support new discard BLKDISCARD and
BLKSECDISCARD ioctls for block devices. The new command is only
symlink to fstrim(8) as the both utils share some code and the basic
ideas.
Based on patch from Lukas Czerner <lczerner@redhat.com>.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A sideeffect of 839be2ba6b44fa9dc927f081d547ebadec9de19c is that we now
warp the systemtime according to the timezone, on the first call of
--systz. This is not always the correct thing to do, and causes a
regression for us in Arch Linux.
The behavior is correct if the RTC, and hence the systemtime, is
in localtime. However, if the systemtime is already in UTC we don't
want to touch it when we set the kernel timezone (which we still need to
do as some filesystems use this information).
An almost identical issue was also fixed in systemd commit
72edcff5db936e54cfc322d9392ec46e2428fd9b.
Signed-off-by: Tom Gundersen <teg@jklm.no>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On Sun, Sep 16, 2012 at 02:11:48PM +0800, Queen Adam wrote:
> I'm using Archlinux ARM for my Melo A100 box.
> The hwclock always timeout when using select() in rtc.c.
>
> After I change the timeout from 5 to 10, the problem is solved.
>
> In fact the timeout in my ARM box seems only to be a little larger
> than 5s.
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
|
|
| |
Signed-off-by: Ville Skyttä <ville.skytta@iki.fi>
|
|
|
|
|
|
|
|
| |
Disable an alarm use the same logic used to enable it: first try RTC_WKALM_SET
with the "enabled" flag set to false, if it fails fall back to RTC_AIE_OFF.
Signed-off-by: Giacomo <giacomo.perale@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
|