summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-12-06hwdb: Add fixed layout for OKE barcode readerBastien Nocera
2016-12-06time-util: accept "µs" as time unit, in addition to "us" (#4836)Lennart Poettering
Let's accept "µs" as alternative time unit for microseconds. We already accept "us" and "usec" for them, lets extend on this and accept the proper scientific unit specification too. We will never output this as time unit, but it's fine to accept it, after all we are pretty permissive with time units already.
2016-12-06rules: consider MMC device partitions with partition number > 9 (#4831)Kieran Colford
Add entries for extra partitions found on MMC devices (common in Chromebooks).
2016-12-06Merge pull request #4838 from phomes/misc-cleanup2Evgeny Vereshchagin
Misc cleanups
2016-12-06core: remove unused variableThomas Hindoe Paaboel Andersen
2016-12-06udev: remove duplicate flagThomas Hindoe Paaboel Andersen
One SA_RESTART is enough. Fall out from e28c7cd0665364bb910fe2cead882623c23c28ac
2016-12-05man: Document return value of event source prepare callback (#4834)Martin Ejdestig
2016-12-05nspawn: don't hide --bind=/tmp/* mounts (#4824)Evgeny Vereshchagin
Fixes #4789
2016-12-05networkd: link_enter_configured remove assert (#4800)Susant Sahani
When we are in link_enter_configured we assume that the link->state should be LINK_STATE_SETTING_ROUTES but in some situation it's LINK_STATlE_SETTING_ADDRESSES. Just ignore the wrong state. Also since the return value not used any where make link_enter_configured return type void. Fixes: #4746
2016-12-02journal: make sure to initially populate the space info cache (#4807)Franck Bui
Make sure to populate the cache in cache_space_refresh() at least once otherwise it's possible that the system boots fast enough (and the journal flush service is finished) before the invalidate cache timeout (30 us) has expired. Fixes: #4790
2016-12-02cgroup: properly check for ignore-notfound paths (#4803)Dave Reisner
Follow-up to #4687 and e7330dfe14b1965f.
2016-12-02treewide: fix typos (#4802)Torstein Husebø
2016-12-02Merge pull request #4228 from dm0-/coreos-1554Zbigniew Jędrzejewski-Szmek
networkd: support marking links unmanaged
2016-12-02Merge pull request #4797 from keszybz/pylintMartin Pitt
Python cleanups based on pylint advice
2016-12-01python: use raw strings for regexp patternsZbigniew Jędrzejewski-Szmek
Behaviour is not changed, because "unknown" escapes like \s or \d were not substituted, but it's much nicer to use raw strings to avoid ambiguity.
2016-12-01hwdb_parse: adjust indentation and imports following pylint adviceZbigniew Jędrzejewski-Szmek
(This commit is separate to make it easy to export to libinput.)
2016-12-01python: adjust imports, indentation, unused variables following pylint adviceZbigniew Jędrzejewski-Szmek
2016-12-01acpi-update.py: there is no "Error" classZbigniew Jędrzejewski-Szmek
Evidently this code path was never hit, because we'd crash with NameError. The exception message also seems bogus. So just replace the whole thing with the standard exception for invalid input.
2016-12-01Spot inconsistent quoting (just one single quote) (#4732)Tobias Stoeckmann
It is possible to specify only one quote in udev rules, which is not detected as an invalid quoting (" instead of "" for empty string). Technically this doesn't lead to a bug, because the string ends in two terminating nul characters at this position, but a user should still be reminded that his configuration is invalid.
2016-12-02networkd: VXLAN add better explanation for ARPProxy (#4781)Susant Sahani
This closes #4768
2016-12-01networkd: support marking links unmanagedDavid Michael
2016-12-01networkd-test: define a utility class to simplify testsDavid Michael
2016-12-01rules: add persistent links for nbd devices (#4785)Martin Pitt
https://bugs.debian.org/837999
2016-12-01Update boot.c (#4780)Yassine Imounachen
2016-12-01Merge pull request #4694 from poettering/chase-everywhereZbigniew Jędrzejewski-Szmek
tree-wide: stop using canonicalize_file_name(), use chase_symlinks() …
2016-12-01Merge pull request #4778 from whot/xkb-fixed-layoutMartin Pitt
Xkb fixed layout
2016-12-01util-lib: rename CHASE_NON_EXISTING → CHASE_NONEXISTENTLennart Poettering
As suggested by @keszybz
2016-12-01nspawn: improve log messagesLennart Poettering
When complaining about the inability to resolve a path, show the full path, not just the relative one. As suggested by @keszybz.
2016-12-01nspawn: optionally, automatically allocated --bind=/--overlay source from ↵Lennart Poettering
/var/tmp This extends the --bind= and --overlay= syntax so that an empty string as source/upper directory is taken as request to automatically allocate a temporary directory below /var/tmp, whose lifetime is bound to the nspawn runtime. In combination with the "+" path extension this permits a switch "--overlay=+/var::/var" in order to use the container's shipped /var, combine it with a writable temporary directory and mount it to the runtime /var of the container.
2016-12-01nspawn: permit prefixing of source paths in --bind= and --overlay= with "+"Lennart Poettering
If a source path is prefixed with "+" it is taken relative to the container's root directory instead of the host. This permits easily establishing bind and overlay mounts based on data from the container rather than the host. This also reworks custom_mounts_prepare(), and turns it into two functions: one custom_mount_check_all() that remains in nspawn.c but purely verifies the validity of the custom mounts configured. And one called custom_mount_prepare_all() that actually does the preparation step, sorts the custom mounts, resolves relative paths, and allocates temporary directories as necessary.
2016-12-01tree-wide: set SA_RESTART for signal handlers we installLennart Poettering
We already set it in most cases, but make sure to set it in all others too, and document that that's a good idea.
2016-12-01nspawn: add ability to configure overlay mounts to .nspawn filesLennart Poettering
Fixes: #4634
2016-12-01hwdb: add XKB_FIXED_LAYOUT/VARIANT to the keyboard hwdbPeter Hutterer
Yubikeys and other pseudo keyboards require that they are in the US layout, otherwise the data they send is invalid. Add two new keys to signal this to processes that handles (XKB) layouts.
2016-12-01hwdb: fix comment referring to rules filePeter Hutterer
60-keyboard.rules was renamed to 60-evdev.rules in 51c0c2869 Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-12-01nspawn: split out overlayfs argument parsing into a function of its ownLennart Poettering
Add overlay_mount_parse() similar in style to tmpfs_mount_parse() and bind_mount_parse().
2016-12-01nspawn: use -ENOMEM instead of log_oom() in one caseLennart Poettering
The function is of the "library" kind and doesn't log ENOMEM in all other cases, hence fix the one outlier.
2016-12-01nspawn: make use of CHASE_NON_EXISTING when locking imageLennart Poettering
If --template= is used on an image, then the image might not exist initially. We can use CHASE_NON_EXISTING to properly lock the image already before it exists. Let's do so.
2016-12-01nspawn: use the new CHASE_NON_EXISTING flag when resolving mount pointsLennart Poettering
This restores the ability to implicitly create files/directories to mount specified mount points on.
2016-12-01fs-util: add new CHASE_NON_EXISTING flag to chase_symlinks()Lennart Poettering
This new flag controls whether to consider a problem if the referenced path doesn't actually exist. If specified it's OK if the final file doesn't exist. Note that this permits one or more final components of the path not to exist, but these must not contain "../" for safety reasons (or, to be extra safe, neither "./" and a couple of others, i.e. what path_is_safe() permits). This new flag is useful when resolving paths before issuing an mkdir() or open(O_CREAT) on a path, as it permits that the file or directory is created later. The return code of chase_symlinks() is changed to return 1 if the file exists, and 0 if it doesn't. The latter is only returned in case CHASE_NON_EXISTING is set.
2016-12-01fs-util: add flags parameter to chase_symlinks()Lennart Poettering
Let's remove chase_symlinks_prefix() and instead introduce a flags parameter to chase_symlinks(), with a flag CHASE_PREFIX_ROOT that exposes the behaviour of chase_symlinks_prefix().
2016-12-01fs-util: change chase_symlinks() behaviour in regards to escaping the root dirLennart Poettering
Previously, we'd generate an EINVAL error if it is attempted to escape a root directory with relative ".." symlinks. With this commit this is changed so that ".." from the root directory is a NOP, following the kernel's own behaviour where /.. is equivalent to /. As suggested by @keszybz.
2016-12-01test-fs-util: add a test case with repeated ".." parts that would escape the ↵Zbigniew Jędrzejewski-Szmek
root
2016-12-01nspawn: use chase_symlinks() on all paths specified via --tmpfs=, --bind= ↵Lennart Poettering
and so on Fixes: #2860
2016-12-01fs-util: add chase_symlinks_prefix() and extend commentsLennart Poettering
chase_symlinks() currently expects a fully qualified, absolute path, relative to the host's root as first argument. Which is useful in many ways, and similar to the paths unlink(), rename(), open(), … expect. Sometimes it's however useful to first prefix the specified path with the specified root directory. Add a new call chase_symlinks_prefix() for this, that is a simple wrapper.
2016-12-01nspawn: coding style: don't mix variable declarations and function callsLennart Poettering
2016-12-01nspawn: use realloc_multiply() where it makes senseLennart Poettering
2016-12-01nspawn: accept --ephemeral --template= as alternative for --ephemeral ↵Lennart Poettering
--directory= As suggested in PR #3667. This PR simply ensures that --template= can be used as alternative to --directory= when --ephemeral is used, following the logic that for ephemeral options the source directory is actually a template. This does not deprecate usage of --directory= with --ephemeral, as I am not convinced the old logic wouldn't make sense. Fixes: #3667
2016-12-01nspawn: properly handle image/directory paths that are symlinksLennart Poettering
This resolves any paths specified on --directory=, --template=, and --image= before using them. This makes sure nspawn can be used correctly on symlinked images and directory trees. Fixes: #2001
2016-12-01tree-wide: stop using canonicalize_file_name(), use chase_symlinks() insteadLennart Poettering
Let's use chase_symlinks() everywhere, and stop using GNU canonicalize_file_name() everywhere. For most cases this should not change behaviour, however increase exposure of our function to get better tested. Most importantly in a few cases (most notably nspawn) it can take the correct root directory into account when chasing symlinks.
2016-12-01core: make unit_free() accept NULL pointersLennart Poettering
We generally try to make our destructors robust regarding NULL pointers, much in the same way as glibc's free(). Do this also for unit_free(). Follow-up for #4748.