1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-03-10 00:58:20 +03:00

49362 Commits

Author SHA1 Message Date
Alan Perry
8db704b28b no blkid for mmcblk[0-9]boot[0-9]
Don't run blkid on mmcblk[0-9]boot[0-9] devices because they contain
bootloaders or boot parameters, and not partitions or file systems.
2021-02-13 10:38:29 +01:00
Zbigniew Jędrzejewski-Szmek
b3c57df0f5
Merge pull request #18401 from anitazha/oomdxattr
oomd: implement avoid/omit support for cgroups
2021-02-13 10:00:31 +01:00
Nick
7253850abf Added Trekstor Yourbook C11B to 60-sensor.hwdb
Added the Trekstor Yourbook C11B which is equivalent to Trekstor Primebook C11B.
2021-02-13 17:47:25 +09:00
Lennart Poettering
3ec2f7f2e3 udev: make net_setup_link builtin quiet when link vanishes while we operate on it
Fixes: #16175
2021-02-13 17:46:56 +09:00
Lennart Poettering
6b10a2e030 core: slightly improve error message on load errors
Let's be a bit more helpful when refusing jobs on units that failed to
load properly. We already have explicit D-Bus errors for the error
conditions that are common and expected (such as "not found"), but for
the rest we so far generate a fairly cryptic message.

Let's try to be friendlier towards users and suggest what to do on such
errors.

Fixes: #16487
2021-02-13 17:46:39 +09:00
Yu Watanabe
9ae4f96056
Merge pull request #18555 from yuwata/network-address-set-flag-on-remove
network: address: also set IFA_FLAGS on remove
2021-02-13 17:44:58 +09:00
Yu Watanabe
b2af6d66fb
Merge pull request #18455 from yuwata/network-change-link-state-only-when-new-address-or-route-will-be-assigned
network: change link state only when new address or route will be assigned
2021-02-13 17:43:27 +09:00
Luca Boccassi
9ba008cbc3 NEWS: mention new systemctl verb and fix typo 2021-02-13 08:41:13 +09:00
Anita Zhang
d8a4d64bc3 man: document ManagedOOMPreference= 2021-02-12 12:46:22 -08:00
Anita Zhang
4e806bfa9f oom: add unit file settings for oomd avoid/omit xattrs 2021-02-12 12:45:36 -08:00
Lennart Poettering
199d251b72
Merge pull request #18568 from keszybz/v248-prep
Start preparing for v238-rc1
2021-02-12 21:43:31 +01:00
Lennart Poettering
73b6fc7770 resolved: never route DNSSEC traffic to LLMNR/mDNS
LLMNR/mDNS don't support DNSSEC, hence there's no point in routing any
lookups asking for DNSSEC there.

This speeds up looking up DNSSEC RRs for top-level domains, since we
don't have to wait for LLMNR to complete.
2021-02-12 21:41:01 +01:00
Zbigniew Jędrzejewski-Szmek
6dd990f3dc NEWS: start preparing for v248 2021-02-12 18:51:27 +01:00
Zbigniew Jędrzejewski-Szmek
b1b0cd3920 hwdb: update for v248
As usual, it seems to be additions and updates, no major removals.
2021-02-12 18:51:27 +01:00
Zbigniew Jędrzejewski-Szmek
b85ee926a8 syscall-tables: add missing preposition and fix file name path
I added an extension in 1f6f8cc8039a204609ddab79791ef22ee6340da0 but
forgot to fix the consumer script.
2021-02-12 18:51:27 +01:00
Lennart Poettering
e7a8f6b66f
Merge pull request #18558 from poettering/have-tpm2
ask the uefi firmware if TPM2 support is available
2021-02-12 15:49:20 +01:00
Yu Watanabe
4a70450104 test-network: merge test_address_static and test_address_preferred_lifetime_zero_ipv6 2021-02-12 23:09:21 +09:00
Yu Watanabe
53ae4762ef network: address: do not set IFA_F_PERMANENT flag
The flag is automatically set by kernel when the valid lifetime is
infinite. Note that the flag in netlink message for IPv4 address is
ignored. See set_ifa_lifetime() in kernel's net/ipv4/devinet.c.
But the flag is honored for IPv6 address. And if the flag is set with
finite valid lifetime, the address will not removed automatically by
the kernel.
2021-02-12 23:09:21 +09:00
Yu Watanabe
a8481354f0 network: address: also set IFA_FLAGS on remove
If an address is assigned with IFA_F_MANAGETEMPADDR, then the flag must
be also set on remove. Otherwise, temporary addresses will not be
removed. See also inet6_rtm_deladdr() in kernel's net/ipv6/addrconf.c.

Fixes #13218.
2021-02-12 23:09:21 +09:00
Yu Watanabe
111ce98419 network: dhcp6: change link state into "configuring" only when a new address or route will be assigned 2021-02-12 22:44:05 +09:00
Yu Watanabe
24b445c2ce network: ndisc: change link state into "configuring" only when a new address or route will be assigned 2021-02-12 22:44:05 +09:00
Yu Watanabe
b54aed29c6 network: dhcp6: fix condtion check 2021-02-12 22:43:39 +09:00
Yu Watanabe
0ef9f3c76f network: set return value at the end of the function
The later netlink_call_async() call may fail. We should not touch the
return value when the function failed.
2021-02-12 22:43:10 +09:00
Yu Watanabe
d9eee312a7 network: make address_configure() or friends return 1 when the address is new 2021-02-12 22:43:10 +09:00
Zbigniew Jędrzejewski-Szmek
e81fd9dd23
Merge pull request #18544 from yuwata/tree-wide-use-error-in-xxx_from_string
tree-wide: use error in xxx_from_string()
2021-02-12 12:16:23 +01:00
Yu Watanabe
0ef0c9caf7
Merge pull request #18554 from yuwata/network-address-set-NLM_F_REPLACE-flag-automatically
network: automatically set NLM_F_REPLACE flag
2021-02-12 13:47:58 +09:00
Lennart Poettering
537c10f937 condition: if spelunking through /sys/class/tpmrm doesn't work ask EFI if TPM2 exists
This makes ConditionSecurity=tpm2 work reliably during early boot: if
Linux doesn't know about the TPM2 then maybe the firmware does.
2021-02-11 23:12:46 +01:00
Lennart Poettering
b2a220492b bootctl: show whether the firmware has TPM2 support 2021-02-11 23:11:56 +01:00
Lennart Poettering
d0ddaf587f efi-loader: add efi_has_tpm2() helper
The helper checks if the UEFI firmware is hooked up to a TPM2 chip. This
is useful to know in trusted boot scenarios, in particular during early
boot in auto-enroll scenarios where we want to know whether TPM2 is
available or not, and the Linux drivers are not loaded yet, and where it
might or not be worth waiting for it.
2021-02-11 23:10:07 +01:00
Lennart Poettering
5b4c163002 efivars: debug log if we fail to detect whether /sys/firmware/efi/ exists 2021-02-11 23:09:54 +01:00
Yu Watanabe
b3f9c17a6b tree-wide: use free_and_strdup_warn() 2021-02-12 03:05:08 +09:00
Yu Watanabe
37c0b60177 network: automatically set NLM_F_REPLACE flag
The difference between sd_rtnl_message_new_addr() and
sd_rtnl_message_new_addr_update() is only whether NLM_F_REPLACE flag
will be set or not.

If an address is already assigned, then we need to set NLM_F_REPLACE
flag, otherwise, address_configure() will be fail.

This makes address_configure() judge whether we should use the flag or
not.
2021-02-12 01:50:14 +09:00
Yu Watanabe
fe44ce8dba network: address: also logs preferred lifetime 2021-02-12 01:49:59 +09:00
Yu Watanabe
7fb1d980af tree-wide: propagate error in xxx_from-string() 2021-02-12 01:19:18 +09:00
Yu Watanabe
bde8467a0d network: dhcp: use string table 2021-02-12 01:19:18 +09:00
Yu Watanabe
58f99ed8a8 string-table: introduce DEFINE_STRING_TABLE_LOOKUP_FROM_STRING() 2021-02-12 01:19:18 +09:00
Yu Watanabe
e4ffe10367 network: route: use _WITH_FALLBACK macros 2021-02-12 01:19:18 +09:00
Yu Watanabe
0fcc4e7484 networkd: lldp: use string table 2021-02-12 01:19:13 +09:00
Yu Watanabe
641bcbc56b string-table: introduce DEFINE_PRIVATE_STRING_TABLE_LOOKUP_FROM_STRING_WITH_BOOLEAN() 2021-02-12 01:17:13 +09:00
Yu Watanabe
b98680b2b8 tree-wide: use error codes in xxx_from_string() 2021-02-12 01:17:13 +09:00
Yu Watanabe
0cbb768aba conf-parser: use return codes in xxx_from_string()
Follow-up for #11484.
2021-02-12 01:17:06 +09:00
Luca Boccassi
1c3c43a417
Merge pull request #18550 from keszybz/coverity-inspired-fixes
Coverity inspired fixes
2021-02-11 15:44:25 +00:00
Zbigniew Jędrzejewski-Szmek
aaf73b2ecf
Merge pull request #17902 from bugaevc/fix-container-detection
improve container detection
2021-02-11 12:56:01 +01:00
Zbigniew Jędrzejewski-Szmek
a4aa5742f7 homework: fix unitialized variable
Coverity CID#1444703.
2021-02-11 12:00:09 +01:00
Zbigniew Jędrzejewski-Szmek
78b4e9ed17 homework: reduce scope of iterator variables 2021-02-11 11:59:22 +01:00
Zbigniew Jędrzejewski-Szmek
0eacd1852a basic/locale-util: reduce variable scope 2021-02-11 09:55:01 +01:00
Zbigniew Jędrzejewski-Szmek
333ab199a1 fsck: make sure we don't read an unitialized variable
This use on %n was completely unnecessary: fprintf returns the number of
characters written. And the issue was that if fprintf failed for whatever
reason, it would not process the %n and m would be unitialized. Rework the
code a bit to simplify it.

Coverity CID#1444708.
2021-02-11 09:50:49 +01:00
Zbigniew Jędrzejewski-Szmek
363729c470 sd-journal: add forgotten unmap in error path
Bug introduced in 4b5bc5396c090ee41c45cab9052372d296c4a2f4 :(

Coverity CID#1444709.
2021-02-11 09:35:52 +01:00
Zbigniew Jędrzejewski-Szmek
47237e0ed4 shared/generator: add missing initializer
Coverity CID#1444710.
2021-02-11 09:23:22 +01:00
Zbigniew Jędrzejewski-Szmek
b5f1c0d88b udev: add assert to make coverity happy
Coverity says:
CID 1446387 (#1 of 1): Bad bit shift operation (BAD_SHIFT)
8. negative_shift: In expression 1U << (int)cmd, shifting by a negative amount
has undefined behavior. The shift amount, cmd, is -22.

I don't think there's any issue, unless we forget to set token->data
appropriately. Let's add an assert.
2021-02-11 09:17:46 +01:00