udev: link-config - move naming policy from udev rules

This introduces a new key NamePolicy, which takes an ordered list of naming
policies. The first successful one is applide. If all fail the value of Name
(if any) is used.

The possible policies are 'onboard', 'slot', 'path' and 'mac'.

This patch introduces a default link file, which replaces the equivalent udev
rule.
This commit is contained in:
Tom Gundersen
2013-10-28 01:18:04 +01:00
parent 2a73e0d39a
commit daeb71a36a
7 changed files with 59 additions and 19 deletions
+1 -1
View File
@@ -6004,7 +6004,7 @@ bool restore_state(void) {
r = read_one_line_file("/proc/cmdline", &line);
if (r < 0) {
log_warning("Failed to read /proc/cmdline, ignoring: %s", strerror(-r));
return 0;
return true; /* something is very wrong, let's not make it worse */
}
FOREACH_WORD_QUOTED(w, l, line, state)