Yu Watanabe [Sat, 1 Sep 2018 14:04:42 +0000 (23:04 +0900)]
core/umount: use structured initializers
Yu Watanabe [Tue, 28 Aug 2018 07:05:35 +0000 (16:05 +0900)]
tree-wide: replace device_enumerator_scan_devices()+FOREACH_DEVICE_AND_SUBSYSTEM() by FOREACH_DEVICE()
Yu Watanabe [Tue, 28 Aug 2018 07:05:20 +0000 (16:05 +0900)]
login/sysfs-show: use device_enumerator_get_devices()
Yu Watanabe [Tue, 28 Aug 2018 06:59:08 +0000 (15:59 +0900)]
sd-device: introduce device_enumerator_get_devices()
Yu Watanabe [Mon, 27 Aug 2018 06:35:45 +0000 (15:35 +0900)]
sd-device: make sd_device_enumerator_get_*_next() not destroy the list
Zbigniew Jędrzejewski-Szmek [Sun, 9 Sep 2018 19:01:17 +0000 (21:01 +0200)]
Merge pull request #10037 from filbranden/docs2
Moving docs around and starting conversion to Markdown
Filipe Brandenburger [Sat, 8 Sep 2018 20:55:09 +0000 (13:55 -0700)]
build-sys: Use common gcc argument detection for negative warning flags.
Starting with meson 0.46, it is able to detect these argument correctly.
See this commit in meson codebase for more details:
https://github.com/mesonbuild/meson/commit/
695b8f3a0377d3e2ce78ba8716adc365b18edea1
We already carry a requirement for meson_version : '>= 0.46', so we can be sure
our build system will include this commit.
Tested by building systemd using a cloned meson synced to the 0.46.0 tag,
confirmed the warnings were detected correctly in that case. The meson messages included this snippet:
> Compiler for C supports arguments -Wno-unused-parameter -Wunused-parameter: YES
> Compiler for C supports arguments -Wno-missing-field-initializers -Wmissing-field-initializers: YES
> Compiler for C supports arguments -Wno-unused-result -Wunused-result: YES
> Compiler for C supports arguments -Wno-format-signedness -Wformat-signedness: YES
> Compiler for C supports arguments -Wno-error=nonnull -Werror=nonnull: YES
> Compiler for C supports arguments -Wno-maybe-uninitialized -Wmaybe-uninitialized: YES
Zbigniew Jędrzejewski-Szmek [Sun, 9 Sep 2018 18:39:23 +0000 (20:39 +0200)]
Merge pull request #10042 from jwrdegoede/hwdb-sensors4
Hwdb sensors4
Hans de Goede [Fri, 7 Sep 2018 11:14:52 +0000 (13:14 +0200)]
hwdb: Add accelerometer orientation quirk for the Onda v975w tablet
Add accelerometer orientation quirk for the Onda v975w tablet.
Hans de Goede [Sat, 30 Jun 2018 19:56:59 +0000 (21:56 +0200)]
hwdb: Add accelerometer orientation quirk for the Connect Tablet9 tablet
Add accelerometer orientation quirk for the Connect Tablet9 tablet.
Hans de Goede [Sun, 20 May 2018 15:33:30 +0000 (17:33 +0200)]
hwdb: Add accelerometer orientation quirk for the HP Pavilion x2 - 10-n000nd
Add accelerometer orientation quirk for the HP Pavilion x2 - 10-n000nd 2-in-1.
Hans de Goede [Fri, 8 Jun 2018 07:29:09 +0000 (09:29 +0200)]
hwdb: Add accelerometer orientation quirk for the Chuwi Vi10 tablet
Add accelerometer orientation quirk for the Chuwi Vi10 (CWI505) tablet.
While at it also update the Chuwi Hi8 Pri comment to include the
CWI model-number.
Filipe Brandenburger [Fri, 7 Sep 2018 08:44:49 +0000 (01:44 -0700)]
docs: convert TRANSLATORS to Markdown
Also expand it to cover typical tasks of creating new translations, updating
existing ones and compiling them (which can be useful to check syntax.)
Filipe Brandenburger [Fri, 7 Sep 2018 08:22:34 +0000 (01:22 -0700)]
docs: convert DISTRO_PORTING to Markdown
Filipe Brandenburger [Fri, 7 Sep 2018 08:07:06 +0000 (01:07 -0700)]
docs: move markdown docs from .github/ to docs/
The GitHub guide on contributing file says: "Decide whether to store your
contributing guidelines in your repository's root, docs, or .github directory."
https://help.github.com/articles/setting-guidelines-for-repository-contributors/#adding-a-contributing-file
But there's really no advantage to keeping it in the hidden .github/, since
these are public and really belong together with the other documentation.
We can still keep the issue templates under .github/, since they are not really
documentation on their own.
Updated the links pointing to CONTRIBUTING.md to refer to the one in docs/.
Filipe Brandenburger [Fri, 7 Sep 2018 08:02:42 +0000 (01:02 -0700)]
docs: move doc/ to docs/
The docs/ directory is special in GitHub, since it can be used to serve GitHub
Pages from, so there's a benefit to switching to it in order to expose it
directly as a website.
Updated references to it from the documentations themselves, from the
CONTRIBUTING.md file and from Meson build files.
Zbigniew Jędrzejewski-Szmek [Sat, 8 Sep 2018 15:17:07 +0000 (17:17 +0200)]
Merge pull request #9832 from yuwata/fix-9831
network: fixes related to setting MTU
Zbigniew Jędrzejewski-Szmek [Sat, 8 Sep 2018 10:08:54 +0000 (12:08 +0200)]
Merge pull request #9942 from lucaswerkmeister/9939
seccomp: fix #9939 and allow specifying multiple errnos for syscall
Filipe Brandenburger [Thu, 6 Sep 2018 19:34:24 +0000 (12:34 -0700)]
build-sys: disable -Wmaybe-uninitialized
Compiler flag -Wmaybe-uninitialized is quite noisy and produces many false
positives, especially when optimization flags are enabled (tested gcc 8.2.1),
so let's just disable it in systemd build.
For example, with CFLAGS=-O2, the build produces 11 such warnings and the
default CFLAGS of Fedora's rpmbuild warns about it in 176 places. A look at a
sample of those shows that most are false positives, where the compiler just
can't figure it out correctly. (While fixing those would be nice, I'm not sure
it's a good use of our time.)
The noisy [-Wmaybe-uninitialized] warnings are not just an annoyance, since
they make it harder to spot warnings that indicate actual problems (such as
variable declared but not used.) Silencing those is beneficial, so that
contributors would see warnings where there are actually actionable problems,
so there's a better chance of having those issues addressed before a PR is
pushed.
Tested:
$ CFLAGS='-O2 -Wp,-D_FORTIFY_SOURCE=2' meson build/
$ ninja -C build/
(NOTE: -Wp,-D_FORTIFY_SOURCE=2 prevents [-Wstringop-truncation] warnings.)
With the commands above, the build will not produce any [-Wmaybe-uninitialized]
warnings (or any other warnings), which is not really the case before this commit.
Also tested with rpmbuild on Fedora, after this commit there are no warnings
produced in the build step.
Evgeny Vereshchagin [Fri, 7 Sep 2018 06:13:17 +0000 (06:13 +0000)]
tests: put fuzz_journald_processing_function in a .c file
Wyatt Ward [Sat, 8 Sep 2018 06:18:44 +0000 (02:18 -0400)]
hwdb: Add hwdb entry for X220 tablet (#10036)
Lucas Werkmeister [Wed, 29 Aug 2018 19:35:38 +0000 (21:35 +0200)]
seccomp: permit specifying multiple errnos for a syscall
If more than one errno is specified for a syscall in SystemCallFilter=,
use the last one instead of reporting an error. This is especially
useful when used with system call sets:
SystemCallFilter=@privileged:EPERM @reboot
This will block any system call requiring super-user capabilities with
EPERM, except for attempts to reboot the system, which will immediately
terminate the process. (@reboot is included in @privileged.)
This also effectively fixes #9939, since specifying different errnos for
“the same syscall” (same pseudo syscall number) is no longer an error.
Yu Watanabe [Wed, 5 Sep 2018 05:56:08 +0000 (14:56 +0900)]
gitignore: add nspawn image lock and mkosi temporary files
Yu Watanabe [Thu, 6 Sep 2018 02:58:29 +0000 (11:58 +0900)]
backlight: do not unref parent device
Fixes double-free introduced by
9aadd28149ae2d8ce9956495c961d97ba4033b0e.
Filipe Brandenburger [Fri, 7 Sep 2018 03:10:22 +0000 (20:10 -0700)]
po: update Brazilian Portuguese translation
Julian Andres Klode [Fri, 7 Sep 2018 14:39:44 +0000 (16:39 +0200)]
man: Document networkd states in networkctl(1) (#10033)
The manpage gives example outputs with the states, but it never
explains what the states are.
Fixes #575
Wyatt Ward [Fri, 7 Sep 2018 01:35:55 +0000 (21:35 -0400)]
hwdb: Added entry for X200 Tablet/X201 Tablet so their pointing sticks would be recognized. They share parts with normal X200 and X201's. (#10029)
Yu Watanabe [Wed, 5 Sep 2018 02:46:17 +0000 (11:46 +0900)]
Merge pull request #10009 from evverx/rework-journald-fuzzers
Add a fuzzer for server_process_native_message
Yu Watanabe [Fri, 24 Aug 2018 02:19:22 +0000 (11:19 +0900)]
sd-dhcp6: set requested time for DUID-LLT
Follow-up for
7e90a499ab1d5648c9169b5991b117d36fc59fad.
Yu Watanabe [Fri, 24 Aug 2018 02:14:32 +0000 (11:14 +0900)]
sd-dhcp: drop meaningless checking
mac_addr is not dynamically allocated.
Fixes CID 1395162 and 1395164.
Trevonn [Tue, 4 Sep 2018 16:47:08 +0000 (17:47 +0100)]
hwdb: add Logitech G703 Wired/Wireless (#10005)
Network Silence [Tue, 4 Sep 2018 16:46:07 +0000 (12:46 -0400)]
hwdb: Synaptics touchpad edge fix for HP Pavilion G6 (#10008)
Michal Sekletar [Thu, 30 Aug 2018 08:45:11 +0000 (08:45 +0000)]
cryptsetup-generator: introduce basic keydev support
Dracut has a support for unlocking encrypted drives with keyfile stored
on the external drive. This support is included in the generated initrd
only if systemd module is not included.
When systemd is used in initrd then attachment of encrypted drives is
handled by systemd-cryptsetup tools. Our generator has support for
keyfile, however, it didn't support keyfile on the external block
device (keydev).
This commit introduces basic keydev support. Keydev can be specified per
luks.uuid on the kernel command line. Keydev is automatically mounted
during boot and we look for keyfile in the keydev
mountpoint (i.e. keyfile path is prefixed with the keydev mount point
path). After crypt device is attached we automatically unmount
where keyfile resides.
Example:
rd.luks.key=
70bc876b-f627-4038-9049-
3080d79d2165=/key:LABEL=KEYDEV
Michael Biebl [Tue, 4 Sep 2018 14:18:02 +0000 (16:18 +0200)]
Merge pull request #10007 from keszybz/fix-no-logind
systemctl: fix compilation w/o logind
Zbigniew Jędrzejewski-Szmek [Tue, 4 Sep 2018 07:34:16 +0000 (09:34 +0200)]
systemctl: fix compilation w/o logind
Fixes #10006.
Dongsu Park [Mon, 3 Sep 2018 18:44:13 +0000 (20:44 +0200)]
importd, basic/string-util: use case-insensitive comparison for HTTP headers
According to RFC2616[1], HTTP header names are case-insensitive. So
it's totally valid to have a header starting with either `Date:` or
`date:`.
However, when systemd-importd pulls an image from an HTTP server, it
parses HTTP headers by comparing header names as-is, without any
conversion. That causes failures when some HTTP servers return headers
with different combinations of upper-/lower-cases.
An example:
https://alpha.release.flatcar-linux.net/amd64-usr/current/flatcar_developer_container.bin.bz2 returns `Etag: "pe89so9oir60"`,
while https://alpha.release.core-os.net/amd64-usr/current/coreos_developer_container.bin.bz2
returns `ETag: "
f03372edea9a1e7232e282c346099857"`.
Since systemd-importd expects to see `ETag`, the etag for the Container Linux image
is correctly interpreted as a part of the hidden file name.
However, it cannot parse etag for Flatcar Linux, so the etag the Flatcar Linux image
is not appended to the hidden file name.
```
$ sudo ls -al /var/lib/machines/
-r--r--r-- 1 root root
3303014400 Aug 21 20:07 '.raw-https:\x2f\x2falpha\x2erelease\x2ecore-os\x2enet\x2famd64-usr\x2fcurrent\x2fcoreos_developer_container\x2ebin\x2ebz2.\x22f03372edea9a1e7232e282c346099857\x22.raw'
-r--r--r-- 1 root root
3303014400 Aug 17 06:15 '.raw-https:\x2f\x2falpha\x2erelease\x2eflatcar-linux\x2enet\x2famd64-usr\x2fcurrent\x2fflatcar_developer_container\x2ebin\x2ebz2.raw'
```
As a result, when the Flatcar image is removed and downloaded again,
systemd-importd is not able to determine if the file has been already
downloaded, so it always download it again. Then it fails to rename it
to an expected name, because there's already a hidden file.
To fix this issue, let's introduce a new helper function
`memory_startswith_no_case()`, which compares memory regions in a
case-insensitive way. Use this function in `curl_header_strdup()`.
See also https://github.com/kinvolk/kube-spawn/issues/304
[1]: https://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.2
Liberasys [Mon, 3 Sep 2018 15:35:44 +0000 (17:35 +0200)]
man: fix a typo in the documentation (#10003)
Yu Watanabe [Mon, 3 Sep 2018 12:44:30 +0000 (21:44 +0900)]
Merge pull request #9919 from keszybz/more-sd-bus-doc
Some more sd-bus docs
Harald Hoyer [Mon, 3 Sep 2018 11:57:54 +0000 (13:57 +0200)]
boot/efi/stub.c: fix Dell LoadOptions
On Dell machines LoadOptions is filled with:
01 00 00 00 <name of BIOS Boot Loader Entry> ... <unknown bytes>
So, in case of meaningfull LoadOptions, better check if the first char
is a printable character.
Alan Jenkins [Mon, 3 Sep 2018 10:10:24 +0000 (11:10 +0100)]
user-runtime-dir: fix selinux regression
Fix #9993. When this code was split out to user-runtime-dir, it forgot to
include the call to mac_selinux_init(). So mkdir_label() stopped working.
Fixes:
a9f0f5e50104 ("logind: split %t directory creation to a helper
unit")
Yu Watanabe [Mon, 3 Sep 2018 09:39:56 +0000 (18:39 +0900)]
network: drop an unused variable
Follow-up for
53cb501a1314740fa777f145067cefccda954487.
Evgeny Vereshchagin [Sun, 2 Sep 2018 18:13:31 +0000 (18:13 +0000)]
tests: add reproducers for several issues uncovered with fuzz-journald-syslog
This is a follow-up to
a70f343cacf03ac51cdefb0d2e.
Zbigniew Jędrzejewski-Szmek [Mon, 3 Sep 2018 12:06:41 +0000 (14:06 +0200)]
Merge pull request #9995 from yuwata/fix-usbffs
core/socket: fix memleak in the error paths in usbffs_dispatch_eps()
Evgeny Vereshchagin [Mon, 3 Sep 2018 07:05:48 +0000 (07:05 +0000)]
tests: add a fuzzer for server_process_native_message
Evgeny Vereshchagin [Mon, 3 Sep 2018 07:03:10 +0000 (07:03 +0000)]
journald: make server_process_native_message compatible with fuzz_journald_processing_function
Evgeny Vereshchagin [Mon, 3 Sep 2018 06:46:24 +0000 (06:46 +0000)]
tests: rework the code fuzzing journald
This should make it easier to add a new fuzzer without a lot of
duplication.
Yu Watanabe [Mon, 3 Sep 2018 05:22:08 +0000 (14:22 +0900)]
core/socket: fix memleak in the error paths in usbffs_dispatch_eps()
Yu Watanabe [Mon, 3 Sep 2018 05:21:13 +0000 (14:21 +0900)]
TODO: drop duplicated entry
Renaud Métrich [Mon, 3 Sep 2018 03:42:39 +0000 (05:42 +0200)]
journald: fixed assertion failure when system journal rotation fails (#9893)
Evgeny Vereshchagin [Mon, 3 Sep 2018 03:18:26 +0000 (06:18 +0300)]
tests: add a rudimentary fuzzer for server_process_syslog_message (#9979)
Arkan49 [Mon, 3 Sep 2018 03:07:23 +0000 (11:07 +0800)]
Update 60-sensor.hwdb (#9991)
Sergey Ptashnick [Mon, 3 Sep 2018 03:05:45 +0000 (06:05 +0300)]
po: update Russian translation (#9992)
Daniele Medri [Mon, 3 Sep 2018 03:05:28 +0000 (05:05 +0200)]
po: update Italian translation (#9980)
Yu Watanabe [Sat, 1 Sep 2018 14:47:46 +0000 (23:47 +0900)]
cryptsetup: do not define arg_sector_size if libgcrypt is v1.x (#9990)
Follow-up for #9936.
Yu Watanabe [Sat, 1 Sep 2018 14:18:01 +0000 (23:18 +0900)]
Merge pull request #9977 from sourcejedi/no-remount-superblock3
Namespace fixes
Alan Jenkins [Wed, 29 Aug 2018 23:20:48 +0000 (00:20 +0100)]
namespace: remove redundant .has_prefix=false
The MountEntry's added for EMPTY_DIR work very similarly to the TMPFS ones.
In both cases, .has_prefix is false. In fact, .has_prefix is false in
*all* the MountEntry's we add except for the access mounts (READONLY etc).
But EMPTY_DIR stuck out by explicitly setting .has_prefix = false.
Let's remove that.
Alan Jenkins [Wed, 29 Aug 2018 22:38:40 +0000 (23:38 +0100)]
namespace: we always use a root_directory now
We changed to always setup the new namespace in a separate directory
(commit 0722b35)
Alan Jenkins [Wed, 29 Aug 2018 21:36:37 +0000 (22:36 +0100)]
namespace: fix mode for TemporaryFileSystem=
... when no mount options are passed.
Change the code, to avoid the following failure in the newly added tests:
exec-temporaryfilesystem-rw.service: Executing: /usr/bin/sh -x -c
'[ "$(stat -c %a /var)" == 755 ]'
++ stat -c %a /var
+ '[' 1777 == 755 ']'
Received SIGCHLD from PID 30364 (sh).
Child 30364 (sh) died (code=exited, status=1/FAILURE)
(And I spotted an opportunity to use TAKE_PTR() at the end).
Alan Jenkins [Wed, 29 Aug 2018 23:32:54 +0000 (00:32 +0100)]
namespace: don't try to remount superblocks
We can't remount the underlying superblocks, if we are inside a user
namespace and running Linux <= 4.17. We can only change the per-mount
flags (MS_REMOUNT | MS_BIND).
This type of mount() call can only change the per-mount flags, so we
don't have to worry about passing the right string options now.
Fixes #9914 ("Since 1beab8b was merged, systemd has been failing to start
systemd-resolved inside unprivileged containers" ... "Failed to re-mount
'/run/systemd/unit-root/dev' read-only: Operation not permitted").
> It's basically my fault :-). I pointed out we could remount read-only
> without MS_BIND when reviewing the PR that added TemporaryFilesystem=,
> and poettering suggested to change PrivateDevices= at the same time.
> I think it's safe to change back, and I don't expect anyone will notice
> a difference in behaviour.
>
> It just surprised me to realize that
> `TemporaryFilesystem=/tmp:size=10M,ro,nosuid` would not apply `ro` to the
> superblock (underlying filesystem), like mount -osize=10M,ro,nosuid does.
> Maybe a comment could note the kernel version (v4.18), that lets you
> remount without MS_BIND inside a user namespace.
This makes the code longer and I guess this function is still ugly, sorry.
One obstacle to cleaning it up is the interaction between
`PrivateDevices=yes` and `ReadOnlyPaths=/dev`. I've added a test for the
existing behaviour, which I think is now the correct behaviour.
Victor Laskurain [Wed, 29 Aug 2018 18:49:57 +0000 (20:49 +0200)]
Add sensor configuration for Asus TP201SA
Evgeny Vereshchagin [Thu, 30 Aug 2018 04:01:18 +0000 (07:01 +0300)]
tests: also run TEST-01-BASIC in an unprivileged container (#9957)
This should make it much easier to catch regressions like
https://github.com/systemd/systemd/issues/9914 and
https://github.com/systemd/systemd/issues/8535.
Yu Watanabe [Wed, 29 Aug 2018 18:38:28 +0000 (03:38 +0900)]
tree-wide: use '#pragma once' for header guard
Follow-up for
a2b635eb3940f33f5dd308d85ba416f0630d152b (#9959).
Todd Walton [Thu, 30 Aug 2018 00:47:07 +0000 (20:47 -0400)]
man: fix RFC ref in resolved.conf man page (#9976)
This is a simple one-character fix to reference the correct RFC for
LLMNR, which is RFC 4795, not RFC 4794.
Lucas Werkmeister [Sat, 25 Aug 2018 22:27:29 +0000 (00:27 +0200)]
seccomp: improve error reporting
Only report OOM if that was actually the error of the operation,
explicitly report the possible error that a syscall was already blocked
with a different errno and translate that into a more sensible errno
(EEXIST only makes sense in connection to the hashmap), and pass through
all other potential errors unmodified. Part of #9939.
Alan Jenkins [Mon, 27 Aug 2018 18:09:58 +0000 (19:09 +0100)]
resolve: update comment, avoid alarming wrongness
`systemd-resolved.service` runs as `User=systemd-resolved`, and uses certain
Capabilit{y,ies} magic. By my understanding, this means it is started with a
number of "privileges". Indeed, `capabilities(7)` explains
> Linux divides the privileges traditionally
> associated with superuser into distinct units, known as capabilities,
> which can be independently enabled and disabled."
This situation appears to contradict our current code comment which said
> If we are not running as root we assume all privileges are already dropped.
This appears to be a confusion in the comment only. The rest of the code
tells a much clearer story. (Don't ask me if the story is correct.
`capabilities(7)` scares me). Let's tweak the comment to make it consistent
and avoid worrying readers about this.
Sjoerd Simons [Tue, 28 Aug 2018 07:32:18 +0000 (09:32 +0200)]
fd-util: accept that kcmp might fail with EPERM/EACCES
In a container the kcmp call might well be blocked; Accept that and fall
back to fstat in that case.
Samuel Morris [Tue, 28 Aug 2018 14:40:51 +0000 (10:40 -0400)]
systemctl: if no logind, don't try to schedule shutdown
If logind is not supported, don't try to schedule a shutdown,
immediately poweroff. This is the behavior indicated by the current
message given to the user, but the command is returning an error. I
believe this was broken on this commit:
7f96539d45028650f2ba9452095473a9c455d84b
Sylvain Plantefève [Tue, 28 Aug 2018 19:51:24 +0000 (21:51 +0200)]
po: update French translation
Zbigniew Jędrzejewski-Szmek [Wed, 29 Aug 2018 15:47:00 +0000 (17:47 +0200)]
Merge pull request #9959 from yuwata/small-fixes
tiny fixes and a cleanup
Yu Watanabe [Wed, 29 Aug 2018 14:27:42 +0000 (23:27 +0900)]
test: fix a memleak
Follow-up for #9901.
Fixes #9968.
Dimitri John Ledkov [Wed, 29 Aug 2018 14:38:09 +0000 (15:38 +0100)]
cryptsetup: add support for sector-size= option (#9936)
Bug-Ubuntu: https://launchpad.net/bugs/1776626
Closes #8881.
Yu Watanabe [Tue, 28 Aug 2018 05:20:08 +0000 (14:20 +0900)]
sd-boot: fix header guard
Follow-up for
a42d7cf16515ab0ab62aaeff3aab5750c885b7e7.
Yu Watanabe [Tue, 28 Aug 2018 03:41:55 +0000 (12:41 +0900)]
dynamic-user: drop unnecessary initialization
Zbigniew Jędrzejewski-Szmek [Wed, 29 Aug 2018 12:22:27 +0000 (14:22 +0200)]
Merge pull request #9901 from peterbaouoft/pr/preset_enable_multiple_instances
install: allow instantiated units to be enabled via presets
Yu Watanabe [Tue, 28 Aug 2018 03:40:25 +0000 (12:40 +0900)]
string-table: do not ignore 'scope' argument
Yu Watanabe [Tue, 28 Aug 2018 01:43:25 +0000 (10:43 +0900)]
Merge pull request #9950 from yuwata/macro-ref-unref
tree-wide: introduce macros to define *_ref() and *_unref() functions
Ruixin Bao [Sun, 26 Aug 2018 20:00:03 +0000 (20:00 +0000)]
install: small refactor to combine two function calls into one function
Combine consecutive function calls of install_info_discover and
install_info_may_process into one short helper function.
Ruixin Bao [Tue, 21 Aug 2018 20:40:56 +0000 (20:40 +0000)]
install: allow instantiated units to be enabled via presets
This patch implements https://github.com/systemd/systemd/issues/9421.
The .preset file now is able to take a rule in the format of:(e.g)
enable foo@.service bar0 bar1 bar2
In the above example, when preset-all is called, all three instances of
foo@bar0.service, foo@bar1.service and foo@bar2.service will be enabled.
When preset is called on a single service(e.g: foo@bar1.service), only
the mentioned one(foo@bar1.service) will be enabled.
Tests are added for future regression.
Yu Watanabe [Mon, 27 Aug 2018 06:33:17 +0000 (15:33 +0900)]
sd-device: sd_device_enumerator_get_subsystem_next() requests the device list is uptodate
Yu Watanabe [Mon, 27 Aug 2018 05:07:01 +0000 (14:07 +0900)]
sd-device: use structured initializers
Yu Watanabe [Mon, 27 Aug 2018 05:00:01 +0000 (14:00 +0900)]
libsystemd: use DEFINE_ATOMIC_REF_UNREF_FUNC or frineds where applicable
Yu Watanabe [Mon, 27 Aug 2018 04:58:15 +0000 (13:58 +0900)]
refcnt: introduce DEFINE_ATOMIC_REF_UNREF_FUNC() macro and friends
Yu Watanabe [Mon, 27 Aug 2018 04:57:09 +0000 (13:57 +0900)]
sd-netlink: fix indentation
Yu Watanabe [Mon, 27 Aug 2018 04:56:29 +0000 (13:56 +0900)]
sd-hwdb: drop unused variable
Yu Watanabe [Mon, 27 Aug 2018 20:09:00 +0000 (05:09 +0900)]
dynamic-user: fix potential segfault
Zbigniew Jędrzejewski-Szmek [Mon, 27 Aug 2018 12:49:11 +0000 (14:49 +0200)]
Merge pull request #9935 from pfl/dhcp6_pd_assignment_fix
Dhcp6 pd assignment fix
Lucas Werkmeister [Sat, 25 Aug 2018 16:41:42 +0000 (18:41 +0200)]
tools: use print function in Python 3 code
This GDB script was converted to use Python 3 along with all other
Python scripts in commit
b95f5528cc, but still used the Python 2 print
statement syntax instead of the Python 3 print function. Fix that.
We also add the Python 2 compatibility statement, just in case some GDB
still uses Python 2 instead of Python 3.
Thomas Haller [Tue, 7 Aug 2018 14:01:18 +0000 (16:01 +0200)]
link: allocate correct number of bytes in ethtool_set_features()
sfeatures is a "struct ethtool_sfeatures". Use sizeof() on the correct
data type.
Since "struct ethtool_gstrings" is larger than "struct ethtool_sfeatures",
this had no serious consequences.
Fixes:
50725d10e3417fd357abe1df2f177b8458027ac7
Marcin Skarbek [Sun, 26 Aug 2018 14:48:52 +0000 (16:48 +0200)]
don't ignore zd* block devices
dj-kaktus [Sun, 26 Aug 2018 15:26:54 +0000 (17:26 +0200)]
hwdb: Added values for another WALTOP Tablet
Yu Watanabe [Mon, 27 Aug 2018 05:01:46 +0000 (14:01 +0900)]
tree-wide: use DEFINE_TRIVIAL_REF_UNREF_FUNC() macro or friends where applicable
Yu Watanabe [Mon, 27 Aug 2018 05:01:27 +0000 (14:01 +0900)]
macro: introduce DEFINE_TRIVIAL_REF_UNREF_FUNC() macro and friends
Yu Watanabe [Mon, 27 Aug 2018 04:48:04 +0000 (13:48 +0900)]
tree-wide: use unsigned for refcount
Patrik Flykt [Fri, 24 Aug 2018 15:49:22 +0000 (09:49 -0600)]
networkd-dhcp6: Improve logging on DHCPv6 PD assignment
Print out prefixes assigned to links in addition to the DHCPv6
prefix it was delegated from.
Patrik Flykt [Fri, 24 Aug 2018 15:49:20 +0000 (09:49 -0600)]
networkd-dhcp6: Fix logging of DHCPv6 prefix
Pretty-print log messages with DHCPv6 prefixes after the prefixes
have been set instead of some random unassigned stack values.
Patrik Flykt [Fri, 24 Aug 2018 15:49:18 +0000 (09:49 -0600)]
networkd-dhcp6: Fix PD prefix length for subnet assignment
When computing the next network prefix to assign, compute the next
prefix to allocate based on the intended /64 assignment, not the
given prefix length for the whole prefix, e.g. /48, given to
systemd-networkd.
Fixes #9626.
Patrik Flykt [Fri, 24 Aug 2018 15:49:14 +0000 (09:49 -0600)]
networkd-dhcp6: Log warning with PD prefixes shorter than 48
Log a warning message in case the network prefix delegated is shorter
than /48.
Yu Watanabe [Fri, 24 Aug 2018 13:46:13 +0000 (22:46 +0900)]
po: update Japanese translation
Piotr Drąg [Fri, 24 Aug 2018 13:35:46 +0000 (15:35 +0200)]
po: update Polish translation
Yu Watanabe [Fri, 24 Aug 2018 13:34:13 +0000 (22:34 +0900)]
dissect: rescan devices before creating partition list (#9930)
Fixes #9924 which is caused by
3c1f2cee0ad2bea0839ac335532275f3a73c8b20.