summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* mkswap: add alignment checkDavidlohr Bueso2011-04-121-0/+2
| | | | | | | | | This patch produces the program to warn if the given device is misaligned. [kzak@redhat.com: - call the check for block devices only] Signed-off-by: Davidlohr Bueso <dave@gnu.org> Signed-off-by: Karel Zak <kzak@redhat.com>
* blkdev: add blkdev_is_misaligned()Davidlohr Bueso2011-04-122-0/+15
| | | | | | | | | | This functions returns the status of the device's alignment. It will be 0 when aligned, otherwise return the offset. [kzak@redhat.com: - returns 0 if the ioctl failed] Signed-off-by: Davidlohr Bueso <dave@gnu.org> Signed-off-by: Karel Zak <kzak@redhat.com>
* hexdump: don't include err.h directlyKarel Zak2011-04-121-1/+2
|
* script: don't include err.h directlyKarel Zak2011-04-121-1/+1
|
* iosize: fix gcc warningKarel Zak2011-04-121-1/+0Star
| | | | | | | isosize.c: In function ‘main’: isosize.c:168:8: warning: unused variable ‘p’ Signed-off-by: Karel Zak <kzak@redhat.com>
* elvtune, isosize: print usage text in case of invalid optionFrancesco Cosoleto2011-04-122-6/+12
| | | | Signed-off-by: Francesco Cosoleto <cosoleto@gmail.com>
* isosize: use program_invocation_short_nameFrancesco Cosoleto2011-04-121-7/+3Star
| | | | Signed-off-by: Francesco Cosoleto <cosoleto@gmail.com>
* isosize: simplify some error messagesFrancesco Cosoleto2011-04-121-18/+9Star
| | | | | | | perror() and fprintf() are replaced with err() calls Signed-off-by: Francesco Cosoleto <cosoleto@gmail.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* elvtune, isosize: remove redundant message in case of invalid optionFrancesco Cosoleto2011-04-122-5/+0Star
| | | | | | | This leaves getopt() only to print a similar error message on invalid options. Signed-off-by: Francesco Cosoleto <cosoleto@gmail.com>
* readprofile: don't stop parsing at __init_endPo-Yu Chuang2011-04-121-2/+4
| | | | | | | | | | Some architectures like ARM place __init_end before .text section. If any function in .init section is hit while profiling, readprofile stops at __init_end. That means if we enable profiling at boot time, the profiler probably hits init functions and readprofile does not work well unless we reset profiling buffer with -r option. Signed-off-by: Po-Yu Chuang <ratbert@faraday-tech.com>
* wall: support --timeout switch (vol 2.)Karel Zak2011-04-122-1/+6
| | | | | | | | | | | | This is the rest of the commit cae7485e59299c4b70ea7e1c7a4206df416701dc the original patch was committed without man page and Makefile changes. Sorry. Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: cleanup mbufsize usageKarel Zak2011-04-121-7/+5Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: support --timeout switchSami Kerola2011-04-121-2/+11
| | | | | | The switch controls message write time out to terminals. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* wall: add long options and 79 char cut info to the man pageSami Kerola2011-04-121-2/+11
| | | | | | | Mention that over 79 characters long lines are cut, while long options is an obvious change. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* ttymsg: fix compiler warnings and use EXIT_Sami Kerola2011-04-122-10/+11
| | | | | | | [kzak@redhat.com: - remove 'register' storage class specifier] Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: use long optionsSami Kerola2011-04-121-7/+30
| | | | | | | Also --version & --help options added, and rewrote help output. Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: remove global variables and support TMPDIRSami Kerola2011-04-121-27/+47
| | | | | | | | | | The TMPDIR environment is preferred over _PATH_TMP in which a file is created that is ultimately sent to terminals. This patch will also fix compiler warnings and removes magical numbers, which has not explanation. Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* mount: add note about blank lines to fstab.5Karel Zak2011-04-121-3/+6
| | | | | Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=694648 Signed-off-by: Karel Zak <kzak@redhat.com>
* umount: support non-canonical devnames in mtabKarel Zak2011-04-112-1/+17
| | | | | Addresses: https://bugs.launchpad.net/ubuntu/+source/util-linux/+bug/755193 Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: update TODOKarel Zak2011-04-081-0/+15
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: use xmalloc()Karel Zak2011-04-061-6/+4Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: fix variable types, and unused argument warningsSami Kerola2011-04-061-3/+4
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* setterm: add note about long dump file paths to man pageSami Kerola2011-04-061-1/+2
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* setterm: function screendump coding style fixedSami Kerola2011-04-061-60/+61
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* setterm: mention in man setterm.1 -version and -help switchesSami Kerola2011-04-061-0/+6
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* setterm: use libc error printing facilitiesSami Kerola2011-04-061-21/+27
| | | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: support -help and -version optionsSami Kerola2011-04-061-61/+65
| | | | | | | [kzak@redhat.com: - merge all options to the one string] Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: segfault with long dump file nameSami Kerola2011-04-061-2/+3
| | | | | | | | | | | | | The patch will make too long path to be truncated to MAX_PATH lenght. If user supplies too long file name that is caught at fopen. Some users might find this unintuitive, so the altered behavior will be mantioned in manual page. Bug in earlier version was visible with a command bellow. setterm -dump -file $(for i in $(seq 254); do printf x ; done) Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* column: use xalloc libSami Kerola2011-04-061-10/+6Star
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rev: mention long options in man pageSami Kerola2011-04-061-0/+7
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rev: option parsing bug fixed & long options addedSami Kerola2011-04-061-5/+19
| | | | | | | | | | | | | The former getopts segment gave impression unknown options will cause the program to exit with error and help is available with -h. Neither work quite as designed, all unknown options made the program to exit with success; and none of the options where known. The fix also has support for long options, and new --version switch. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rev: memory leak fixSami Kerola2011-04-061-2/+2
| | | | | | | | Moving the malloc out of loop will make leak to disappear, and the command might run few jiffie quicker when there are 1+N arguments. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rev: use xrealloc from xalloc.hSami Kerola2011-04-061-9/+1Star
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* partx: trivial comment fixDavidlohr Bueso2011-04-061-1/+1
| | | | | | Replace atgv for argv Signed-off-by: Davidlohr Bueso <dave@gnu.org>
* getopt: add static qualifiersOlivier Mengué2011-04-061-27/+27
| | | | Signed-off-by: Olivier Mengué <dolmen@cpan.org>
* build-sys: remove check-newsKarel Zak2011-04-051-1/+1
| | | | | | | | I need to call "make distcheck" often during development phase to check that all files are correctly added to Makefiles. The "check-new" automake option is useless if $(VERSION) is generated from git. Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: use git-version-gen to distinct git and release versionsSami Kerola2011-04-055-1/+190
| | | | | | | | | | | The script is copied as is from gnulib. [kzak@redhat.com: - generate .tarball-version and .version files in top level Makefile.am - delete autom4te.cache in autogen.sh] Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: fix parsing of mountinfo from 2.6.39Karel Zak2011-04-051-8/+21
| | | | | | | | | | The /proc/self/mountinfo file uses " - " field as a separator between optional fields and next fields in the file. The '-' char could be used in the fields (for example in UUIDs), so it's necessary to check for whole " - " string rather than for '-' char only. Reported-by: "Aneesh Kumar K. V" <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: fix distcheck for term-utilsKarel Zak2011-04-041-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: add mountpoint(1) implementation to samples/Karel Zak2011-04-013-1/+176
|
* umount: use helper= for all UIDsKarel Zak2011-04-016-19/+20
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: support /run/mount rather than /dev/.mountKarel Zak2011-03-317-16/+28
| | | | | | | | | The /run directory should be preferred on distributions where this directory exists. http://thread.gmane.org/gmane.linux.redhat.fedora.devel/146976 Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add dump from PPC64 to lscpu testsKarel Zak2011-03-312-0/+31
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: detect sun4{u,v} in /proc/cpuinfo for sparc64Karel Zak2011-03-312-1/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add dump from UltraSparc T1 to lscpu testsKarel Zak2011-03-312-0/+37
| | | | | | Thanks to Jan Engelhardt. Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add dump from huge ia64 to lscpu testsKarel Zak2011-03-312-0/+654
| | | | | | Thanks to Jan Engelhardt. Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: fix op-mode for /{sys,proc} dumpsKarel Zak2011-03-312-1/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: fix threads-per-core calculationKarel Zak2011-03-311-6/+14
| | | | | | | | | | | | | | | | | | | | | | | On Thu, Mar 24, 2011 at 01:45:34PM +0100, Jan Engelhardt wrote: > On a 24-thread/6-core SPARC T1, lscpu would wrongly output "5 > threads per core". > > It seems that the 6c T1 is simply an 8c T1 where 2c are disabled > (offering a lesser model for a lower price, and all that marketing > fluff). So the machine description header of the 6c T1 reports 32 > threads, but only goes on to provide 24 elements thereafter, which > is why Linux will report threads 24-31 as "offline". So far so good. > > But lscpu would take the number of all (online and offline) threads > (32) and divides it by the number of online cores (6), which yields > an odd 5.33 threads/core. > > Simply pick the number of online threads. Based on Jan's patch. Reported-by: Jan Engelhardt <jengelh@medozas.de> Signed-off-by: Karel Zak <kzak@redhat.com>
* login: fix checktty test to compile with old glibcKarel Zak2011-03-311-0/+1
| | | | | Reported-by: "Gabor Z. Papp" <gzp@papp.hu> Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: plug memory leak in sample programPetr Uzel2011-03-311-0/+1
| | | | | Signed-off-by: Petr Uzel <petr.uzel@suse.cz> Signed-off-by: Karel Zak <kzak@redhat.com>