Lennart Poettering [Wed, 11 Nov 2020 16:38:21 +0000 (17:38 +0100)]
resolved: never allow _gateway lookups to go to the network
Make them rather fail than go to the network.
Previously we'd filter them on LLMNR (explicitly) and MDNS (implicitly,
because it doesn't have .local suffix), but not on DNS.
In order to make _gateway truly reliable, let's not allow it to go to
DNS either, and keep it local.
This is particular relevant, as clients can now request lookups without
local RR synthesis, where we'd rather have NXDOMAIN returned for
_gateway than have it hit the network.
(cherry picked from commit
fbbc72189f7844df8500bb10a58988f70bf90c99)
Lennart Poettering [Thu, 12 Nov 2020 16:52:09 +0000 (17:52 +0100)]
resolved: lower SERVFAIL cache timeout from 30s to 10s
Apparently 30s is a bit too long for some cases, see #5552. But not
caching SERVFAIL at all also breaks stuff, see explanation in
201d99584ed7af8078bb243ce2587e5455074713.
Let's try to find some middle ground, by lowering the cache timeout to
10s. This should be ample for the problem
201d99584ed7af8078bb243ce2587e5455074713 attackes, but not as long as
half a miute, as #5552 complains.
Fixes: #5552
(cherry picked from commit
19bcef9dc3fde342f138394333ab04d7e44b7da2)
Lennart Poettering [Mon, 9 Nov 2020 22:10:43 +0000 (23:10 +0100)]
dns-domain: try IDN2003 rules if IDN2008 doesn't work
This follows more closely what web browsers do, and makes sure emojis in
domains work.
Fixes: #14483
(cherry picked from commit
d80e72ec602c2af2983842ad87e4443fce89d423)
Christopher Obbard [Wed, 2 Dec 2020 14:20:39 +0000 (14:20 +0000)]
virt: Properly detect nested UML inside another hypervisor
UML runs as a user-process so it can quite easily be ran inside of
another hypervisor, for instance inside a KVM instance. UML passes
through the CPUID from the host machine so in this case detect_vm
incorrectly identifies as running under KVM. So check we are running
a UML kernel first, before we check any other hypervisors.
Resolves: #17754
Signed-off-by: Christopher Obbard <chris.obbard@collabora.com>
(cherry picked from commit
c8037dbf05da586b6a210ac04f145d99f424971f)
Lennart Poettering [Tue, 17 Nov 2020 17:31:53 +0000 (18:31 +0100)]
resolved: properly check per-link NTA list
We need to check for parent domains too. We did this correctly for the
system-wide NTA list, but not for the per-link one. Let's fix that.
(cherry picked from commit
7e8a93b77c3c4d4df1e8c3177dc9553c94fac759)
Yu Watanabe [Wed, 2 Dec 2020 09:05:06 +0000 (18:05 +0900)]
Lennart Poettering [Wed, 4 Nov 2020 15:23:11 +0000 (16:23 +0100)]
man: mention that --key= is about *secret* keys
(cherry picked from commit
ce82de671f63105e9839978b432e2b015783ffc0)
Luca Boccassi [Thu, 3 Dec 2020 16:17:43 +0000 (16:17 +0000)]
meson: check that cxx variable is set before using it
In some cases it is not defined. Eg in a yocto build:
src/systemd/meson.build:61:15: ERROR: Unknown variable cxx.
(cherry picked from commit
442bc2afee6c5f731c7b3e76ccab7301703a45a7)
Franck Bui [Mon, 30 Nov 2020 14:26:15 +0000 (15:26 +0100)]
scope: on unified, make sure to unwatch all PIDs once they've been moved to the cgroup scope
Commit
428a9f6f1d0396b9eacde2b38d667cbe3f15eb55 freed u->pids which is
problematic since the references to this unit in m->watch_pids were no more
removed when the unit was freed.
This patch makes sure to clean all this refs up before freeing u->pids by
calling unit_unwatch_all_pids().
(cherry picked from commit
e9eec8b5d2c106c5dd51382a155e6045c7c17c1a)
Vito Caputo [Tue, 1 Dec 2020 08:26:54 +0000 (00:26 -0800)]
sd-event: fix delays assert brain-o (#17790)
s/sizeof/ELEMENTSOF/
Bug introduced in
34b87517749caa4142b19eb3c63bdf349fafbc49.
(cherry picked from commit
cb9d621ebbfa30bbd620c17e143daeb0d78c12f0)
Piotr Drąg [Sat, 28 Nov 2020 12:43:52 +0000 (13:43 +0100)]
po: add units/systemd-journald.service.in to POTFILES.skip
(cherry picked from commit
a75471ced1b4527870e21e96fbb81017e76fbcc8)
Zbigniew Jędrzejewski-Szmek [Sat, 28 Nov 2020 10:27:31 +0000 (11:27 +0100)]
test-networkd-conf: add missing assert_se
Coverity CID#
1437351. Fixup for
f706340979a.
(cherry picked from commit
78cafcbc7ec7eb19d40a07dfa75ad562f7ded643)
Zbigniew Jędrzejewski-Szmek [Fri, 27 Nov 2020 11:51:48 +0000 (12:51 +0100)]
NEWS: really fix kernel version number reference
Fixes #17736.
(cherry picked from commit
832eedd192deb4e3520deb6a62c9acae23541b67)
Christian Hesse [Thu, 26 Nov 2020 20:29:30 +0000 (21:29 +0100)]
oom: fix oomd.conf install location
The file is read in pkgsysconfdir, so install it there.
Christian Hesse [Thu, 26 Nov 2020 20:22:41 +0000 (21:22 +0100)]
home: fix homed.conf install location
The install location changed in
d7aa78c32f076c305ceeb183fc06eb1de0960deb,
I think this was not intentional. Keep the condition but revert the path.
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 18:00:50 +0000 (19:00 +0100)]
Merge pull request #17738 from keszybz/hwdb-news-update-v247
Update hwdb and news for v247
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 10:23:54 +0000 (11:23 +0100)]
shared/seccomp-util: address family filtering is broken on ppc
This reverts the gist of
da1921a5c396547261c8c7fcd94173346eb3b718 and
0d9fca76bb69e162265b2d25cb79f1890c0da31b (for ppc).
Quoting #17559:
> libseccomp 2.5 added socket syscall multiplexing on ppc64(el):
> https://github.com/seccomp/libseccomp/pull/229
>
> Like with i386, s390 and s390x this breaks socket argument filtering, so
> RestrictAddressFamilies doesn't work.
>
> This causes the unit test to fail:
> /* test_restrict_address_families */
> Operating on architecture: ppc
> Failed to install socket family rules for architecture ppc, skipping: Operation canceled
> Operating on architecture: ppc64
> Failed to add socket() rule for architecture ppc64, skipping: Invalid argument
> Operating on architecture: ppc64-le
> Failed to add socket() rule for architecture ppc64-le, skipping: Invalid argument
> Assertion 'fd < 0' failed at src/test/test-seccomp.c:424, function test_restrict_address_families(). Aborting.
>
> The socket filters can't be added so `socket(AF_UNIX, SOCK_DGRAM, 0);` still
> works, triggering the assertion.
Fixes #17559.
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 13:01:09 +0000 (14:01 +0100)]
NEWS: fix kernel version number reference
Fixes #17736.
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 12:45:06 +0000 (13:45 +0100)]
NEWS: version 247
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 12:54:08 +0000 (13:54 +0100)]
hwdb: update chromiumos autosuspend rules
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 12:53:03 +0000 (13:53 +0100)]
hwdb: update for v247
Only some small changes, because we updated recently. As usual, it seems that there are mostly
additions with a smaller amount of corrections, no big removals.
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 12:48:35 +0000 (13:48 +0100)]
docs/RELEASE: clarify which steps are done when
Dan Streetman [Wed, 25 Nov 2020 20:22:24 +0000 (15:22 -0500)]
test: use cap_last_cap() for max supported cap number, not capability_list_length()
This test assumes capability_list_length() is an invalid cap number,
but that isn't true if the running kernel supports more caps than we were
compiled with, which results in the test failing.
Instead use cap_last_cap() + 1.
If cap_last_cap() is 63, there are no more 'invalid' cap numbers to test with,
so the invalid cap number test part is skipped.
Whired Planck [Thu, 26 Nov 2020 11:35:55 +0000 (12:35 +0100)]
Translated using Weblate (Chinese (Simplified))
Currently translated at 83.9% (157 of 187 strings)
Co-authored-by: Whired Planck <fungdaat31@outlook.com>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/zh_CN/
Translation: systemd/master
Zbigniew Jędrzejewski-Szmek [Thu, 26 Nov 2020 11:48:05 +0000 (12:48 +0100)]
Merge pull request #17622 from yuwata/udev-database-set-udev-version
sd-device: make sd_device_has_current_tag() compatible with udev database generated by older udevd
Lee Whalen [Thu, 26 Nov 2020 04:31:47 +0000 (20:31 -0800)]
add touchpad-edge-detect output for the Lenovo Thinkpad Extreme to evdev.hwdb
Yu Watanabe [Thu, 26 Nov 2020 00:31:10 +0000 (09:31 +0900)]
Merge pull request #17709 from yuwata/test-seccomp-skip
test: skip several tests in test-seccomp when running under valgrind or ASAN
Yu Watanabe [Mon, 16 Nov 2020 10:47:42 +0000 (19:47 +0900)]
sd-device: make sd_device_has_current_tag() and friends compatible with database version 0
Yu Watanabe [Wed, 25 Nov 2020 21:23:14 +0000 (06:23 +0900)]
sd-device: introduce database version and save it in udev database V field
Yu Watanabe [Mon, 16 Nov 2020 10:28:40 +0000 (19:28 +0900)]
sd-device: make device_add_property_internal() inline
Yu Watanabe [Wed, 25 Nov 2020 13:20:48 +0000 (22:20 +0900)]
man: slightly update the man page of sd_bus_message_read_basic()
Follow-up for
73a1d7d2433edd1872ec53db3e804009298ebb1d.
igo95862 [Wed, 25 Nov 2020 13:15:33 +0000 (16:15 +0300)]
man: Fixed an incomplete sentence
igo95862 [Wed, 25 Nov 2020 12:53:52 +0000 (15:53 +0300)]
man: Specify that sd_bus_message_read_basic returns 0 if end of array had been reached.
Lennart Poettering [Fri, 20 Nov 2020 11:33:16 +0000 (12:33 +0100)]
docs: document what VPNs should do to systemd-resolved.service
Fixes: #17588 #17512
Prompted-by: #17529
(Also relevant: #6076)
Yu Watanabe [Tue, 17 Nov 2020 00:13:59 +0000 (09:13 +0900)]
core/mount: mount command may fail after adding the corresponding proc mountinfo entry
Hopefully fixes #17617.
Zbigniew Jędrzejewski-Szmek [Wed, 25 Nov 2020 12:22:56 +0000 (13:22 +0100)]
Merge pull request #17715 from yuwata/specifier-follow-ups
Sort specifiers
Lennart Poettering [Tue, 24 Nov 2020 12:56:48 +0000 (13:56 +0100)]
cryptsetup: use log_warning_errno() where we can, instead of log_warning()
Zbigniew Jędrzejewski-Szmek [Wed, 25 Nov 2020 12:20:42 +0000 (13:20 +0100)]
Merge pull request #17721 from poettering/more-strjoin-cryptsetup
two minor fixes/clean-ups
Lennart Poettering [Tue, 17 Nov 2020 17:35:08 +0000 (18:35 +0100)]
mkosi: make sure our mkosi files work with f33
Yu Watanabe [Tue, 24 Nov 2020 12:07:42 +0000 (21:07 +0900)]
test: skip several tests in test-seccomp when running on asan
Yu Watanabe [Tue, 24 Nov 2020 11:58:07 +0000 (20:58 +0900)]
test: skip several tests in test-seccomp when running on valgrind
Pavel Sapezhko [Wed, 18 Nov 2020 14:54:01 +0000 (17:54 +0300)]
man: clarify DefaultTasksMax doc
Lennart Poettering [Wed, 25 Nov 2020 10:20:38 +0000 (11:20 +0100)]
units: typo fix /proc/<pid>/exec → /proc/<pid>/exe
Fix a pretty relevant typo introduced in
c7faa23235694a1e803ba093cba6d6e0193a093e.
Lennart Poettering [Wed, 4 Nov 2020 17:14:54 +0000 (18:14 +0100)]
cryptsetup: use strjoin() for concatenating strings
Franck Bui [Wed, 25 Nov 2020 08:47:46 +0000 (09:47 +0100)]
units: document why CAP_SYS_PTRACE is needed by journald
Yu Watanabe [Wed, 25 Nov 2020 04:50:58 +0000 (13:50 +0900)]
tree-wide: fix typo
Yu Watanabe [Wed, 25 Nov 2020 06:09:17 +0000 (15:09 +0900)]
tree-wide: sort specifiers and move common comments to specifier.h
Yu Watanabe [Wed, 25 Nov 2020 05:39:10 +0000 (14:39 +0900)]
man: sort specifiers alphabetically
Yu Watanabe [Wed, 25 Nov 2020 05:38:50 +0000 (14:38 +0900)]
man: add missing specifiers supported in [INSTALL] section
Lennart Poettering [Fri, 20 Nov 2020 14:15:24 +0000 (15:15 +0100)]
specifiers: introduce common macros for generating specifier tables
In many cases the tables are largely the same, hence define a common set
of macros to generate the common parts.
This adds in a couple of missing specifiers here and there, so is more
thant just refactoring: it actually fixes accidental omissions.
Note that some entries that look like they could be unified under these
macros can't really be unified, since they are slightly different. For
example in the DNSSD service logic we want to use the DNSSD hostname for
%H rather than the unmodified kernel one.
Michael Biebl [Tue, 24 Nov 2020 20:45:12 +0000 (21:45 +0100)]
Merge pull request #17706 from ddstreet/test-move-pam-systemd-user
test/test-functions: copy /usr/lib/pam.d into $initdir
Lennart Poettering [Tue, 24 Nov 2020 15:07:39 +0000 (16:07 +0100)]
NEWS: mention that we intend to retrigger udev devices on package upgrade
Also, mention RISCV GPT partition types have been defined.
Christoph Ruegge [Mon, 23 Nov 2020 17:06:36 +0000 (18:06 +0100)]
pam_systemd_home: export password as PAM_AUTHTOK
Lennart Poettering [Tue, 24 Nov 2020 16:42:45 +0000 (17:42 +0100)]
Merge pull request #17680 from yuwata/udev-link-mac-address
udev: to make MACAddress= take effect, MACAddressPolicy= must be "none"
Yu Watanabe [Tue, 24 Nov 2020 09:47:37 +0000 (18:47 +0900)]
seccomp: also move munmap into @default syscall filter set
Follow-up for
5abede3247591248718026cb8be6cd231de7728b.
INSUN PYO [Thu, 19 Nov 2020 01:49:04 +0000 (10:49 +0900)]
sd-device-enumerator: do not return error when a device is removed
If /sys/class/OOO node is created and destroyed during booting (kernle driver initialization fails),
systemd-udev-trigger.service fails due to race condition.
***** race condition ***********************************************************************************
1. kernel driver create /sys/class/OOO
2. systemd-udev-trigger.service execues "/usr/bin/udevadm trigger --type=devices --action=add"
3. device_enumerator_scan_devices() => enumerator_scan_devices_all() => enumerator_scan_dir("class") =>
opendir("/sys/class") and iterate all subdirs ==> enumerator_scan_dir_and_add_devices("/sys/class/OOO")
4. kernel driver fails and destroy /sys/class/OOO
5. enumerator_scan_dir_and_add_devices("/sys/class/OOO") fails in opendir("/sys/class/OOO")
6. "systemd-udev-trigger.service" fails
7. udev coldplug fails and some device units not ready
8. mount units asociated with device units fail
9. local-fs.target fails
10. enters emergency mode
********************************************************************************************************
***** status of systemd-udev-trigger.service unit ******************************************************
$ systemctl status systemd-udev-trigger.service
systemd-udev-trigger.service - udev Coldplug all Devices
Loaded: loaded (/usr/lib/systemd/system/systemd-udev-trigger.service; static; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2020-01-02 13:16:54 KST; 22min ago
Docs: man:udev(7)
man:systemd-udevd.service(8)
Process: 2162 ExecStart=/usr/bin/udevadm trigger --type=subsystems --action=add (code=exited, status=0/SUCCESS)
Process: 2554 ExecStart=/usr/bin/udevadm trigger --type=devices --action=add (code=exited, status=1/FAILURE)
Main PID: 2554 (code=exited, status=1/FAILURE)
Jan 02 13:16:54 localhost udevadm[2554]: Failed to scan devices: No such file or directory
Jan 02 13:16:54 localhost systemd[1]: systemd-udev-trigger.service: Main process exited, code=exited, status=1/FAILURE
Jan 02 13:16:54 localhost systemd[1]: systemd-udev-trigger.service: Failed with result 'exit-code'.
Jan 02 13:16:54 localhost systemd[1]: Failed to start udev Coldplug all Devices.
*******************************************************************************************************
***** journal log with Environment=SYSTEMD_LOG_LEVEL=debug in systemd-udev-trigger.service ***********
Jan 01 21:57:20 localhost udevadm[2039]: sd-device-enumerator: Scanning /sys/bus
Jan 01 21:57:20 localhost udevadm[2522]: sd-device-enumerator: Scan all dirs
Jan 01 21:57:20 localhost udevadm[2522]: sd-device-enumerator: Scanning /sys/bus
Jan 01 21:57:21 localhost udevadm[2522]: sd-device-enumerator: Scanning /sys/class
Jan 01 21:57:21 localhost udevadm[2522]: sd-device-enumerator: Failed to scan /sys/class: No such file or directory
Jan 01 21:57:21 localhost udevadm[2522]: Failed to scan devices: No such file or directory
*******************************************************************************************************
Yu Watanabe [Fri, 20 Nov 2020 09:25:06 +0000 (18:25 +0900)]
kernel-install: drop redundant "/"
Follow-up for
1cdbff1c844ce46f1d84d8feeed426ebfd550988.
After the commit
1cdbff1c844ce46f1d84d8feeed426ebfd550988, each entry .conf contains
redundant slash like the following:
```
$ cat xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx-5.9.8-200.fc33.x86_64.conf
title Fedora 33 (Thirty Three)
version 5.9.8-200.fc33.x86_64
machine-id xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
options root=/dev/nvme0n1p2 ro rootflags=subvol=system/fedora selinux=0 audit=0
linux //xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/5.9.8-200.fc33.x86_64/linux
initrd //xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/5.9.8-200.fc33.x86_64/initrd
```
Yu Watanabe [Fri, 20 Nov 2020 09:43:13 +0000 (18:43 +0900)]
man: bootctl set-default/oneshot accept an empty string
Frantisek Sumsal [Thu, 29 Oct 2020 14:29:29 +0000 (15:29 +0100)]
Revert "semaphore: temporarily explicitly use the US image mirror"
This reverts commit
9ac47d926146ed177aef805bba75f07bd3ed8643.
Dan Streetman [Fri, 20 Nov 2020 18:41:03 +0000 (13:41 -0500)]
test/test-functions: copy /usr/lib/pam.d into $initdir
The systemd-user file has been moved from /etc/pam.d into /usr/lib/pam.d,
so test-functions needs to copy it from /usr/lib/pam.d instead.
This will copy it from either location.
Yu Watanabe [Fri, 20 Nov 2020 08:16:44 +0000 (17:16 +0900)]
unit: update comment about OOM score
Follow-up for
6b2229c6c60d0486f5eb9ed3088f9c780d7c0233.
Lennart Poettering [Mon, 23 Nov 2020 21:19:52 +0000 (22:19 +0100)]
Merge pull request #17669 from yuwata/coccinelle-update
tree-wide: shorten code a bit suggested by coccinelle
Lennart Poettering [Mon, 23 Nov 2020 21:18:28 +0000 (22:18 +0100)]
Merge pull request #17676 from yuwata/lgtm-fixes
tree-wide: several fixes prompted by LGTM
Dimitri John Ledkov [Mon, 23 Nov 2020 14:31:07 +0000 (14:31 +0000)]
gpt: add RISC-V GPT partition typecode uuid
Etienne Doms [Fri, 20 Nov 2020 16:15:25 +0000 (17:15 +0100)]
curl-util: fix callback prototype
CURLMOPT_SOCKETFUNCTION callback is an easy handle, not a multi.
Lennart Poettering [Mon, 23 Nov 2020 13:36:05 +0000 (14:36 +0100)]
Merge pull request #17685 from yuwata/curl-no-oldies
meson: set CURL_NO_OLDIES in developer mode
Lennart Poettering [Mon, 23 Nov 2020 13:35:36 +0000 (14:35 +0100)]
Merge pull request #17687 from yuwata/use-localtime_or_gmtime_r
use localtime_or_gmtime_r()
Yu Watanabe [Mon, 23 Nov 2020 07:17:04 +0000 (16:17 +0900)]
backlight: add several debug logs and adjust log level of non critical error
This may help to investigate issues.
Jörg Thalheim [Sat, 14 Nov 2020 13:50:39 +0000 (14:50 +0100)]
networkd/dhcp6: allow layer3 devices without MAC
Devices with multicast but without mac addresses i.e. tun devices
are not getting setuped correctly:
$ ip tuntap add mode tun dev tun0
$ ip addr show tun0
16: tun0: <NO-CARRIER,POINTOPOINT,MULTICAST,NOARP,UP> mtu 1500 qdisc fq_codel state DOWN group default qlen 500
link/none
$ cat /etc/systemd/network/tun0.network
[Match]
Name = tun0
[Network]
Address=192.168.1.1/32
$ ./systemd-networkd
tun0: DHCP6 CLIENT: Failed to set identifier: Invalid argument
tun0: Failed
vanou [Mon, 23 Nov 2020 12:21:46 +0000 (21:21 +0900)]
man: Fix misspelling of directive and typos in systemd-coredump man page
This commit fixes
* misspelling of LimitCORE directive of systemd.exec
* typos
in systemd-coredump man page.
Jérémy Nouhaud [Sun, 22 Nov 2020 23:30:08 +0000 (00:30 +0100)]
hwdb: set fuzz value for lenovo x240 touchpad to improve cursor precision (#17659)
Yu Watanabe [Fri, 20 Nov 2020 19:38:41 +0000 (04:38 +0900)]
logs-show: use localtime_or_gmtime_r()
Yu Watanabe [Fri, 20 Nov 2020 19:28:45 +0000 (04:28 +0900)]
timedate: use localtime_or_gmtime_r() and mktime_or_timegm()
Yu Watanabe [Fri, 20 Nov 2020 16:52:47 +0000 (01:52 +0900)]
meson: set CURL_NO_OLDIES in developer mode
Yu Watanabe [Fri, 20 Nov 2020 16:51:03 +0000 (01:51 +0900)]
curl-util: fix type CURL -> CURLM
Franck Bui [Fri, 20 Nov 2020 10:52:36 +0000 (11:52 +0100)]
units: restore sysfs conditions in sys-fs-fuse-connections.mount and sys-kernel-config.mount
Commit
42cc2855ba2fe4c6f5d incorrectly removed the condition on sysfs in both
sys-fs-fuse-connections.mount and sys-kernel-config.mount. However there are
still needed in case modprobe of one of these modules is intentionally skipped
(due to lack of privs for example).
This patch restores the 2 conditions which should be safe for the common case,
since all conditions are only checked after all deps ordered before are
complete.
Follow-up for
42cc2855ba2fe4c6f5dc863507a1c843611350a0.
Yu Watanabe [Tue, 17 Nov 2020 01:50:12 +0000 (10:50 +0900)]
core/mount: mount_start() may be called during the state is MOUNT_MOUNTING_DONE
As, both MOUNT_MOUNTING and MOUNT_MOUNTING_DONE are mapped to
UNIT_ACTIVATING.
Fixes #17570.
Franck Bui [Mon, 16 Nov 2020 14:12:21 +0000 (15:12 +0100)]
core: serialize u->pids until the processes have been moved to the scope cgroup
Otherwise if a daemon-reload happens somewhere between the enqueue of the job
start for the scope unit and scope_start() then u->pids might be lost and none
of the processes specified by "PIDs=" will be moved into the scope cgroup.
Yu Watanabe [Fri, 20 Nov 2020 13:43:45 +0000 (22:43 +0900)]
man: to make MACAddress= take effect, MACAddressPolicy= must be "none"
Yu Watanabe [Fri, 20 Nov 2020 13:58:23 +0000 (22:58 +0900)]
link-config: warn when MACAddress= is set with MACAddressPolicy=persistent or random
Yu Watanabe [Fri, 20 Nov 2020 13:48:59 +0000 (22:48 +0900)]
link-config: make MACAddressPolicy= accept an empty string
Lennart Poettering [Fri, 20 Nov 2020 13:56:59 +0000 (14:56 +0100)]
Merge pull request #17649 from yuwata/resolve-dnssd-template-name
resolve: ignore invalid service template name
Lennart Poettering [Fri, 20 Nov 2020 13:49:41 +0000 (14:49 +0100)]
Merge pull request #17658 from jwrdegoede/hwdb-accel-work
hwdb accel work
Yu Watanabe [Fri, 20 Nov 2020 10:50:33 +0000 (19:50 +0900)]
systemctl: fix potential pointer overflow
Yu Watanabe [Fri, 20 Nov 2020 10:47:11 +0000 (19:47 +0900)]
tools: drop unnecessary "else" after for loop
Yu Watanabe [Fri, 20 Nov 2020 10:42:38 +0000 (19:42 +0900)]
ask-passwd: drop a condition which is always false
Yu Watanabe [Fri, 20 Nov 2020 10:39:49 +0000 (19:39 +0900)]
resolvectl: drop a condition which is always true
Yu Watanabe [Thu, 19 Nov 2020 17:50:30 +0000 (02:50 +0900)]
pstore: use log_oom()
Yu Watanabe [Thu, 19 Nov 2020 17:47:06 +0000 (02:47 +0900)]
coccinelle: always use SYNTHETIC_ERRNO() macro
Yu Watanabe [Thu, 19 Nov 2020 17:35:24 +0000 (02:35 +0900)]
tree-wide: use return value of log_xxx_errno()
Yu Watanabe [Thu, 19 Nov 2020 17:34:48 +0000 (02:34 +0900)]
coccinelle: add one more rule to use return value of log_xxx_errno()
Lennart Poettering [Thu, 19 Nov 2020 10:14:41 +0000 (11:14 +0100)]
seccomp: move brk+mmap+mmap2 into @default syscall filter set
These three syscalls are internally used by libc's memory allocation
logic, i.e. ultimately back malloc(). Allocating a bit of memory is so
basic, it should just be in the default set.
This fixes a couple of issues with asan/msan and the seccomp tests: when
asan/msan is used some additional, large memory allocations take place
in the background, and unless mmap/mmap2/brk are allowlisted these will
fail, aborting the test prematurely.
Zbigniew Jędrzejewski-Szmek [Thu, 19 Nov 2020 15:35:32 +0000 (16:35 +0100)]
Merge pull request #17667 from fbuihuu/fix-module-loading-from-udev-rule
Fix module loading from udev rule
Lennart Poettering [Wed, 18 Nov 2020 12:47:43 +0000 (13:47 +0100)]
man: suffix settings name with = and enclose in <varname>
Franck Bui [Thu, 19 Nov 2020 08:17:19 +0000 (09:17 +0100)]
units: wait until some fs modules are entirely loaded before mounting their corresponding filesystem
udev requests to start the fs mount units when their respective module is
loaded. For that it monitors uevents of type "ADD" for the relevant fs modules.
However the uevent is sent by the kernel too early, ie before the init() of the
module is called hence before directories in /sys/fs/ are created.
This patch workarounds adds "Requires/After=modprobe@<fs-module>.service" to
the mount unit, which means that modprobe(8) will be called once the fs module
is announced to be loaded. This sounds pointless, but given that modprobe only
returns after the initialization of the module is complete, it should
workaround the issue.
As a side effect, the module will be automatically loaded if the mount unit is
started manually.
Fixes #17586.
Franck Bui [Thu, 19 Nov 2020 07:55:56 +0000 (08:55 +0100)]
Revert "units: skip modprobe@.service if the unit appears to be already loaded"
This reverts commit
9cbf1e58f9629af5c6b56777ee73dc6320306d6d.
The presence of /sys/module/%I directory can't be used to assert that the load
of a given module is complete and therefore the call to modprobe(8) can be
skipped. Indeed this directory is created before the init() function of the
module is called.
Users of modprobe@.service needs to be sure that once this service returns the
module is fully operational.
Hans de Goede [Wed, 18 Nov 2020 16:11:50 +0000 (17:11 +0100)]
hwdb: Add accel orientation quirk for Acer Aspire Switch 10 SW3-016 2-in-1
Add a quirk to fix the accelerometer orientation on the
Acer Aspire Switch 10 SW3-016 2-in-1.
Hans de Goede [Sun, 15 Nov 2020 10:23:04 +0000 (11:23 +0100)]
hwdb: Add accel orientation quirk for Voyo Winpad A15 tablet
Add a quirk to fix the accelerometer orientation on the
Voyo Winpad A15 tablet.
Hans de Goede [Sat, 14 Nov 2020 16:09:04 +0000 (17:09 +0100)]
hwdb: Add accel orientation quirk for Lenovo ThinkPad Yoga 11e 4th gen
Add a quirk to fix the accelerometer orientation on the Lenovo
ThinkPad Yoga 11e 4th gen 360 degree hinges 2-in-1.
Hans de Goede [Sat, 14 Nov 2020 16:10:51 +0000 (17:10 +0100)]
hwdb: Fix accel orientation quirk Z-axis for Lenovo ThinkPad Yoga 11e 3th gen
The Lenovo ThinkPad Yoga 11e 360 degree hinges style 2-in-1s use 2
accelerometers, 1 in the display and 1 in the base.
Kernel work is under way to also export the second accelerometer in
the base as an iio-device; and userspace work is underway to use
both accelerometers on 360 degree hinges style 2-in-1s (with 2 accels)
to figure out the angle between the 2 halves.
So far most orientation-matrix quirks have not cared much about the
Z-axis being correct, but in these 2 accelerometer setups getting
the Z-axis correct is important too.