Skip to content

Commit

Permalink
[net] Disable prio and cls cgroups to make working cgroup2 sock match…
Browse files Browse the repository at this point in the history
…ing (#198)

* Unset CONFIG_CGROUP_NET_CLASSID, CONFIG_CGROUP_NET_PRIO and depended
  modules CONFIG_NET_CLS_CGROUP, CONFIG_NETFILTER_XT_MATCH_CGROUP
  in Kconfig to disable those v1 cgroups.
  The system contains programs, which use both groups v1 and v2, e.g. docker
  uses net_prio, net_cls and "ip vrf" uses cgroup2 socket matching.
  But, Linux kernel does not allow to work with net_prio, net_cls and
  socket matching from cgroup2 in the same time. Link to comment in source file:
  https://elixir.bootlin.com/linux/v4.19.156/source/include/linux/cgroup-defs.h#L745
  The related warning, appearing on startup: "sonic INFO kernel: [ 14.057746] cgroup:
  cgroup: disabling cgroup2 socket matching due to net_prio or net_cls activation".
  Disabling of net_prio and net_cls will prevent this conflict and make programs,
  which uses cgroup2 socket matching, to be working correct.

Signed-off-by: Maksym Belei <Maksym_Belei@jabil.com>
  • Loading branch information
maksymbelei95 authored Mar 11, 2021
1 parent 30b9a59 commit ba9558c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions patch/kconfig-exclusions
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
[common]
# Unset STRICT_DEVMEM according to Broadcom's requirement and for CENTEC arm64 arch
CONFIG_STRICT_DEVMEM
# Unset classid and priority network cgroups due to conflict between cgroups v1 and v2
CONFIG_CGROUP_NET_CLASSID
CONFIG_NET_CLS_CGROUP
CONFIG_NETFILTER_XT_MATCH_CGROUP
CONFIG_CGROUP_NET_PRIO

[amd64]
# Unset X86_PAT according to Broadcom's requirement
Expand Down

0 comments on commit ba9558c

Please sign in to comment.