Commit Graph

9 Commits

Author SHA1 Message Date
Thomas Haller
f299a79d5b libnm: sort attribute names in nm_tc_action_get_attribute_names()
The order in which the attribute names are returns should
be defined and stable. Sort them and re-use the helper functions.
2017-12-18 12:14:49 +01:00
Lubomir Rintel
902bbfdb18 ifcfg-rh: add tc support
Format:

  QDISC1=ingress
  QDISC2="root handle 1234: fq_codel"
  FILTER1="parent ffff: matchall action simple sdata Input"
  FILTER2="parent 1234: matchall action simple sdata Output"
2017-12-11 11:20:13 +01:00
Thomas Haller
7cd2b6178d libnm: disable g_warning() from library
Printing a g_warning() from the library is not helpful.

Client-side, libnm should support newer server versions and changing
formats. To support forward-compatibility, it should parse the received
GVariant best-effort like, without complaining.

Server-side, libnm-core should return errors when receiving invalid
configuration. It must not maintain forward-compatibility, only
backward-compatibility -- which is implemented by handling old
and newer formats. But never should server allow a configuration
that is invalid.

Currently, the libnm API cannot yet fail at this point. Hence,
it cannot return an error. It would need a strict and relaxed
parsing mode. Until that exists, just comment out the warnings.
2017-12-11 11:02:04 +01:00
Lubomir Rintel
dbef7e684f libnm-core/tests: test NMSettingTCConfig traffic filter support 2017-12-11 11:02:04 +01:00
Lubomir Rintel
e035cb7be0 libnm-core: add traffic filter support to NMSettingTCConfig 2017-12-11 11:02:04 +01:00
Lubomir Rintel
733464ada3 libnm-core: add functionality for dealing with tc-style action specifiers
Tailored to fit both nmcli and keyfile needs.
2017-12-11 11:02:04 +01:00
Thomas Haller
b0ba17e903 libnm-core: consider attributes in nm_tc_action_equal() 2017-12-11 11:01:59 +01:00
Lubomir Rintel
7c8ce778fb libnm-core: add action support to NMSettingTCConfig
The actions are not too useful my themselves, but it will be possible to
embed them into traffic filters in subsequent commits.
2017-12-11 10:52:23 +01:00
Lubomir Rintel
da13c7a1a4 libnm-core: add NMSettingTCConfig with qdisc support
Currently is only able to hold the queueing disciplines.
2017-12-11 10:52:22 +01:00