]> git.ipfire.org Git - thirdparty/util-linux.git/commit
lsfd: add 'm' flag representing "multiplexed by epoll_wait(2)" to XMODE column
authorMasatake YAMATO <yamato@redhat.com>
Mon, 10 Jul 2023 14:49:41 +0000 (23:49 +0900)
committerMasatake YAMATO <yamato@redhat.com>
Mon, 10 Jul 2023 15:06:24 +0000 (00:06 +0900)
commitda9013142193231fadf430a118969453bedc0658
treec1282da8558266269fbf6e3b046b5bb11e364394
parentb8ea758b0c86ef28ffbca90b30d470f3da540fb8
lsfd: add 'm' flag representing "multiplexed by epoll_wait(2)" to XMODE column

An example output:

    $ ./lsfd -p 3101482 -Q '(FD > 2)'
    COMMAND        PID   USER ASSOC  XMODE      TYPE       SOURCE MNTID INODE NAME
    test_mkfds 3101482 yamato     3 rw---- eventpoll anon_inodefs    15   106 tfds=4,5
    test_mkfds 3101482 yamato     4 r----m       CHR        mem:8    23     8 /dev/random
    test_mkfds 3101482 yamato     5 -w---m       CHR        mem:8    23     8 /dev/random

The fd 4 and 5 is multiplexed by 3, an evetpoll fd.
Therefore 'm' flags in XMODE column for fd 4 and 5 are set.

Just one character but 'm' may help users to understand the "IO structure"
of a process.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
misc-utils/lsfd-file.c
misc-utils/lsfd-unkn.c
misc-utils/lsfd.1.adoc
misc-utils/lsfd.c
misc-utils/lsfd.h