chiark / gitweb /
6 years agoudev: move global property handling from libudev to udevd
Kay Sievers [Thu, 13 Nov 2014 12:50:01 +0000 (13:50 +0100)]
udev: move global property handling from libudev to udevd

6 years agoudev: switch to systemd logging functions
Kay Sievers [Thu, 13 Nov 2014 12:11:04 +0000 (13:11 +0100)]
udev: switch to systemd logging functions

6 years agolibudev: we do not log errors from libraries
Kay Sievers [Thu, 13 Nov 2014 10:42:24 +0000 (11:42 +0100)]
libudev: we do not log errors from libraries

6 years agotests: add test-execute
Ronny Chevalier [Tue, 11 Nov 2014 19:05:40 +0000 (20:05 +0100)]
tests: add test-execute

add tests for the following directives:
- WorkingDirectory
- Personality
- PrivateTmp
- SystemCallFilter: It makes test/TEST-04-SECCOMP obsolete, so it has
  been removed.
- SystemCallErrorNumber
- User
- Group
- Environment

6 years agomanager: allow test run to catch SIGCHLD events
Ronny Chevalier [Tue, 11 Nov 2014 18:48:27 +0000 (19:48 +0100)]
manager: allow test run to catch SIGCHLD events

Otherwise we cannot know when a service exited

6 years agokeymap: Fix special keys on ThinkPad X60/X61 Tablet
Bastien Nocera [Wed, 12 Nov 2014 22:31:08 +0000 (23:31 +0100)]
keymap: Fix special keys on ThinkPad X60/X61 Tablet

KEY_DIRECTION is mapped to XF86RotateWindows, to rotate the display:

And F13 is mapped to XF86Tools, which is closest to the original toolbox

6 years agokeymap: Add support for IBM ThinkPad X41 Tablet
Bastien Nocera [Wed, 12 Nov 2014 22:30:46 +0000 (23:30 +0100)]
keymap: Add support for IBM ThinkPad X41 Tablet

Scancode taken from:

William Jon McCann provided the DMI match. IBM seems to have
swapped the version and model of the system:
        Manufacturer: IBM
        Product Name: 18666TU
        Version: ThinkPad X41 Tablet

6 years agoman: fix typo
Lennart Poettering [Wed, 12 Nov 2014 22:44:21 +0000 (23:44 +0100)]
man: fix typo

6 years agoUpdate TODO
Lennart Poettering [Wed, 12 Nov 2014 22:44:14 +0000 (23:44 +0100)]
Update TODO

6 years agoudev: use properly the systemd logging functions
Ronny Chevalier [Wed, 12 Nov 2014 20:42:38 +0000 (21:42 +0100)]
udev: use properly the systemd logging functions

6 years agoudev: use the systemd logging functions in udev tools
Kay Sievers [Wed, 12 Nov 2014 17:35:18 +0000 (18:35 +0100)]
udev: use the systemd logging functions in udev tools

6 years agosd-bus: pass attach flags to BUS_CREATOR_INFO
Daniel Mack [Tue, 11 Nov 2014 17:31:11 +0000 (18:31 +0100)]
sd-bus: pass attach flags to BUS_CREATOR_INFO

kdbus learned parsing the attach flags for the KDBUS_CMD_BUS_CREATOR_INFO
ioctl. Bits not set in this mask will not be exported. Set that field to

Signed-off-by: Daniel Mack <>
6 years agoupdate TODO
Lennart Poettering [Tue, 11 Nov 2014 17:12:48 +0000 (18:12 +0100)]
update TODO

6 years agosysuser: simplify access mode syncing by introducing helper function for it
Lennart Poettering [Tue, 11 Nov 2014 17:12:40 +0000 (18:12 +0100)]
sysuser: simplify access mode syncing by introducing helper function for it

6 years agobus-proxyd: explicitly address messages to unique and well-known name
Daniel Mack [Thu, 23 Oct 2014 11:06:38 +0000 (13:06 +0200)]
bus-proxyd: explicitly address messages to unique and well-known name

In order to check for matching policy entries at message transfers, we
have to consider the following:

* check the currently owned names of both the sending and the receiving
peer. If the sending peer is connected via kdbus, the currently owned
names are already attached to the message. If it was originated by the
connection we're proxying for, we store the owned names in our own strv
so we can check against them.

* Walk the list of names to check which name would allow the message to
pass, and explicitly use that name as destination of the message. If the
destination is on kdbus, store both the connection's unique name and the
chosen well-known-name in the message. That way, the kernel will make sure
the supplied name is owned by the supplied unique name, at the time of
sending, and return -EREMCHG otherwise.

* Make the policy checks optional by retrieving the bus owner creds, and
when the uid matches the current user's uid and is non-null, don't check
the bus policy.

6 years agobuild-sys: move libsystemd-capability into libsystemd-shared
Kay Sievers [Tue, 11 Nov 2014 15:13:59 +0000 (16:13 +0100)]
build-sys: move libsystemd-capability into libsystemd-shared

6 years agoRevert "bus-proxyd: make policy checks optional"
Michal Schmidt [Tue, 11 Nov 2014 14:36:00 +0000 (15:36 +0100)]
Revert "bus-proxyd: make policy checks optional"

This reverts commit 5bb24cccbce846c0d77e71b70a3be7f4b2ba6c0e.

It does not even compile (unbalanced {)

6 years agobus-proxyd: make policy checks optional
Daniel Mack [Thu, 23 Oct 2014 11:06:38 +0000 (13:06 +0200)]
bus-proxyd: make policy checks optional

Retrieve the bus owner creds, and when the uid matches the current user's
uid and is non-null, don't check the bus policy.

6 years agobus-proxyd: move name list iteration to policy users
Daniel Mack [Thu, 9 Oct 2014 11:26:53 +0000 (13:26 +0200)]
bus-proxyd: move name list iteration to policy users

We need to figure out which of the possible names satisfied the policy,
so we cannot do the iteration in check_policy_item() but have to leave it
to the users.

Test cases amended accordingly.

6 years agobus-proxyd: enforce policy for method calls
Daniel Mack [Wed, 24 Sep 2014 15:50:31 +0000 (17:50 +0200)]
bus-proxyd: enforce policy for method calls

6 years agobus-proxyd: enforce policy for name ownership
Daniel Mack [Wed, 24 Sep 2014 15:24:20 +0000 (17:24 +0200)]
bus-proxyd: enforce policy for name ownership

6 years agobus-proxyd: enforce policy for Hello messages
Daniel Mack [Wed, 24 Sep 2014 15:18:35 +0000 (17:18 +0200)]
bus-proxyd: enforce policy for Hello messages

6 years agobus-proxyd: keep track of names acquired by legacy client
Daniel Mack [Wed, 24 Sep 2014 15:10:31 +0000 (17:10 +0200)]
bus-proxyd: keep track of names acquired by legacy client

Store names successfully acquired by the legacy client into a hashmap.
We need to take these names into account when checking for send policies.

6 years agosd-bus: add sd_bus_message.verify_destination_id and .destination_ptr
Daniel Mack [Wed, 22 Oct 2014 12:41:53 +0000 (14:41 +0200)]
sd-bus: add sd_bus_message.verify_destination_id and .destination_ptr

kdbus learned to accept both a numerical destination ID as well as a
well-known-name. In that case, kdbus makes sure that the numerical ID is in
fact the owner of the provided name and fails otherwise.

This allows for race-free assertion of a bus name owner while sending a
message, which is a requirement for bus-proxyd.

Add two new fields to sd_bus_message, and set the numerical ID to
verify_destination_id if bus_message_setup_kmsg() is called for a
message with a well-known name.

Also, set the destination's name in the kdbus item to .destination_ptr
if it is non-NULL.

Normal users should not touch these fields, and they're not publicy

6 years agoupdate TODO
Lennart Poettering [Mon, 10 Nov 2014 22:45:31 +0000 (23:45 +0100)]
update TODO

6 years agostrv: rework strv_split_quoted() to use unquote_first_word()
Lennart Poettering [Mon, 10 Nov 2014 22:44:34 +0000 (23:44 +0100)]
strv: rework strv_split_quoted() to use unquote_first_word()

This should make the unquoting scheme a bit less naive.

6 years agobus: when dumping string property values escape the chars we use as end-of-line and...
Lennart Poettering [Mon, 10 Nov 2014 19:54:45 +0000 (20:54 +0100)]
bus: when dumping string property values escape the chars we use as end-of-line and end-of-item marks

6 years agoshared: explicitly ignore the return value of wait_for_terminate
Ronny Chevalier [Sun, 9 Nov 2014 14:51:04 +0000 (15:51 +0100)]
shared: explicitly ignore the return value of wait_for_terminate


6 years agoman: improve documentation for "indirect" unit file state a bit
Lennart Poettering [Mon, 10 Nov 2014 19:16:16 +0000 (20:16 +0100)]
man: improve documentation for "indirect" unit file state a bit

Also, correct mentions of "units" instead of "unit files" in the table,
and terminate all sentences with a full stop.

6 years agoshared/install: when unit contains only Also=, report 'indirect'
Jan Synacek [Fri, 7 Nov 2014 20:21:05 +0000 (21:21 +0100)]
shared/install: when unit contains only Also=, report 'indirect'

If a unit contains only Also=, with no Alias= or WantedBy=, it shouldn't
be reported as static. New 'indirect' status shall be introduced.

6 years agoupdate TODO
Lennart Poettering [Mon, 10 Nov 2014 18:25:16 +0000 (19:25 +0100)]
update TODO

6 years agobusctl: add "tree" command to explore object trees
Lennart Poettering [Mon, 10 Nov 2014 18:24:48 +0000 (19:24 +0100)]
busctl: add "tree" command to explore object trees

6 years agoinhibit: allow filtering --list by mode
Mantas Mikulėnas [Fri, 7 Nov 2014 14:45:53 +0000 (16:45 +0200)]
inhibit: allow filtering --list by mode

Usually there are a few delay inhibitors all the time (NetworkManager,
Telepathy, etc.), but I'm only interested in the block ones.

6 years agobuild-sys: do not use "label" functions in libsystemd-shared
Kay Sievers [Mon, 10 Nov 2014 17:59:03 +0000 (18:59 +0100)]
build-sys: do not use "label" functions in libsystemd-shared

6 years agobuild-sys: test-fdset - add libsystemd-internal
Kay Sievers [Mon, 10 Nov 2014 17:22:44 +0000 (18:22 +0100)]
build-sys: test-fdset - add libsystemd-internal

6 years agobuild-sys: add libcap to libsystemd-shared
Kay Sievers [Mon, 10 Nov 2014 16:32:29 +0000 (17:32 +0100)]
build-sys: add libcap to libsystemd-shared

6 years agoman: don't refer to undocumented option '--failed'
Michal Schmidt [Mon, 10 Nov 2014 13:54:57 +0000 (14:54 +0100)]
man: don't refer to undocumented option '--failed'

6 years agoman: don't document systemctl --failed
Lennart Poettering [Mon, 10 Nov 2014 13:44:35 +0000 (14:44 +0100)]
man: don't document systemctl --failed

This effectively reverts 599b6322f19ec619ddc294d0e7880b669040cf66, which
in turn partially reverted 4dc5b821ae737914499119e29811fc3346e3d97c.

The --failed switch is not documented on purpose, since it is redundant
due to --state=failed, which it predates. Due to that it's not
documented in --help either.

We generally try to avoid redundant interfaces, but if we need to keep
them for compatibility we do so, however remove them from documentation
to ensure they are not used in future.

The man page is now changed to include a comment about the fact that
--failed is not documented on purpose. Also, explicitly mention
--state=failed as example for --state.

6 years agobuild-sys: do not include tests in code coverage
Ronny Chevalier [Sat, 8 Nov 2014 21:33:02 +0000 (22:33 +0100)]
build-sys: do not include tests in code coverage

6 years agoupdate .gitignore
Ronny Chevalier [Sat, 8 Nov 2014 21:31:04 +0000 (22:31 +0100)]
update .gitignore

6 years agobuild-sys: link to libsystemd-core only when needed
Ronny Chevalier [Sat, 8 Nov 2014 21:05:29 +0000 (22:05 +0100)]
build-sys: link to libsystemd-core only when needed

Multiple executables do not need libsystemd-core

6 years agocore: remove unused macro GC_QUEUE_USEC_MAX
Ronny Chevalier [Sat, 8 Nov 2014 20:55:07 +0000 (21:55 +0100)]
core: remove unused macro GC_QUEUE_USEC_MAX

It is unused since cf1265e188e876dda906dca0029248a06dc80c33

6 years agobuild-sys: avoid duplication of macro definition
Ronny Chevalier [Sat, 8 Nov 2014 20:11:19 +0000 (21:11 +0100)]
build-sys: avoid duplication of macro definition

TEST_DIR is already defined in AM_CFLAGS

6 years agotests: add test-path
Ronny Chevalier [Wed, 5 Nov 2014 20:27:01 +0000 (21:27 +0100)]
tests: add test-path

It tests all available directives of Path units:
- PathChanged
- PathModified
- PathExists
- PathExisysGlob
- DirectoryNotEmpty
- MakeDirectory
- DirectoryMode
- Unit

6 years agonetwork: fix typo
Rami Rosen [Sat, 8 Nov 2014 10:59:01 +0000 (12:59 +0200)]
network: fix typo


6 years agoman: document --failed
Zbigniew Jędrzejewski-Szmek [Fri, 7 Nov 2014 23:11:53 +0000 (18:11 -0500)]
man: document --failed

6 years agoshared: add readlink_value
Tom Gundersen [Fri, 7 Nov 2014 18:19:02 +0000 (19:19 +0100)]
shared: add readlink_value

Reads the basename of the target of a symlink.

6 years agosysusers: be nice and print a warning if futimens() fails
Lennart Poettering [Fri, 7 Nov 2014 15:34:37 +0000 (16:34 +0100)]
sysusers: be nice and print a warning if futimens() fails

CID# 1251163

6 years agoutf8: when looking at the next unichar, honour the size parameter, in utf8_is_printab...
Lennart Poettering [Fri, 7 Nov 2014 15:34:00 +0000 (16:34 +0100)]
utf8: when looking at the next unichar, honour the size parameter, in utf8_is_printable_newline()

6 years agolog: explicitly ignore return value of parse_proc_cmdline()
Lennart Poettering [Fri, 7 Nov 2014 15:33:03 +0000 (16:33 +0100)]
log: explicitly ignore return value of parse_proc_cmdline()

CID# 1251162

6 years agocore: unify how we create the notify and private dbus socket
Lennart Poettering [Fri, 7 Nov 2014 15:32:06 +0000 (16:32 +0100)]
core: unify how we create the notify and private dbus socket

Use the same robust logic of mkdir + unlink of any existing AF_UNIX
socket, ignoring the return value, right before bind().

6 years agoupdate TODO
Lennart Poettering [Fri, 7 Nov 2014 15:31:42 +0000 (16:31 +0100)]
update TODO

6 years agoman: update bootup(7) for asynchronous
Zbigniew Jędrzejewski-Szmek [Fri, 7 Nov 2014 02:37:44 +0000 (21:37 -0500)]
man: update bootup(7) for asynchronous

6 years agomanager: cast mkdir() result to (void) to make sure coverity is quiet
Lennart Poettering [Fri, 7 Nov 2014 01:05:50 +0000 (02:05 +0100)]
manager: cast mkdir() result to (void) to make sure coverity is quiet

Also simplify the code a bit by moving mkdir to the common path.

6 years agoupdate TODO
Lennart Poettering [Fri, 7 Nov 2014 01:01:47 +0000 (02:01 +0100)]
update TODO

6 years agoutil: simplify normalize_env_assignment() a bit
Lennart Poettering [Fri, 7 Nov 2014 00:19:48 +0000 (01:19 +0100)]
util: simplify normalize_env_assignment() a bit

6 years agoutil: file_is_priv_sticky() is used internally in util.c only nowadays, make it static
Lennart Poettering [Fri, 7 Nov 2014 00:19:14 +0000 (01:19 +0100)]
util: file_is_priv_sticky() is used internally in util.c only nowadays, make it static

6 years agoupdate TODO
Lennart Poettering [Fri, 7 Nov 2014 00:10:57 +0000 (01:10 +0100)]
update TODO

6 years agotimer: reenable TIMER_ACTIVE timers when restarted
Michael Chapman [Thu, 6 Nov 2014 08:47:02 +0000 (19:47 +1100)]
timer: reenable TIMER_ACTIVE timers when restarted

A timer configured with OnActiveSec will start its associated unit again
if the timer is stopped, then started. However, if the timer unit is
restarted -- with "systemctl restart", say -- this does not occur.

This commit ensures that TIMER_ACTIVE timers are re-enabled whenever the
timer is started, even if that's within a restart job.

6 years agoutil: rework /proc/cmdline parser to use unquote_first_word()
Lennart Poettering [Thu, 6 Nov 2014 23:10:24 +0000 (00:10 +0100)]
util: rework /proc/cmdline parser to use unquote_first_word()

6 years agoutil: simplify proc_cmdline() to reuse get_process_cmdline()
Lennart Poettering [Thu, 6 Nov 2014 20:53:34 +0000 (21:53 +0100)]
util: simplify proc_cmdline() to reuse get_process_cmdline()

Also, make all parsing of the kernel cmdline non-fatal.

6 years agofileio: simplify write_string_file_atomic() by reusing write_string_stream()
Lennart Poettering [Thu, 6 Nov 2014 20:21:39 +0000 (21:21 +0100)]
fileio: simplify write_string_file_atomic() by reusing write_string_stream()

6 years agocopy: change error code when hitting copy limit to EFBIG
Lennart Poettering [Thu, 6 Nov 2014 20:20:32 +0000 (21:20 +0100)]
copy: change error code when hitting copy limit to EFBIG

After all, this is about files, not arguments, hence EFBIG is more
appropriate than E2BIG

6 years agocopy: teach copy_bytes() sendfile() support, and then replace sendfile_full() by it
Lennart Poettering [Thu, 6 Nov 2014 20:19:20 +0000 (21:19 +0100)]
copy: teach copy_bytes() sendfile() support, and then replace sendfile_full() by it

6 years agoutil: make use of isempty() where appropriate
Lennart Poettering [Thu, 6 Nov 2014 20:11:10 +0000 (21:11 +0100)]
util: make use of isempty() where appropriate

6 years agoshutdown: fix arguments to /run/initramfs/shutdown
Michal Schmidt [Thu, 6 Nov 2014 21:24:13 +0000 (22:24 +0100)]
shutdown: fix arguments to /run/initramfs/shutdown

Our initrd interface specifies that the verb is in argv[1].
This is where systemd passes it to systemd-shutdown, but getopt
permutes argv[]. This confuses dracut's shutdown script:
  Shutdown called with argument '--log-level'. Rebooting!

getopt can be convinced to not permute argv[] by having '-' as the first
character of optstring. Let's use it. This requires changing the way
non-option arguments (in our case, the verb) are processed.

This fixes a bug where the system would reboot instead of powering off.

6 years agoupdate TODO
Lennart Poettering [Thu, 6 Nov 2014 19:09:27 +0000 (20:09 +0100)]
update TODO

6 years agos/command-line/command line/g
Lennart Poettering [Thu, 6 Nov 2014 19:06:30 +0000 (20:06 +0100)]
s/command-line/command line/g

A follow-up to:

commit 3f85ef0f05ffc51e19f86fb83a1c51e8e3cd6817
Author: Harald Hoyer <>
Date:   Thu Nov 6 15:33:48 2014 +0100

    s/commandline/command line/g

6 years agomachined: reorder method calls in vtable
Lennart Poettering [Thu, 6 Nov 2014 19:00:14 +0000 (20:00 +0100)]
machined: reorder method calls in vtable

6 years agoswitch-root: explain why we don't care about base_filesystem_create() failing
Lennart Poettering [Thu, 6 Nov 2014 19:00:01 +0000 (20:00 +0100)]
switch-root: explain why we don't care about base_filesystem_create() failing

6 years agoshared: create files even if the SELinux policy has no context for them
Michal Schmidt [Thu, 6 Nov 2014 15:48:11 +0000 (16:48 +0100)]
shared: create files even if the SELinux policy has no context for them

The SELinux policy defines no context for some files. E.g.:
  $ matchpathcon /run/lock/subsys /dev/mqueue
  /run/lock/subsys        <<none>>
  /dev/mqueue     <<none>>

We still need to be able to create them.
In this case selabel_lookup_raw() returns ENOENT. We should then skip
setfscreatecon(), but still return success.
It was broken since c34255bdb2 ("label: unify code to make directories,

6 years agos/commandline/command line/g
Harald Hoyer [Thu, 6 Nov 2014 14:33:48 +0000 (15:33 +0100)]
s/commandline/command line/g

6 years agoswitch_root: do not fail, if base_filesystem_create() failed
Harald Hoyer [Wed, 3 Sep 2014 11:31:25 +0000 (13:31 +0200)]
switch_root: do not fail, if base_filesystem_create() failed

Not all switch roots are like base_filesystem_create() wants them
to look like. They might even boot, if they are RO and don't have the FS
layout. Just ignore the error and switch_root nevertheless.

base_filesystem_create() should have logged, what went wrong.

6 years agoREADME: mention that engineering services for systemd are available from endocode
Lennart Poettering [Thu, 6 Nov 2014 14:27:13 +0000 (15:27 +0100)]
README: mention that engineering services for systemd are available from endocode

6 years agosystemctl: when invokes as "reboot -f", sync()
Lennart Poettering [Thu, 6 Nov 2014 14:20:29 +0000 (15:20 +0100)]
systemctl: when invokes as "reboot -f", sync()

We do this in the clean shutdown path in shutdown.c, hence we should do
is for "reboot -f", too.

6 years agohostnamed: introduce new "embedded" chassis type
Lennart Poettering [Thu, 6 Nov 2014 13:37:12 +0000 (14:37 +0100)]
hostnamed: introduce new "embedded" chassis type

We really don't want to get lost in adding fridge, car, plane, drone, or
whatever else, hence add a generic term "embedded" cover all the cases
where the computer is just part of something bigger, and not at the
focus of things.

6 years agoupdate TODO
Lennart Poettering [Thu, 6 Nov 2014 13:31:04 +0000 (14:31 +0100)]
update TODO

6 years agoshared: rename condition-util.[ch] to condition.[ch]
Lennart Poettering [Thu, 6 Nov 2014 13:19:05 +0000 (14:19 +0100)]
shared: rename condition-util.[ch] to condition.[ch]

Now that we only have one file with condition implementations around, we
can drop the -util suffix and simplify things a bit.

6 years agocore: get rid of condition.c and move the remaining call into util.c
Lennart Poettering [Thu, 6 Nov 2014 13:09:51 +0000 (14:09 +0100)]
core: get rid of condition.c and move the remaining call into util.c

That way only one file with condition code remaining, in src/shared/,
rather than src/core/.

Next step: dropping the "-util" suffix from condition-util.[ch].

6 years agoman: document that we don't document .include on purpose
Lennart Poettering [Thu, 6 Nov 2014 13:00:05 +0000 (14:00 +0100)]
man: document that we don't document .include on purpose

<!-- xml comments are useful! -->

6 years agoman: don't document ConditionNull=/AssertNull= as the are not particularly useful...
Lennart Poettering [Thu, 6 Nov 2014 12:59:41 +0000 (13:59 +0100)]
man: don't document ConditionNull=/AssertNull= as the are not particularly useful and simply confusing

6 years agocondition: order condition types the same way in man page, enum, tables
Lennart Poettering [Thu, 6 Nov 2014 12:56:22 +0000 (13:56 +0100)]
condition: order condition types the same way in man page, enum, tables

Yes, sometimes I develop OCD.

6 years agocore: introduce the concept of AssertXYZ= similar to ConditionXYZ=, but fatal for...
Lennart Poettering [Thu, 6 Nov 2014 12:43:45 +0000 (13:43 +0100)]
core: introduce the concept of AssertXYZ= similar to ConditionXYZ=, but fatal for a start job if not met

6 years agocondition: record test state internally and beef it up to be a full enum
Lennart Poettering [Thu, 6 Nov 2014 01:27:10 +0000 (02:27 +0100)]
condition: record test state internally and beef it up to be a full enum

6 years agocondition: add more test cases
Lennart Poettering [Thu, 6 Nov 2014 01:11:08 +0000 (02:11 +0100)]
condition: add more test cases

6 years agojournal: adjust audit log messages a bit
Lennart Poettering [Thu, 6 Nov 2014 01:10:56 +0000 (02:10 +0100)]
journal: adjust audit log messages a bit

6 years agocondition: internalize condition test functions
Lennart Poettering [Thu, 6 Nov 2014 01:02:13 +0000 (02:02 +0100)]
condition: internalize condition test functions

Also, implement the negation check inside of condition_test() instead of
individually in each test function.

6 years agocondition: unify condition logic in one file
Lennart Poettering [Thu, 6 Nov 2014 00:40:37 +0000 (01:40 +0100)]
condition: unify condition logic in one file

6 years agocondition: properly allow passing back errors from condition checks
Lennart Poettering [Wed, 5 Nov 2014 23:49:44 +0000 (00:49 +0100)]
condition: properly allow passing back errors from condition checks

6 years agounits: restore job timeouts for poweroff and reboot
Zbigniew Jędrzejewski-Szmek [Thu, 6 Nov 2014 13:15:48 +0000 (08:15 -0500)]
units: restore job timeouts for poweroff and reboot

It seems that there actually aren't any long running tasks which are
performed at shutdown. If it turns out that there actually are, this
should be revisited.

This reverts most of commit 038193efa6.

6 years agologin: rerun vconsole-setup when switching from vgacon to fbcon
Ray Strode [Wed, 5 Nov 2014 13:30:52 +0000 (08:30 -0500)]
login: rerun vconsole-setup when switching from vgacon to fbcon

The initialization performed by systemd-vconsole-setup is reset
when changing console drivers (say from vgacon to fbcon), so we
need to run it in that case.


This commit adds a udev rule to make systemd-vconsole-setup get run when
the fbcon device becomes available.

(david: moved into new file 90-vconsole.rules instead of 71-seats.rules;
        build-failures are on me, not on Ray)

6 years agounits: disable job timeouts
Zbigniew Jędrzejewski-Szmek [Wed, 5 Nov 2014 14:16:58 +0000 (09:16 -0500)]
units: disable job timeouts

For boot, we might kill fsck in the middle, with likely catastrophic

On shutdown there might be other jobs, like downloading of updates for
installation, and other custom jobs. It seems better to schedule an
individual timeout on each one separately, when it is known what
timeout is useful.

Disable the timeouts for now, until we have a clearer picture of how
we can deal with long-running jobs.

6 years agoudev hwdb: Change error message regarding missing hwdb.bin back to debug.
Colin Guthrie [Wed, 5 Nov 2014 15:29:41 +0000 (15:29 +0000)]
udev hwdb: Change error message regarding missing hwdb.bin back to debug.

When used in an initramfs, it's expected that the hwdb.bin file is
not present (it makes for a very large initramfs otherwise).

While it's nice to tell the user about this, as it's not strictly
speaking an error we really shouldn't be so forceful in our

6 years agoutil: minor modernisations
Lennart Poettering [Wed, 5 Nov 2014 18:44:01 +0000 (19:44 +0100)]
util: minor modernisations

6 years agocondition: rewrite condition_test_kernel_command_line() based on unquote_first_word()
Lennart Poettering [Wed, 5 Nov 2014 18:43:55 +0000 (19:43 +0100)]
condition: rewrite condition_test_kernel_command_line() based on unquote_first_word()

6 years agosd-pppoe: spelling
Tom Gundersen [Wed, 5 Nov 2014 18:32:46 +0000 (19:32 +0100)]
sd-pppoe: spelling

Thanks to Daniele Medri

6 years agosd-bus: by default allow all creds to be passed along
Lennart Poettering [Wed, 5 Nov 2014 17:54:50 +0000 (18:54 +0100)]
sd-bus: by default allow all creds to be passed along

6 years agocore: introduce new Delegate=yes/no property controlling creation of cgroup subhierar...
Lennart Poettering [Wed, 5 Nov 2014 16:57:23 +0000 (17:57 +0100)]
core: introduce new Delegate=yes/no property controlling creation of cgroup subhierarchies

For priviliged units this resource control property ensures that the
processes have all controllers systemd manages enabled.

For unpriviliged services (those with User= set) this ensures that
access rights to the service cgroup is granted to the user in question,
to create further subgroups. Note that this only applies to the
name=systemd hierarchy though, as access to other controllers is not
safe for unpriviliged processes.

Delegate=yes should be set for container scopes where a systemd instance
inside the container shall manage the hierarchies below its own cgroup
and have access to all controllers.

Delegate=yes should also be set for user@.service, so that systemd
--user can run, controlling its own cgroup tree.

This commit changes machined, systemd-nspawn@.service and user@.service
to set this boolean, in order to ensure that container management will
just work, and the user systemd instance can run fine.

6 years agolibsystemd-network: don't use unaligned helpers in _packed_ structs
Tom Gundersen [Tue, 4 Nov 2014 19:19:07 +0000 (20:19 +0100)]
libsystemd-network: don't use unaligned helpers in _packed_ structs

The compiler will do this for us.

6 years agoshared: unaligned - use void* instead of unaligned be16_t*
Tom Gundersen [Tue, 4 Nov 2014 18:52:04 +0000 (19:52 +0100)]
shared: unaligned - use void* instead of unaligned be16_t*