From 61ec09f900166653334414a8d8718571babe629be6f4edeee586d79750dde632 Mon Sep 17 00:00:00 2001 From: "Dr. Werner Fink" Date: Thu, 11 Jun 2015 12:35:52 +0000 Subject: [PATCH] . OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=871 --- ...some-boolean-survive-a-daemon-reload.patch | 69 +++++++++++++++++++ ...aa13539ed2cd4b31972cd30f678543-apply.patch | 26 ------- systemd-mini.changes | 8 +++ systemd-mini.spec | 11 ++- systemd.changes | 8 +++ systemd.spec | 11 ++- 6 files changed, 93 insertions(+), 40 deletions(-) create mode 100644 0001-Let-some-boolean-survive-a-daemon-reload.patch delete mode 100644 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch diff --git a/0001-Let-some-boolean-survive-a-daemon-reload.patch b/0001-Let-some-boolean-survive-a-daemon-reload.patch new file mode 100644 index 00000000..5ce4385d --- /dev/null +++ b/0001-Let-some-boolean-survive-a-daemon-reload.patch @@ -0,0 +1,69 @@ +Based on deff2d3e18e831d63bf98dd4114e4e35e41966e8 Mon Sep 17 00:00:00 2001 +From: Werner Fink +Date: Wed, 10 Jun 2015 10:47:13 +0200 +Subject: [PATCH] Let some boolean survive a daemon-reload + +Without the boolean bus_name_good services as well as cgroup_realized +for units a unit of Type=dbus and ExecReload sending SIGHUP to $MAINPID +will be terminated if systemd will be daemon reloaded. + +https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=746151 +https://bugs.freedesktop.org/show_bug.cgi?id=78311 +https://bugzilla.opensuse.org/show_bug.cgi?id=934077 +--- + src/core/service.c | 9 +++++++++ + src/core/unit.c | 11 +++++++++++ + 2 files changed, 20 insertions(+) + +--- systemd-219/src/core/service.c ++++ systemd-219/src/core/service.c 2015-06-11 12:24:36.769519910 +0000 +@@ -1920,6 +1920,7 @@ static int service_serialize(Unit *u, FI + unit_serialize_item_format(u, f, "main-pid", PID_FMT, s->main_pid); + + unit_serialize_item(u, f, "main-pid-known", yes_no(s->main_pid_known)); ++ unit_serialize_item(u, f, "bus-name-good", yes_no(s->bus_name_good)); + + if (s->status_text) + unit_serialize_item(u, f, "status-text", s->status_text); +@@ -2044,6 +2045,14 @@ static int service_deserialize_item(Unit + log_unit_debug(u->id, "Failed to parse main-pid-known value %s", value); + else + s->main_pid_known = b; ++ } else if (streq(key, "bus-name-good")) { ++ int b; ++ ++ b = parse_boolean(value); ++ if (b < 0) ++ log_debug_unit(u->id, "Failed to parse bus-name-good value %s", value); ++ else ++ s->bus_name_good = b; + } else if (streq(key, "status-text")) { + char *t; + +--- systemd-219/src/core/unit.c ++++ systemd-219/src/core/unit.c 2015-06-11 12:30:56.805519155 +0000 +@@ -2612,6 +2612,7 @@ int unit_serialize(Unit *u, FILE *f, FDS + + if (u->cgroup_path) + unit_serialize_item(u, f, "cgroup", u->cgroup_path); ++ unit_serialize_item(u, f, "cgroup-realized", yes_no(u->cgroup_realized)); + + if (serialize_jobs) { + if (u->job) { +@@ -2803,6 +2804,16 @@ int unit_deserialize(Unit *u, FILE *f, F + assert(hashmap_put(u->manager->cgroup_unit, s, u) == 1); + + continue; ++ } else if (streq(l, "cgroup-realized")) { ++ int b; ++ ++ b = parse_boolean(v); ++ if (b < 0) ++ log_debug("Failed to parse cgroup-realized bool %s", v); ++ else ++ u->cgroup_realized = b; ++ ++ continue; + } + + if (unit_can_serialize(u)) { diff --git a/1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch b/1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch deleted file mode 100644 index 8a108af0..00000000 --- a/1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch +++ /dev/null @@ -1,26 +0,0 @@ -Exist only to be able to apply the patch -1056-udevd-add-event-timeout-commandline-option.patch -without the BLKRRPART ioctl patches. - ---- systemd-210/src/udev/udevd.c -+++ systemd-210/src/udev/udevd.c 2014-07-30 11:52:34.318235685 +0000 -@@ -1311,16 +1311,16 @@ int main(int argc, char *argv[]) - if (worker->state != WORKER_RUNNING) - continue; - -- if ((now(CLOCK_MONOTONIC) - worker->event_start_usec) > 30 * 1000 * 1000) { -+ if ((now(CLOCK_MONOTONIC) - worker->event_start_usec) > 30 * USEC_PER_SEC) { - log_error("worker [%u] %s timeout; kill it", worker->pid, - worker->event ? worker->event->devpath : ""); - kill(worker->pid, SIGKILL); - worker->state = WORKER_KILLED; -+ - /* drop reference taken for state 'running' */ - worker_unref(worker); - if (worker->event) { -- log_error("seq %llu '%s' killed", -- udev_device_get_seqnum(worker->event->dev), worker->event->devpath); -+ log_error("seq %llu '%s' killed", udev_device_get_seqnum(worker->event->dev), worker->event->devpath); - worker->event->exitcode = -64; - event_queue_delete(worker->event, true); - worker->event = NULL; diff --git a/systemd-mini.changes b/systemd-mini.changes index 5a962a4b..1e69c8eb 100644 --- a/systemd-mini.changes +++ b/systemd-mini.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Thu Jun 11 12:12:58 UTC 2015 - werner@suse.de + +- Drop 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch + as now upstream code +- Add 0001-Let-some-boolean-survive-a-daemon-reload.patch to fix + bsc#933365 and boo#934077 + ------------------------------------------------------------------- Mon May 18 12:25:54 UTC 2015 - jengelh@inai.de diff --git a/systemd-mini.spec b/systemd-mini.spec index 1d27ae1a..29e05f44 100644 --- a/systemd-mini.spec +++ b/systemd-mini.spec @@ -1,7 +1,7 @@ # # spec file for package systemd-mini # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -254,6 +254,8 @@ Patch520: systemd-add-user-keep.patch # PATCH-FIX-SUSE systemd-add-user-keep.patch (bnc#903009) Patch521: kbd-model-map.patch Patch522: 0001-core-rework-device-state-logic.patch +# PATCH-FIX-SUSE/PATCH-FIX-UPSTREAM +Patch523: 0001-Let-some-boolean-survive-a-daemon-reload.patch # UDEV PATCHES # ============ @@ -285,8 +287,6 @@ Patch1013: 1013-no-runtime-PM-for-IBM-consoles.patch Patch1035: 1035-99-systemd.rules-Ignore-devices-with-SYSTEMD_READY-0.patch # PATCH-FIX-SUSE See bnc#882714 comment #51 Patch1037: 1037-udev-exclude-cd-dvd-from-block-device.patch -# PATCH-FIX-SUSE 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch -Patch1055: 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch # PATCH-FIX-SUSE 1060-udev-use-device-mapper-target-name-for-btrfs-device-ready.patch Patch1060: 1060-udev-use-device-mapper-target-name-for-btrfs-device-ready.patch # PATCH-FIX-SUSE 1062-rules-set-default-permissions-for-GenWQE-devices.patch (bnc#890977) @@ -606,6 +606,7 @@ cp %{SOURCE7} m4/ %patch520 -p1 %patch521 -p1 %patch522 -p1 +%patch523 -p1 # udev patches %patch1001 -p1 @@ -621,10 +622,6 @@ cp %{SOURCE7} m4/ %if %{with blkrrpart} %patch1037 -p1 %endif -%if %{with blkrrpart} -%else -%patch1055 -p1 -%endif %patch1060 -p1 %patch1062 -p1 %patch1066 -p1 diff --git a/systemd.changes b/systemd.changes index 5a962a4b..1e69c8eb 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Thu Jun 11 12:12:58 UTC 2015 - werner@suse.de + +- Drop 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch + as now upstream code +- Add 0001-Let-some-boolean-survive-a-daemon-reload.patch to fix + bsc#933365 and boo#934077 + ------------------------------------------------------------------- Mon May 18 12:25:54 UTC 2015 - jengelh@inai.de diff --git a/systemd.spec b/systemd.spec index 512e2356..5a2fc793 100644 --- a/systemd.spec +++ b/systemd.spec @@ -1,7 +1,7 @@ # # spec file for package systemd # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -249,6 +249,8 @@ Patch520: systemd-add-user-keep.patch # PATCH-FIX-SUSE systemd-add-user-keep.patch (bnc#903009) Patch521: kbd-model-map.patch Patch522: 0001-core-rework-device-state-logic.patch +# PATCH-FIX-SUSE/PATCH-FIX-UPSTREAM +Patch523: 0001-Let-some-boolean-survive-a-daemon-reload.patch # UDEV PATCHES # ============ @@ -280,8 +282,6 @@ Patch1013: 1013-no-runtime-PM-for-IBM-consoles.patch Patch1035: 1035-99-systemd.rules-Ignore-devices-with-SYSTEMD_READY-0.patch # PATCH-FIX-SUSE See bnc#882714 comment #51 Patch1037: 1037-udev-exclude-cd-dvd-from-block-device.patch -# PATCH-FIX-SUSE 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch -Patch1055: 1055-let-9719859c07aa13539ed2cd4b31972cd30f678543-apply.patch # PATCH-FIX-SUSE 1060-udev-use-device-mapper-target-name-for-btrfs-device-ready.patch Patch1060: 1060-udev-use-device-mapper-target-name-for-btrfs-device-ready.patch # PATCH-FIX-SUSE 1062-rules-set-default-permissions-for-GenWQE-devices.patch (bnc#890977) @@ -601,6 +601,7 @@ cp %{SOURCE7} m4/ %patch520 -p1 %patch521 -p1 %patch522 -p1 +%patch523 -p1 # udev patches %patch1001 -p1 @@ -616,10 +617,6 @@ cp %{SOURCE7} m4/ %if %{with blkrrpart} %patch1037 -p1 %endif -%if %{with blkrrpart} -%else -%patch1055 -p1 -%endif %patch1060 -p1 %patch1062 -p1 %patch1066 -p1