]> git.ipfire.org Git - thirdparty/iproute2.git/commit
lib: Move get_size() from tc here
authorPetr Machata <me@pmachata.org>
Sat, 5 Dec 2020 21:13:35 +0000 (22:13 +0100)
committerDavid Ahern <dsahern@gmail.com>
Wed, 9 Dec 2020 02:30:50 +0000 (02:30 +0000)
commit44396bdfcc0aed8473f41aaf8f244a3aa79eccdf
treedcc40c6afd91af9a67ed4bfc6834c18a13232ea1
parentf3be0e6366ac1f608449f6048fef54152a9f5776
lib: Move get_size() from tc here

The function get_size() serves for parsing of sizes using a handly notation
that supports units and their prefixes, such as 10Kbit. This will be useful
for the DCB buffer size parsing. Move the function from TC to the general
library, so that it can be reused.

Signed-off-by: Petr Machata <me@pmachata.org>
Signed-off-by: David Ahern <dsahern@gmail.com>
include/utils.h
lib/utils.c
tc/tc_util.c
tc/tc_util.h