]> git.ipfire.org Git - thirdparty/util-linux.git/log
thirdparty/util-linux.git
17 months agomeson: Only build libmount python module if python was found
Fabian Vogt [Wed, 7 Feb 2024 10:48:33 +0000 (11:48 +0100)] 
meson: Only build libmount python module if python was found

The extension_module call was in the wrong place.

17 months agoMerge branch 'lsfd--error' of https://github.com/masatake/util-linux
Karel Zak [Mon, 5 Feb 2024 11:07:49 +0000 (12:07 +0100)] 
Merge branch 'lsfd--error' of https://github.com/masatake/util-linux

* 'lsfd--error' of https://github.com/masatake/util-linux:
  tests: (lsfd) add a case testing ERROR type appeared in TYPE column
  tests: (test_mkfds::mmap) new factory
  lsfd: add --_drop-prvilege option for testing purpose
  lsfd: add ERROR as a new type
  lsfd: (refactor) make the steps for new_file consistent
  lsfd: (refactor) add abst_class as super class of file_class
  lsfd: (refactor) simplify the step to make a file struct
  lsfd: (refactor) simplify the step to copy a file struct if the result of its stat is reusable
  lsfd: (refactor) flatten bit fields in struct file
  lsfd: fix typos of a function name

17 months agoMerge branch 'meson/lastlog2' of https://github.com/t-8ch/util-linux v2.41-start
Karel Zak [Mon, 5 Feb 2024 10:55:39 +0000 (11:55 +0100)] 
Merge branch 'meson/lastlog2' of https://github.com/t-8ch/util-linux

* 'meson/lastlog2' of https://github.com/t-8ch/util-linux:
  meson: only build liblastlog when enabled
  meson: create dedicated config for pam_lastlog2
  meson: use a dependency object for sqlite3
  meson: use a dependency object for liblastlog2

17 months agoMerge branch 'lsclocks' of https://github.com/alanc/util-linux
Karel Zak [Mon, 5 Feb 2024 10:53:55 +0000 (11:53 +0100)] 
Merge branch 'lsclocks' of https://github.com/alanc/util-linux

* 'lsclocks' of https://github.com/alanc/util-linux:
  lsclocks: use clock id from clock_getcpuclockid in add_cpu_clock

17 months agoMerge branch 'strtod' of https://github.com/alanc/util-linux
Karel Zak [Mon, 5 Feb 2024 10:42:53 +0000 (11:42 +0100)] 
Merge branch 'strtod' of https://github.com/alanc/util-linux

* 'strtod' of https://github.com/alanc/util-linux:
  lib/c_strtod: fix uselocale() fallback if strtod_l() is not available

17 months agofdisk: (man) fix typo, improve readability
Karel Zak [Mon, 5 Feb 2024 10:21:41 +0000 (11:21 +0100)] 
fdisk: (man) fix typo, improve readability

Reported-by: Michael Partridge <mcp292@nau.edu>
Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agoMerge branch 'enosys/optim' of https://github.com/t-8ch/util-linux
Karel Zak [Mon, 5 Feb 2024 09:54:17 +0000 (10:54 +0100)] 
Merge branch 'enosys/optim' of https://github.com/t-8ch/util-linux

* 'enosys/optim' of https://github.com/t-8ch/util-linux:
  enosys: optimize bytecode when execve is not blocked
  enosys: optimize bytecode when no ioctls are blocked
  enosys: add helpers for 64 bit integer loading
  enosys: drop unnessecary load of ioctl number

17 months agoMerge branch 'master' of https://github.com/echoechoin/util-linux
Karel Zak [Mon, 5 Feb 2024 09:38:40 +0000 (10:38 +0100)] 
Merge branch 'master' of https://github.com/echoechoin/util-linux

* 'master' of https://github.com/echoechoin/util-linux:
  sys-utils/lscpu: Unblock SIGSEGV before vmware_bdoor

17 months agodocs: add setpgid do ReleaseNotes
Karel Zak [Mon, 5 Feb 2024 09:20:39 +0000 (10:20 +0100)] 
docs: add setpgid do ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agoliblastlog2: fix pkg-config inclidedir
Karel Zak [Mon, 5 Feb 2024 08:15:55 +0000 (09:15 +0100)] 
liblastlog2: fix pkg-config inclidedir

The path for .pc must be the same as liblastlog2/src/Makemodule.am:$lastlog2incdir
(and it's usually /usr/include/liblastlog2/).

Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agolsclocks: use clock id from clock_getcpuclockid in add_cpu_clock
Alan Coopersmith [Sun, 4 Feb 2024 17:14:23 +0000 (09:14 -0800)] 
lsclocks: use clock id from clock_getcpuclockid in add_cpu_clock

Fixes #2761

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
17 months agoenosys: optimize bytecode when execve is not blocked
Thomas Weißschuh [Sun, 4 Feb 2024 09:06:39 +0000 (10:06 +0100)] 
enosys: optimize bytecode when execve is not blocked

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agoenosys: optimize bytecode when no ioctls are blocked
Thomas Weißschuh [Sat, 3 Feb 2024 17:55:13 +0000 (18:55 +0100)] 
enosys: optimize bytecode when no ioctls are blocked

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agoenosys: add helpers for 64 bit integer loading
Thomas Weißschuh [Sun, 4 Feb 2024 09:21:05 +0000 (10:21 +0100)] 
enosys: add helpers for 64 bit integer loading

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agoenosys: drop unnessecary load of ioctl number
Thomas Weißschuh [Sun, 4 Feb 2024 09:24:26 +0000 (10:24 +0100)] 
enosys: drop unnessecary load of ioctl number

The ioctl number is properly loaded just below the deleted instruction
anyways.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agolib/c_strtod: fix uselocale() fallback if strtod_l() is not available
Alan Coopersmith [Sat, 3 Feb 2024 02:09:18 +0000 (18:09 -0800)] 
lib/c_strtod: fix uselocale() fallback if strtod_l() is not available

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
17 months agotests: (lsfd) add a case testing ERROR type appeared in TYPE column
Masatake YAMATO [Tue, 23 Jan 2024 23:57:06 +0000 (08:57 +0900)] 
tests: (lsfd) add a case testing ERROR type appeared in TYPE column

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agotests: (test_mkfds::mmap) new factory
Masatake YAMATO [Mon, 29 Jan 2024 16:02:07 +0000 (01:02 +0900)] 
tests: (test_mkfds::mmap) new factory

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: add --_drop-prvilege option for testing purpose
Masatake YAMATO [Tue, 23 Jan 2024 20:20:49 +0000 (05:20 +0900)] 
lsfd: add --_drop-prvilege option for testing purpose

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: add ERROR as a new type
Masatake YAMATO [Mon, 15 Jan 2024 19:18:38 +0000 (04:18 +0900)] 
lsfd: add ERROR as a new type

lsfd ignored file descriptors with that readlink(2) or
stat(2) returned errors.

With ERORR type, lsfd can print these file descriptors with incomplete
information.

An example output:

   COMMAND        PID   USER ASSOC  XMODE  TYPE          SOURCE MNTID INODE NAME
   systemd      10677 yamato    31 ????-- ERROR readlink:EACCES
   slirp4netns 901147 yamato     7 ????-- ERROR     stat:EACCES             /home/yamato/.local/share/.../merged

The format of SOURCE column is SYSCALL:ERRNO.

The code for printing errno name is highly based on the code for
printing syscall name in enosys.c.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: (refactor) make the steps for new_file consistent
Masatake YAMATO [Mon, 15 Jan 2024 17:50:23 +0000 (02:50 +0900)] 
lsfd: (refactor) make the steps for new_file consistent

In parse_maps_line of the original code, we called readlink after stat
for gathering arguments that were passed to new_file().

The order was different from that in collect_file_symlink.
In parse_maps_line, we called stat after readlink.

The difference of the order may make the way of handling
errors of readlink and stat complicated.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: (refactor) add abst_class as super class of file_class
Masatake YAMATO [Sun, 14 Jan 2024 22:18:58 +0000 (07:18 +0900)] 
lsfd: (refactor) add abst_class as super class of file_class

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: (refactor) simplify the step to make a file struct
Masatake YAMATO [Sun, 14 Jan 2024 21:40:37 +0000 (06:40 +0900)] 
lsfd: (refactor) simplify the step to make a file struct

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: (refactor) simplify the step to copy a file struct if the result of its stat...
Masatake YAMATO [Sun, 14 Jan 2024 21:26:07 +0000 (06:26 +0900)] 
lsfd: (refactor) simplify the step to copy a file struct if the result of its stat is reusable

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: (refactor) flatten bit fields in struct file
Masatake YAMATO [Sun, 14 Jan 2024 00:37:37 +0000 (09:37 +0900)] 
lsfd: (refactor) flatten bit fields in struct file

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agolsfd: fix typos of a function name
Masatake YAMATO [Sun, 14 Jan 2024 21:19:50 +0000 (06:19 +0900)] 
lsfd: fix typos of a function name

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
17 months agomeson: only build liblastlog when enabled
Thomas Weißschuh [Fri, 2 Feb 2024 13:40:06 +0000 (14:40 +0100)] 
meson: only build liblastlog when enabled

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agomeson: create dedicated config for pam_lastlog2
Thomas Weißschuh [Fri, 2 Feb 2024 12:48:28 +0000 (13:48 +0100)] 
meson: create dedicated config for pam_lastlog2

17 months agomeson: use a dependency object for sqlite3
Thomas Weißschuh [Fri, 2 Feb 2024 12:44:50 +0000 (13:44 +0100)] 
meson: use a dependency object for sqlite3

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agomeson: use a dependency object for liblastlog2
Thomas Weißschuh [Fri, 2 Feb 2024 12:41:37 +0000 (13:41 +0100)] 
meson: use a dependency object for liblastlog2

It is easier to use.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agodocs: add BSD-2-Clause
Karel Zak [Fri, 2 Feb 2024 10:58:46 +0000 (11:58 +0100)] 
docs: add BSD-2-Clause

Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agoMerge branch 'meson/so_passcred' of https://github.com/t-8ch/util-linux
Karel Zak [Fri, 2 Feb 2024 09:35:08 +0000 (10:35 +0100)] 
Merge branch 'meson/so_passcred' of https://github.com/t-8ch/util-linux

* 'meson/so_passcred' of https://github.com/t-8ch/util-linux:
  meson: define _GNU_SOURCE when checking for SO_PASSCRED

17 months agosys-utils/lscpu: Unblock SIGSEGV before vmware_bdoor
WanBingjiang [Fri, 2 Feb 2024 02:43:08 +0000 (10:43 +0800)] 
sys-utils/lscpu: Unblock SIGSEGV before vmware_bdoor

17 months agomeson: define _GNU_SOURCE when checking for SO_PASSCRED
Thomas Weißschuh [Thu, 1 Feb 2024 19:48:49 +0000 (20:48 +0100)] 
meson: define _GNU_SOURCE when checking for SO_PASSCRED

SO_PASSCRED is not exposed in standards mode that was enabled in
commit 6240e4458cdf ("build: use -std=c99 and -std=c++11 by default").

Fixes: #2750
Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agolib/cpuset: exit early from cpulist_parse
Thomas Weißschuh [Thu, 1 Feb 2024 19:09:41 +0000 (20:09 +0100)] 
lib/cpuset: exit early from cpulist_parse

If `a` exceeds `max`, any increment of `a` will also `exceed` max.
In this case the CPU_SET_S will never do anything all additional loops
are wasted.

Fixes #2748

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agolib/cpuset: make max variable const
Thomas Weißschuh [Thu, 1 Feb 2024 19:09:17 +0000 (20:09 +0100)] 
lib/cpuset: make max variable const

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agoMerge branch 'patch-1' of https://github.com/ZmoleCristian/util-linux
Karel Zak [Thu, 1 Feb 2024 14:49:49 +0000 (15:49 +0100)] 
Merge branch 'patch-1' of https://github.com/ZmoleCristian/util-linux

* 'patch-1' of https://github.com/ZmoleCristian/util-linux:
  Added Cristian Zmole

17 months agoMerge branch 'setpriv/without-landlock' of https://github.com/t-8ch/util-linux
Karel Zak [Thu, 1 Feb 2024 14:49:26 +0000 (15:49 +0100)] 
Merge branch 'setpriv/without-landlock' of https://github.com/t-8ch/util-linux

* 'setpriv/without-landlock' of https://github.com/t-8ch/util-linux:
  setpriv: apply landlock without configuration

17 months agoMerge branch 'ci/gcc-13' of https://github.com/t-8ch/util-linux
Karel Zak [Thu, 1 Feb 2024 14:49:12 +0000 (15:49 +0100)] 
Merge branch 'ci/gcc-13' of https://github.com/t-8ch/util-linux

* 'ci/gcc-13' of https://github.com/t-8ch/util-linux:
  ci: consistently use gcc 13 during CI

17 months agoMerge branch 'PR/build-sys-lastlog2' of github.com:karelzak/util-linux-work
Karel Zak [Thu, 1 Feb 2024 14:48:56 +0000 (15:48 +0100)] 
Merge branch 'PR/build-sys-lastlog2' of github.com:karelzak/util-linux-work

* 'PR/build-sys-lastlog2' of github.com:karelzak/util-linux-work:
  autotools: cleanup lastlog2 stuff

17 months agosu: (man) improve formatting
Karel Zak [Thu, 1 Feb 2024 10:55:36 +0000 (11:55 +0100)] 
su: (man) improve formatting

Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agosu: (man) add hint about sessions
Karel Zak [Thu, 1 Feb 2024 10:53:37 +0000 (11:53 +0100)] 
su: (man) add hint about sessions

Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agoAdded Cristian Zmole
Zmole Cristian [Wed, 31 Jan 2024 23:02:20 +0000 (01:02 +0200)] 
Added Cristian Zmole

Added myself to contributors since PR #2451 was approved

Signed-off-by: Cristian Zmole chiarel@tragdate.ninja
17 months agosetpriv: apply landlock without configuration
Thomas Weißschuh [Wed, 31 Jan 2024 17:01:08 +0000 (18:01 +0100)] 
setpriv: apply landlock without configuration

Fixes #2746

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agoci: consistently use gcc 13 during CI
Thomas Weißschuh [Wed, 31 Jan 2024 14:29:48 +0000 (15:29 +0100)] 
ci: consistently use gcc 13 during CI

Some configurations where not migrated from 10 to 13.

The coveralls configuration stays on gcc 10 as the coverage data
generated by the compiler needs to be compatible with the installed
version of gcov.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
17 months agodocs: add exch to ReleaseNotes
Karel Zak [Wed, 31 Jan 2024 13:05:17 +0000 (14:05 +0100)] 
docs: add exch to ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
17 months agodocs: add enosys to ReleaseNotes
Karel Zak [Wed, 31 Jan 2024 12:50:17 +0000 (13:50 +0100)] 
docs: add enosys to ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agoautotools: cleanup lastlog2 stuff
Karel Zak [Mon, 29 Jan 2024 20:04:23 +0000 (21:04 +0100)] 
autotools: cleanup lastlog2 stuff

* use pkg-config (PKG_CHECK_MODULES) rather than check for sqlite3.h
  only
* define $SQLITE3_LIBS

* use UL_ macros in configure.ac for liblastlog2 and pam_lastlog2

* add --disable-pam-lastlog2

* check for PAM to define BUILD_PAM_LASTLOG2

* install lastlog2.h to $(includedir)/liblastlog2/lastlog2.h

* fix liblastlog2_la_LDFLAG

* add Requires.private to lastlog2.pc.in

* use $(SQLITE3_LIBS) rather than hardcoded -lsqlite3

Fixes: https://github.com/util-linux/util-linux/issues/2734
Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agoMerge branch 'lsfd--man-decoration' of https://github.com/masatake/util-linux
Karel Zak [Mon, 29 Jan 2024 13:01:52 +0000 (14:01 +0100)] 
Merge branch 'lsfd--man-decoration' of https://github.com/masatake/util-linux

* 'lsfd--man-decoration' of https://github.com/masatake/util-linux:
  lsdf: (man page) revise text decoration

18 months agoMerge branch 'lsfd--limit-listing-kthreads' of https://github.com/masatake/util-linux
Karel Zak [Mon, 29 Jan 2024 13:01:34 +0000 (14:01 +0100)] 
Merge branch 'lsfd--limit-listing-kthreads' of https://github.com/masatake/util-linux

* 'lsfd--limit-listing-kthreads' of https://github.com/masatake/util-linux:
  lsfd: don't list kernel threads unless --threads is given
  lsfd: (refactor) rename a function, s/new_process/new_proc/g

18 months agoMerge branch 'release-notes--fix-typo' of https://github.com/masatake/util-linux
Karel Zak [Mon, 29 Jan 2024 13:01:15 +0000 (14:01 +0100)] 
Merge branch 'release-notes--fix-typo' of https://github.com/masatake/util-linux

* 'release-notes--fix-typo' of https://github.com/masatake/util-linux:
  docs: fix a typo

18 months agolsdf: (man page) revise text decoration
Masatake YAMATO [Sun, 28 Jan 2024 17:34:21 +0000 (02:34 +0900)] 
lsdf: (man page) revise text decoration

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
18 months agolsfd: don't list kernel threads unless --threads is given
Masatake YAMATO [Wed, 24 Jan 2024 00:05:47 +0000 (09:05 +0900)] 
lsfd: don't list kernel threads unless --threads is given

18 months agolsfd: (refactor) rename a function, s/new_process/new_proc/g
Masatake YAMATO [Tue, 23 Jan 2024 23:58:45 +0000 (08:58 +0900)] 
lsfd: (refactor) rename a function, s/new_process/new_proc/g

Rename the function for making the name consistent with free_proc().

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
18 months agoMerge branch 'liblastlog_so_2' of https://github.com/schubi2/util-linux
Karel Zak [Thu, 25 Jan 2024 09:00:00 +0000 (10:00 +0100)] 
Merge branch 'liblastlog_so_2' of https://github.com/schubi2/util-linux

* 'liblastlog_so_2' of https://github.com/schubi2/util-linux:
  set LIBLASTLOG2_2_40
  set soname of liblastlog2 to 2.0

18 months agoset LIBLASTLOG2_2_40
Stefan Schubert [Thu, 25 Jan 2024 08:12:39 +0000 (09:12 +0100)] 
set LIBLASTLOG2_2_40

18 months agodocs: fix a typo
Masatake YAMATO [Wed, 24 Jan 2024 19:35:50 +0000 (04:35 +0900)] 
docs: fix a typo

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
18 months agoset soname of liblastlog2 to 2.0
Stefan Schubert [Wed, 24 Jan 2024 12:40:37 +0000 (13:40 +0100)] 
set soname of liblastlog2 to 2.0

18 months agobuild-sys: release++ (v2.40-rc1) v2.40-rc1
Karel Zak [Wed, 24 Jan 2024 11:10:42 +0000 (12:10 +0100)] 
build-sys: release++ (v2.40-rc1)

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agodocs: update v2.40-ReleaseNotes
Karel Zak [Wed, 24 Jan 2024 11:08:10 +0000 (12:08 +0100)] 
docs: update v2.40-ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agodocs: update AUTHORS file
Karel Zak [Wed, 24 Jan 2024 10:06:09 +0000 (11:06 +0100)] 
docs: update AUTHORS file

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agopo-man: merge changes
Karel Zak [Wed, 24 Jan 2024 09:56:43 +0000 (10:56 +0100)] 
po-man: merge changes

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agopo: merge changes
Karel Zak [Wed, 24 Jan 2024 09:56:37 +0000 (10:56 +0100)] 
po: merge changes

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agopo-man: add ro.po (from translationproject.org)
Remus-Gabriel Chelu [Wed, 24 Jan 2024 09:54:24 +0000 (10:54 +0100)] 
po-man: add ro.po (from translationproject.org)

18 months agopo-man: add ko.po (from translationproject.org)
Seong-ho Cho [Wed, 24 Jan 2024 09:54:24 +0000 (10:54 +0100)] 
po-man: add ko.po (from translationproject.org)

18 months agopo-man: update uk.po (from translationproject.org)
Yuri Chornoivan [Wed, 24 Jan 2024 09:54:24 +0000 (10:54 +0100)] 
po-man: update uk.po (from translationproject.org)

18 months agopo-man: update sr.po (from translationproject.org)
Мирослав Николић [Wed, 24 Jan 2024 09:54:24 +0000 (10:54 +0100)] 
po-man: update sr.po (from translationproject.org)

18 months agopo-man: update fr.po (from translationproject.org)
Frédéric Marchal [Wed, 24 Jan 2024 09:54:24 +0000 (10:54 +0100)] 
po-man: update fr.po (from translationproject.org)

18 months agopo-man: update de.po (from translationproject.org)
Mario Blättermann [Wed, 24 Jan 2024 09:54:24 +0000 (10:54 +0100)] 
po-man: update de.po (from translationproject.org)

18 months agopo: add ro.po (from translationproject.org)
Remus-Gabriel Chelu [Wed, 24 Jan 2024 09:53:02 +0000 (10:53 +0100)] 
po: add ro.po (from translationproject.org)

18 months agopo: update tr.po (from translationproject.org)
Emir SARI [Wed, 24 Jan 2024 09:53:02 +0000 (10:53 +0100)] 
po: update tr.po (from translationproject.org)

18 months agopo: update sr.po (from translationproject.org)
Мирослав Николић [Wed, 24 Jan 2024 09:53:01 +0000 (10:53 +0100)] 
po: update sr.po (from translationproject.org)

18 months agopo: update ja.po (from translationproject.org)
Takeshi Hamasaki [Wed, 24 Jan 2024 09:53:01 +0000 (10:53 +0100)] 
po: update ja.po (from translationproject.org)

18 months agopo: update hr.po (from translationproject.org)
Božidar Putanec [Wed, 24 Jan 2024 09:53:01 +0000 (10:53 +0100)] 
po: update hr.po (from translationproject.org)

18 months agopo: update es.po (from translationproject.org)
Antonio Ceballos Roa [Wed, 24 Jan 2024 09:53:01 +0000 (10:53 +0100)] 
po: update es.po (from translationproject.org)

18 months agopo: update de.po (from translationproject.org)
Hermann Beckers [Wed, 24 Jan 2024 09:53:01 +0000 (10:53 +0100)] 
po: update de.po (from translationproject.org)

18 months agoagetty: remove duplicate include
Karel Zak [Wed, 24 Jan 2024 09:47:23 +0000 (10:47 +0100)] 
agetty: remove duplicate include

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agobuild-sys: improve checkadoc
Karel Zak [Wed, 24 Jan 2024 09:32:24 +0000 (10:32 +0100)] 
build-sys: improve checkadoc

A man page name may include a number (e.g. lastlog2)

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agoMerge branch 'boilerplate/test' of https://github.com/t-8ch/util-linux
Karel Zak [Wed, 24 Jan 2024 08:56:13 +0000 (09:56 +0100)] 
Merge branch 'boilerplate/test' of https://github.com/t-8ch/util-linux

* 'boilerplate/test' of https://github.com/t-8ch/util-linux:
  Documentation: add basic smoketest for boilerplate.c
  treewide: fix newlines when using fputs

18 months agoMerge branch 'master' of https://github.com/jengelh/util-linux
Karel Zak [Wed, 24 Jan 2024 08:55:36 +0000 (09:55 +0100)] 
Merge branch 'master' of https://github.com/jengelh/util-linux

* 'master' of https://github.com/jengelh/util-linux:
  lscpu: add procfs-sysfs dump from VisionFive 2

18 months agoMerge branch 'lsfd--fix-typo-in-cwd-root' of https://github.com/masatake/util-linux
Karel Zak [Wed, 24 Jan 2024 08:55:04 +0000 (09:55 +0100)] 
Merge branch 'lsfd--fix-typo-in-cwd-root' of https://github.com/masatake/util-linux

* 'lsfd--fix-typo-in-cwd-root' of https://github.com/masatake/util-linux:
  lsfd: fix wrong inconsistency in extracting cwd and root associations

18 months agolibmount: improve act file close
Karel Zak [Wed, 24 Jan 2024 08:54:19 +0000 (09:54 +0100)] 
libmount: improve act file close

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agodmesg: fix FD leak
Karel Zak [Wed, 24 Jan 2024 08:53:42 +0000 (09:53 +0100)] 
dmesg: fix FD leak

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agoliblastlog2: fix leaks
Karel Zak [Wed, 24 Jan 2024 08:49:39 +0000 (09:49 +0100)] 
liblastlog2: fix leaks

* close imported file in ll2_import_lastlog()

* free error message in pam_lastlog2.c

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agolscpu: add procfs-sysfs dump from VisionFive 2
Jan Engelhardt [Tue, 23 Jan 2024 21:58:17 +0000 (21:58 +0000)] 
lscpu: add procfs-sysfs dump from VisionFive 2

Signed-off-by: Jan Engelhardt <jengelh@inai.de>
18 months agolsfd: fix wrong inconsistency in extracting cwd and root associations
Masatake YAMATO [Tue, 23 Jan 2024 20:24:09 +0000 (05:24 +0900)] 
lsfd: fix wrong inconsistency in extracting cwd and root associations

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
18 months agoDocumentation: add basic smoketest for boilerplate.c
Thomas Weißschuh [Sat, 20 Jan 2024 12:10:01 +0000 (13:10 +0100)] 
Documentation: add basic smoketest for boilerplate.c

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
18 months agotreewide: fix newlines when using fputs
Thomas Weißschuh [Tue, 23 Jan 2024 19:22:21 +0000 (20:22 +0100)] 
treewide: fix newlines when using fputs

The `fputs()` introduced in #2561 does not automatically include a
trailing newline which the original `puts()` did.
This broke the `--help` output of various utilities.

Changing all format strings to include a newline is not feasible as it
would force all translations to be adapted.

Instead introduce a new helper `fputsln()` that works as expected.

18 months agoMerge branch 'lastlog2' of https://github.com/schubi2/util-linux
Karel Zak [Tue, 23 Jan 2024 13:54:17 +0000 (14:54 +0100)] 
Merge branch 'lastlog2' of https://github.com/schubi2/util-linux

* 'lastlog2' of https://github.com/schubi2/util-linux:
  lastlog2 - Y2038 safe version of lastlog pam_lastlog2 - PAM module which logs user login with lastlog2

18 months agodmesg: add caller_id support
Edward Chron [Thu, 4 Jan 2024 20:43:46 +0000 (12:43 -0800)] 
dmesg: add caller_id support

Submission to Project: util-linux
Open Incident: #2609 at github.com/util-linux/util-linux/issues/2609
Component: util-linux/sys-utils
File: dmesg.c
Code level patch applied against: 2.39.3 - latest code pulled from
           git.github.com:util-linux/util-linux.git
Revision: #1 on 2023/12/08 per Review from Karel Zak
Revision: #2 on 2023/12/12 Adjust line offsets for master update and
                           Add caller_id_size init to dmesg -K
Revision: #3 on 2023/12/12 Use of sizeof for cidbuf and limit search
                           for caller_id to dmesg prefix to msg text
Revision: #4 on 2023/12/15 Ensure SYSLOG and kmsg inputs have
                           caller_id_size set appropriately
Revision: #5 on 2023/12/24 Make caller_id width consistent with
                           makedumpfile
Revision: #6 on 2023/12/30 Use updated test naming convention
Revision: #7 on 2024/01/04 Normalize kmsg caller_id spacing for test
                           platforms by removing caller_id padding
                           in test generated output.

Add support to standard dmesg command for the optional Linux Kernel
debug CONFIG option PRINTK_CALLER which adds an optional dmesg field
that contains the Thread Id or CPU Id that is issuing the printk to
add the message to the kernel ring buffer. This makes debugging simpler
as dmesg entries for a specific thread or CPU can be recognized.

The dmesg -S using the old syslog interface supports printing the
PRINTK_CALLER field but currently standard dmesg does not support
printing the field if present. There are utilities that use dmesg and
so it would be optimal if dmesg supported PRINTK_CALLER as well.

The additional field provided by PRINTK_CALLER is only present
if it was configured for the Linux kernel where the dmesg command
is run. It is a debug option and not configured by default so the
dmesg output will only change for those kernels where the option was
configured when the kernel was built. For users who went to the
trouble to configure PRINTK_CALLER and have the extra field available
for debugging, having dmesg print the field is very helpful.

Size of the PRINTK_CALLER field is determined by the maximum number
tasks that can be run on the system which is limited by the value of
/proc/sys/kernel/pid_max as pid values are from 0 to value - 1.
This value determines the number of id digits needed by the caller id.
The PRINTK_CALLER field is printed as T<id> for a Task Id or C<id>
for a CPU Id for a printk in CPU context. The values are left space
padded and enclosed in parentheses such as: [    T123] or [     C16]

For consistency with dmesg -S which supports the PRINTK_CALLER field
the field is printed followed by a space. For JSON format output the
PRINTK_CALLER field is identified as caller as that is consistent with
it's naming in /dev/kmsg. No space padding is used to reduce space
consumed by the JSON output. So the output from the command on a system
with PRINTK_CALLER field enabled in the Linux .config file the dmesg
output appears as:

> dmesg
...
[  520.897104] [   T3919] usb 3-3: Product: USB 2.0 Hub

and

> dmesg -x
...
kern  :info  : [  520.897104] [   T3919] usb 3-3: Product: USB 2.0 Hub

and

> dmesg -J
...
      },{
         "pri": 6,
         "time":    520.897104,
         "caller": "T3919",
         "msg": "usb 3-3: Product: USB 2.0 Hub"
      },{

and

> dmesg -J -x
...
      },{
         "fac": "kern",
         "pri": "info",
         "time":   520.897104,
         "caller": "T3919",
         "msg": "usb 3-3: Product: USB 2.0 Hub"
      },{

>

For comparison:

> dmesg -S
...
[  520.897104] [ T3919] usb 3-3: Product: USB 2.0 Hub

and

> dmesg -S -x
...
kern  :info  : [  520.897104] [ T3919] usb 3-3: Product: USB 2.0 Hub

Note: When dmesg uses the old syslog interface the reserved space for
      the PRINTK_CALLER field is capped at 5 digits because 32-bit
      kernels are capped at 32768 as the max number of PIDs. However,
      64-bit systems are currently capped at 2^22 PIDs (0 - 4194303).
      The PID cap is set by PID_MAX_LIMIT but the system limit can be
      less so we use /proc/sys/kernel/pid_max to determine the size
      needed to hold the maximum PID value size for the current system.
      Many 64-bit systems support 2^22 PIDs (0 - 4194303) and you see:

> dmesg -x
...
kern  :info  : [  520.899558] [   T3919] hub 3-3:1.0: USB hub found
...
kern  :info  : [ 9830.456898] [  T98982] cgroup: fork rejected by pids ...
kern  :info  : [14301.158878] [ T137336] cgroup: fork rejected by pids ...
kern  :info  : [18980.803190] [T1637865] cgroup: fork rejected by pids ...

> dmesg -S -x
...
kern  :info  : [  520.899558] [ T3919] hub 3-3:1.0: USB hub found
...
kern  :info  : [ 9830.456898] [T98982] cgroup: fork rejected by pids ...
kern  :info  : [14301.158878] [T137336] cgroup: fork rejected by pids ...
kern  :info  : [18980.803190] [T1637865] cgroup: fork rejected by pids ...

This is the only difference seen with PRINTK_CALLER configured and
printing between the dmesg /dev/kmsg interface and the dmesg -S syslog
interface.

Tests naming has been revised based on naming convention Thomas used to
introduce dmest json tests. The naming of test and input files that
reside in tests/ts/dmeg include:

<name> are existing dmesg syslog interface tests and input files.
cid-<name> are dmesg syslog interface caller_id tests and input files.
json-<name> are dmesg kmsg interface tests and input files.
cid-json-<name> are dmesg kmsg interface caller_id tests and input files.

Resulting expected files match the test names.

Signed-off-by: Ivan Delalande <colona@arista.com>
Signed-off-by: Edward Chron <echron@arista.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agobuild-sys: fix po-man clean
Karel Zak [Tue, 23 Jan 2024 11:32:03 +0000 (12:32 +0100)] 
build-sys: fix po-man clean

The files created by "make" should be removed by "clean".

Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agolscpu: cure empty output of lscpu -b/-p
Jan Engelhardt [Thu, 18 Jan 2024 00:50:01 +0000 (00:50 +0000)] 
lscpu: cure empty output of lscpu -b/-p

On riscv, /proc/cpuinfo looks like:

processor       : 3
hart            : 4
isa             : rv64imafdc_zicntr_zicsr_zifencei_zihpm_zba_zbb
mmu             : sv39
uarch           : sifive,u74-mc
mvendorid       : 0x489
marchid         : 0x8000000000000007
mimpid          : 0x4210427
hart isa        : rv64imafdc_zicntr_zicsr_zifencei_zihpm_zba_zbb

As none of the cputype_patterns match any of the fields in that file,
`cpu->type` is never set, which causes `get_cell_data` to always
return nullptr. The output of `lscpu -b --extended=CPU` and `lscpu
-p` is then empty.

Resolve that.

[kzak@redhat.com: - fix DEF_PAT_CPUTYPE()s order
                  - refresh lscpu/lscpu-rv64-linux test]

Signed-off-by: Jan Engelhardt <jengelh@inai.de>
Signed-off-by: Karel Zak <kzak@redhat.com>
18 months agoMerge branch 'master' of https://github.com/biubiuzy/util-linux
Karel Zak [Tue, 23 Jan 2024 10:09:39 +0000 (11:09 +0100)] 
Merge branch 'master' of https://github.com/biubiuzy/util-linux

* 'master' of https://github.com/biubiuzy/util-linux:
  libblkid: (drbd) reduce false-positive

18 months agoMerge branch 'lsfd--fix-2691' of https://github.com/masatake/util-linux
Karel Zak [Tue, 23 Jan 2024 10:07:58 +0000 (11:07 +0100)] 
Merge branch 'lsfd--fix-2691' of https://github.com/masatake/util-linux

* 'lsfd--fix-2691' of https://github.com/masatake/util-linux:
  tests: (lsfd::column-xmode) skip some subtests if OFD locks are not available
  tests: (lsfd) skip mkfds-netns if SIOCGSKNS is not defined
  tests: (lsfd) add lsfd_check_mkfds_factory as a help function
  tests: (test_mkfds) add --is-available option
  lsfd: build lsfd even if kcmp.h is not available
  tests: (refactor (test_mkfds, lsfd)) use TS_EXIT_NOTSUPP instead of EXIT_ENOSYS

18 months agoMerge branch 'findmnt-inode' of https://github.com/masatake/util-linux
Karel Zak [Tue, 23 Jan 2024 10:06:51 +0000 (11:06 +0100)] 
Merge branch 'findmnt-inode' of https://github.com/masatake/util-linux

* 'findmnt-inode' of https://github.com/masatake/util-linux:
  findmnt: add -I, --dfi options for imitating the output of df -i
  findmnt: add inode-related columns for implementing "df -i" like output

18 months agoMerge branch 'wipefs-man-typos' of https://github.com/codefiles/util-linux
Karel Zak [Tue, 23 Jan 2024 09:57:16 +0000 (10:57 +0100)] 
Merge branch 'wipefs-man-typos' of https://github.com/codefiles/util-linux

* 'wipefs-man-typos' of https://github.com/codefiles/util-linux:
  wipefs: (man) fix typos

18 months agoMerge branch 'PR/libmount-utab-masking' of github.com:karelzak/util-linux-work
Karel Zak [Tue, 23 Jan 2024 09:55:45 +0000 (10:55 +0100)] 
Merge branch 'PR/libmount-utab-masking' of github.com:karelzak/util-linux-work

* 'PR/libmount-utab-masking' of github.com:karelzak/util-linux-work:
  libmount: ignore unwanted kernel events in monitor
  libmount: add utab.act file
  libmount: cleanup locking in table update code
  libmount: introduce reference counting for libmnt_lock

18 months agoMerge branch 'remove-geteuid-ctrlaltdel' of https://github.com/JJ-Meng/util-linux
Karel Zak [Tue, 23 Jan 2024 09:54:51 +0000 (10:54 +0100)] 
Merge branch 'remove-geteuid-ctrlaltdel' of https://github.com/JJ-Meng/util-linux

* 'remove-geteuid-ctrlaltdel' of https://github.com/JJ-Meng/util-linux:
  ctrlaltdel: remove unnecessary uid check

18 months agowipefs: (man) fix typos
codefiles [Tue, 23 Jan 2024 01:14:33 +0000 (20:14 -0500)] 
wipefs: (man) fix typos

18 months agofindmnt: add -I, --dfi options for imitating the output of df -i
Masatake YAMATO [Mon, 22 Jan 2024 21:05:39 +0000 (06:05 +0900)] 
findmnt: add -I, --dfi options for imitating the output of df -i

An example output:

  $ ./findmnt -I
  SOURCE                            FSTYPE      INO.TOTAL  INO.USED INO.AVAIL INO.USE% TARGET
  /dev/mapper/fedora_dev64-root     ext4          5341184   1135307   4205877      21% /
  devtmpfs                          devtmpfs     32930640      1209  32929431       0% /dev
  tmpfs                             tmpfs        32938620        86  32938534       0% /dev/shm
  ...

Signed-off-by: Masatake YAMATO <yamato@redhat.com>