systemd/5010-cgroup-Rename-effective-limits-internal-table.patch
Franck Bui 94f1d69402 - Upgrade to v255.3 (commit 96edf7ad1866172b994cafb4df49e27d68ce8e87)
See https://github.com/openSUSE/systemd/blob/SUSE/v255/NEWS for details.
  - This includes the following bug fixes:
    - commit 6e10405aa25fe5e76b740d9ec59730e3f4470c7a (bsc#1219766)
  - The following patches have been rebased:
    - 0002-rc-local-fix-ordering-startup-for-etc-init.d-boot.lo.patch
    - 0008-sysv-generator-translate-Required-Start-into-a-Wants.patch
    - 0009-pid1-handle-console-specificities-weirdness-for-s390.patch
    - 5001-Revert-udev-update-devlink-with-the-newer-device-nod.patch
    - 5002-Revert-udev-revert-workarounds-for-issues-caused-by-.patch
  - The following patches have been removed since they're part of v255:
    - 5003-cgroup-rename-TasksMax-structure-to-CGroupTasksMax.patch
    - 5004-bus-print-properties-ignore-CGROUP_LIMIT_MAX-for-Mem.patch
    - 5005-bus-print-properties-prettify-more-unset-properties.patch
  - systemd-boot has been added to the list of the dependencies of the
    systemd-testsuite package as the installation of the bootloader is now
    tested.
  - the following patches have been backported on top of v255.3:
    96edf7ad18 service: Demote log level of NotifyAccess= messages to debug (bsc#1210113 jsc#PED-6214)
    fdde7f26d6 vconsole-setup: don't fail if the only found vc is already used by plymouth (bsc#1218618)
    f96c587d41 rules: set up tty permissions and group for /dev/hvc* nodes (bsc#1218137)
    63a41b8899 vconsole-setup: remember the correct error value when open_terminal() fails
    f51a2e038c vconsole-setup: handle the case where the vc is in KD_GRAPHICS mode more gracefully (bsc#1215282)
    15025a04c4 test: make sure to install the filesystem package in the test image on SUSE
    06fecfb635 test: make sure that sd-boot is installed before testing bootctl
    1e8788ea68 test: install systemd-boot in openSUSE test images
    6e2875ad43 test/test-shutdown.py: optionally display the test I/Os in a dedicated log file
    4be1a801b4 test-69: send SIGTERM to ask systemd-nspawn to properly stop the container
    7bdab7b7c7 man: Document ranges for distributions config files and local config files
    3f12a6c22f test: systemd-update-utmp is optional

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1497
2024-02-23 16:24:26 +00:00

67 lines
2.9 KiB
Diff

From ae7d09f074e554a241ba66a2dee2a0cb4b3a0162 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michal=20Koutn=C3=BD?= <mkoutny@suse.com>
Date: Mon, 22 Jan 2024 16:58:18 +0100
Subject: [PATCH 5010/5010] cgroup: Rename effective limits internal table
Post-merge fixup of commit 4fb0d2dc14 ("cgroup: Add EffectiveMemoryMax=,
EffectiveMemoryHigh= and EffectiveTasksMax= properties"), no functional
change intended.
(cherry picked from commit 8ad614890bba66b5f6b590d6a3e1b8b04a920126)
[mkoutny: fixes jsc#PED-5659]
---
src/core/cgroup.c | 4 ++--
src/core/cgroup.h | 4 ++--
src/core/dbus-unit.c | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/core/cgroup.c b/src/core/cgroup.c
index 285fa200d6..0c30aefe80 100644
--- a/src/core/cgroup.c
+++ b/src/core/cgroup.c
@@ -4715,10 +4715,10 @@ static const char* const cgroup_memory_accounting_metric_table[_CGROUP_MEMORY_AC
DEFINE_STRING_TABLE_LOOKUP(cgroup_memory_accounting_metric, CGroupMemoryAccountingMetric);
-static const char *const cgroup_limit_type_table[_CGROUP_LIMIT_TYPE_MAX] = {
+static const char *const cgroup_effective_limit_type_table[_CGROUP_LIMIT_TYPE_MAX] = {
[CGROUP_LIMIT_MEMORY_MAX] = "EffectiveMemoryMax",
[CGROUP_LIMIT_MEMORY_HIGH] = "EffectiveMemoryHigh",
[CGROUP_LIMIT_TASKS_MAX] = "EffectiveTasksMax",
};
-DEFINE_STRING_TABLE_LOOKUP(cgroup_limit_type, CGroupLimitType);
+DEFINE_STRING_TABLE_LOOKUP(cgroup_effective_limit_type, CGroupLimitType);
diff --git a/src/core/cgroup.h b/src/core/cgroup.h
index 54bce91ea1..6e3d05b7d2 100644
--- a/src/core/cgroup.h
+++ b/src/core/cgroup.h
@@ -435,8 +435,8 @@ CGroupIPAccountingMetric cgroup_ip_accounting_metric_from_string(const char *s)
const char* cgroup_io_accounting_metric_to_string(CGroupIOAccountingMetric m) _const_;
CGroupIOAccountingMetric cgroup_io_accounting_metric_from_string(const char *s) _pure_;
-const char* cgroup_limit_type_to_string(CGroupLimitType m) _const_;
-CGroupLimitType cgroup_limit_type_from_string(const char *s) _pure_;
+const char* cgroup_effective_limit_type_to_string(CGroupLimitType m) _const_;
+CGroupLimitType cgroup_effective_limit_type_from_string(const char *s) _pure_;
const char* cgroup_memory_accounting_metric_to_string(CGroupMemoryAccountingMetric m) _const_;
CGroupMemoryAccountingMetric cgroup_memory_accounting_metric_from_string(const char *s) _pure_;
diff --git a/src/core/dbus-unit.c b/src/core/dbus-unit.c
index ac6add4700..bb19831814 100644
--- a/src/core/dbus-unit.c
+++ b/src/core/dbus-unit.c
@@ -1458,7 +1458,7 @@ static int property_get_effective_limit(
assert(reply);
assert(property);
- assert_se((type = cgroup_limit_type_from_string(property)) >= 0);
+ assert_se((type = cgroup_effective_limit_type_from_string(property)) >= 0);
(void) unit_get_effective_limit(u, type, &value);
return sd_bus_message_append(reply, "t", value);
}
--
2.35.3