Lennart Poettering
cfb56a72ce
Merge pull request #7415 from keszybz/udev-alloca
...
udev: modernize style in path_id
2017-11-24 13:32:03 +01:00
Lennart Poettering
f170504825
Merge pull request #7453 from neosilky/coccinelle-fixes
...
Applied fixes from Coccinelle
2017-11-24 13:29:48 +01:00
Lennart Poettering
e92b78b561
Merge pull request #7454 from neosilky/cocci-fixes
...
Apply more fixes from Coccinelle
2017-11-24 13:29:32 +01:00
Daniel Lockyer
4600a396d5
Remove NULL as last parameter to strjoin
2017-11-24 10:37:08 +00:00
Daniel Lockyer
a7419dbc59
Replace use of snprintf with xsprintf
2017-11-24 10:36:04 +00:00
Daniel Lockyer
f9ecfd3bbe
Replace free and reassignment with free_and_replace
2017-11-24 10:33:41 +00:00
Daniel Lockyer
5fecf46d76
Replace free and return NULL with return mfree
2017-11-24 10:31:49 +00:00
Daniel Lockyer
95333b2bed
Replace free and nullify by mfree
2017-11-24 09:37:50 +00:00
Daniel Lockyer
87e4e28dcf
Replace empty ternary with helper method
2017-11-24 09:31:08 +00:00
Yu Watanabe
8b3c4b5757
test-execute: test more % specifiers ( #7450 )
2017-11-24 10:17:28 +01:00
Shawn Landden
fb8e74a499
__attribute__((fallthrough)) only when -Wimplicit-fallthrough ( #7448 )
...
That is version 7 or greater
https://developers.redhat.com/blog/2017/03/10/wimplicit-fallthrough-in-gcc-7/
Fix regression of https://github.com/systemd/systemd/pull/7389
82a27ba821
on older gccs
bumping to re-run CI
upstream FAIL timed out
boot-smoke FAIL non-zero exit status 1
2017-11-24 10:08:12 +01:00
Lennart Poettering
9b3f8e5968
journalctl: add --output-fields= to --help text ( #7443 )
...
Follow-up for #7181
2017-11-24 10:04:14 +01:00
Lennart Poettering
b8afec2107
man: reorder/add sections to systemd.exec(5) ( #7412 )
...
The long long list of settings is getting too confusing, let's add some
sections and reorder things in them.
This makes no changes regarding contents, it only reorders things,
sometimes reindents them, and adds sections that made sense to me to
some degree.
Within each sections the settings are ordered by relevance (at least
according to how relevant I personally find them), and not
alphabetically.
2017-11-23 21:20:48 +01:00
Lennart Poettering
e2cd893bda
Merge pull request #7436 from poettering/mount-util-fixup
...
mount-util.c fixes regarding name_to_handle_at()
2017-11-23 21:01:12 +01:00
Susant Sahani
8dc787d185
networkd: fix commit 5f04a209ea ( #7432 )
...
If classless route not provided configure default routes.
Something went wrong in the rebase.
2017-11-24 01:38:08 +09:00
WaLyong Cho
459aafc6d8
smack: allow comments on smack rules ( #7438 )
2017-11-23 16:27:19 +01:00
Hans de Goede
3a26bc1dd5
hwdb: Add accel mount settings for Axxo TW-1011 2-in-1 ( #7439 )
...
Add accel mount settings for the SMO8500 accelerometer found in
Axxo TW-1011 2-in-1 devices to 60-sensor.hwdb.
2017-11-23 16:25:42 +01:00
Yu Watanabe
8a38aac3a7
meson: do not install RPM macros if rpmmacrosdir is set to no ( #7430 )
...
Fixes #7427 .
2017-11-23 14:20:22 +01:00
Evgeny Vereshchagin
71050acb68
tests: install test as part of BASICTOOLS ( #7434 )
...
This makes TEST-19-DELEGATE, which is currently failing, work.
Closes https://github.com/systemd/systemd/issues/7425 .
2017-11-23 13:28:12 +01:00
Lennart Poettering
9b1573ef76
test: fix test-mount-util when handling duplicate mounts on the same location
...
The test was written so far under the assumption that if two mounts are
placed onto the same location the "upper" mount is listed later in
/proc/self/mountinfo. This appears not to be guaranteed however, as
running the tests in a normal nspawn shows.
This patch fixes that: it reverses the hashmap of mounts we build:
instead of keying by path, we key by mnt_id, and if we notice that
path_get_mnt_id() doesn't match what a line in /proc/self/mountinfo
says, we use the returned ID to check if maybe another line agrees.
Fixes : #7431
2017-11-23 13:28:06 +01:00
Lennart Poettering
4739fc554d
mount-util: fix bad indenting
2017-11-23 13:28:06 +01:00
Lennart Poettering
c83b20d73b
mount-util: EOVERFLOW might have other causes than buffer size issues
...
When we get EOVERFLOW this might be caused by untriggered nfs4 mounts
(see discussion at
https://github.com/systemd/systemd/pull/7395#issuecomment-346164481 and
further down).
Handle this nicely by falling back to fdinfo-based mntid determination.
Fixes : #7082
2017-11-23 13:28:06 +01:00
Lennart Poettering
0d9bcb7c37
mount-util: fix error propagation in fd_fdinfo_mnt_id()
2017-11-23 13:28:06 +01:00
Lennart Poettering
fc010b01e7
mount-util: drop exponential buffer growing in name_to_handle_at_loop()
...
So, it appears name_to_handle_at() always returns the right buffer size
on EOVERFLOW, when it's returned due to a too small buffer. Let's rely
on that exclusively for sizing the buffer, and let's drop the
exponential buffer growing.
The new logic is now: if we see EOVERFLOW and the returned size has
increased, resize our buffer and try again. But if it didn't increase,
then propagate the EOVERFLOW as it likely has other causes.
2017-11-23 13:28:06 +01:00
Yu Watanabe
706424c2e2
core/manager: check the existance of the special units ( #7433 )
...
In the user mode, not all special units exist.
So, we need to check whether the units exist or not before operate
something to the units.
Such the check was mistakenly dropped by e68537f0ba .
Fixes #7426 .
2017-11-23 13:25:56 +01:00
Carsten Strotmann
f75707dbcb
Fixed Type nmnds-ipv4 -> nmdns-ipv4 ( #7435 )
2017-11-23 13:12:00 +01:00
Evgeny Vereshchagin
0fb8449930
cgroup: downgrade the log level of "invocation id" messages to debug ( #7422 )
...
Now that d3070fbdf6 has been merged, these errors are not as
critical as they used to be.
2017-11-23 11:07:20 +01:00
Evgeny Vereshchagin
abe4a74f80
Merge pull request #7420 from brauner/2017-11-22/systemd_in_container_unified_cgroup_hierarchy
...
cgroup: skip unwritable cgroups
2017-11-23 04:11:04 +03:00
Christian Brauner
2d56b80a18
cgroup: test whether pure unified hierarchy is writable
...
If it is not writable we should not mount it.
2017-11-22 17:35:21 +01:00
Christian Brauner
e07aefbd67
cgroup: check whether unified hierarchy is writable
...
When systemd is running inside a container employing user
namespaces it currently mounts the unified cgroup hierarchy
without being able to write to it. This causes systemd to
freeze during boot.
This patch checks whether the unified cgroup hierarchy
is writable. If it is not it will not mount it.
This solution is based on a patch by Evgeny Vereshchagin.
Closes #6408 .
Closes https://github.com/lxc/lxc/issues/1678 .
2017-11-22 17:34:25 +01:00
Lennart Poettering
0a5b5115b1
Merge pull request #7416 from keszybz/readd-lost-test
...
Readd lost test
2017-11-22 17:24:21 +01:00
Zbigniew Jędrzejewski-Szmek
6b97bf2287
meson: re-attach rule-syntax-check.py test
...
39/248 rule-syntax-check OK 0.07 s
--- command ---
/home/zbyszek/src/systemd-work/test/rule-syntax-check.py \
/home/zbyszek/src/systemd-work/build/../rules/60-block.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-cdrom_id.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-drm.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-evdev.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-input-id.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-persistent-alsa.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-persistent-input.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-persistent-storage.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-persistent-storage-tape.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-persistent-v4l.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-sensor.rules \
/home/zbyszek/src/systemd-work/build/../rules/60-serial.rules \
/home/zbyszek/src/systemd-work/build/../rules/70-joystick.rules \
/home/zbyszek/src/systemd-work/build/../rules/70-mouse.rules \
/home/zbyszek/src/systemd-work/build/../rules/70-touchpad.rules \
/home/zbyszek/src/systemd-work/build/../rules/75-net-description.rules \
/home/zbyszek/src/systemd-work/build/../rules/75-probe_mtd.rules \
/home/zbyszek/src/systemd-work/build/../rules/78-sound-card.rules \
/home/zbyszek/src/systemd-work/build/../rules/80-drivers.rules \
/home/zbyszek/src/systemd-work/build/../rules/80-net-setup-link.rules \
/home/zbyszek/src/systemd-work/build/rules/50-udev-default.rules \
/home/zbyszek/src/systemd-work/build/rules/64-btrfs.rules \
/home/zbyszek/src/systemd-work/build/rules/99-systemd.rules
--- stdout ---
...
-------
It got dropped by mistake in 72cdb3e783 .
2017-11-22 12:46:08 +01:00
Zbigniew Jędrzejewski-Szmek
2956395c83
rule-test-syntax: modernize syntax and add debug message
2017-11-22 12:29:58 +01:00
Zbigniew Jędrzejewski-Szmek
bfbcf21d75
Merge pull request #7406 from poettering/timestamp-rework
...
timestamping rework
2017-11-22 11:55:04 +01:00
Zbigniew Jędrzejewski-Szmek
a6856129ec
udev: "handle" oom in path_id
...
path_prepend returned a status code, but it wasn't looked at anywhere.
Adding checks for the return value in all the bazillion places where it
is called is not very attractive, so let's just make the whole program
abort cleanly if the (very unlikely) oom is encountered.
2017-11-22 10:34:47 +01:00
Zbigniew Jędrzejewski-Szmek
d7d7daece9
udev: modernize style in path_id
...
No functional change.
2017-11-22 10:34:34 +01:00
Susant Sahani
d6df583c87
networkd: introduce vxcan netdev. ( #7150 )
...
Similar to the virtual ethernet driver veth, vxcan implements a
local CAN traffic tunnel between two virtual CAN network devices.
When creating a vxcan, two vxcan devices are created as pair
When one end receives the packet it appears on its pair and vice
versa. The vxcan can be used for cross namespace communication.
2017-11-22 08:23:22 +01:00
Zbigniew Jędrzejewski-Szmek
a217a4bcc5
Merge pull request #7395 from poettering/nametohandleat-loop
...
name_to_handle_at() EOVERFLOW handling
2017-11-22 08:20:36 +01:00
Susant Sahani
5f04a209ea
networkd:DHCP-client ignore default route if classless static route is set ( #6885 )
...
According to RFC 3442:
If the DHCP server returns both a Classless Static Routes option and
a Router option, the DHCP client MUST ignore the Router option.
fixes #5695 .
2017-11-22 07:43:55 +01:00
Zbigniew Jędrzejewski-Szmek
ffb70e4424
Merge pull request #7381 from poettering/cgroup-unified-delegate-rework
...
Fix delegation in the unified hierarchy + more cgroup work
2017-11-22 07:42:08 +01:00
Zbigniew Jędrzejewski-Szmek
82a27ba821
Merge pull request #7389 from shawnl/warning
...
tree-wide: adjust fall through comments so that gcc is happy
2017-11-22 07:38:51 +01:00
Andrew Jeddeloh
b1b96380fe
README: add requirements for IPAddress{Allow,Deny} ( #7414 )
...
Document kernel options needed for IPAddress{Allow,Deny}.
2017-11-21 23:54:20 +01:00
Lennart Poettering
23209bcd37
test: fix UDEV-WANTS testcase for non-bash shells ( #7407 )
...
testsuite.sh uses "set -o pipefile", which is a bashism, hence use bash
to invoke the script.
2017-11-21 17:38:43 +01:00
longersson
fc696d52b9
Docs: Fix spelling and capitalization ( #7408 )
2017-11-21 14:37:16 +01:00
Zbigniew Jędrzejewski-Szmek
97279d8380
meson: "upgrade" -Wimplicit-fallthrough to 5
...
5 means that only the explicit attribute introduced in previous commit
is accepted. We don't want the comments anymore.
2017-11-21 12:47:51 +01:00
jobol
37ac2744cc
core/exec: Restore SmackProcessLabel setting ( #7378 )
...
Smack LSM needs the capability CAP_MAC_ADMIN to allow
setting of the current Smack exec label. Consequently,
dropping capabilities must be done after changing the
current exec label.
This is only related to Smack LSM. But for clarity and
regularity, all setting of security context moved before
dropping capabilities.
See Issue 7108
2017-11-21 12:01:13 +01:00
Lennart Poettering
54c552eae6
Merge pull request #7335 from poettering/dissect-meta-info
...
beef up image dissection, to gather image metadata
2017-11-21 11:58:31 +01:00
Lennart Poettering
0b0c55fafd
Merge pull request #7363 from poettering/success-action
...
Generalize FailureAction=, and add SuccessAction=
2017-11-21 11:57:42 +01:00
Susant Sahani
8ad93cacf0
networkd: cleanup do not call link_enter_set_routes after label is set. ( #6935 )
...
Remove link_enter_set_routes after label is set.
2017-11-21 11:54:14 +01:00
Lennart Poettering
e7266e98f9
test: fix UDEV-WANTS testcase for non-bash shells
...
testsuite.sh uses "set -o pipefile", which is a bashism, hence use bash
to invoke the script.
2017-11-21 11:54:08 +01:00