scripts: get_abi.pl: show progress
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 28 Sep 2021 10:14:03 +0000 (12:14 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 28 Sep 2021 10:45:42 +0000 (12:45 +0200)
commit28331a011d1cab2e35be9d56b7aec2a203e7914e
treefa1d819e04695c248c2ced097006060220da5c5b
parent2833e30aa04d4a025341b7071f9d469538367605
scripts: get_abi.pl: show progress

As parsing the sysfs entries can take a long time, add
progress information.

The progress logic will update the stats on every second,
or on 1% steps of the progress.

When STDERR is a console, it will use a single line, using
a VT-100 command to erase the line before rewriting it.
Otherwise, it will put one message on a separate line.
That would help to identify what parts of sysfs checking
that it is taking more time to process.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/4e581dcbec21ad8a60fff883498018f96f13dd1c.1632823172.git.mchehab+huawei@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
scripts/get_abi.pl