diff options
author | Kay Sievers <kay.sievers@suse.de> | 2006-06-07 16:00:34 +0200 |
---|---|---|
committer | Kay Sievers <kay.sievers@suse.de> | 2006-06-07 16:00:34 +0200 |
commit | 891205121395acbe84eb6173670ce7934cd9b1c6 (patch) | |
tree | 8f3281f5d43b2a300d37a191d3fd089fce048664 /udev_rules.c | |
parent | e55a73abb07e6949ebbf17fa08a3ddeaddbbc41f (diff) |
remove MODALIAS key and substitution
Diffstat (limited to 'udev_rules.c')
-rw-r--r-- | udev_rules.c | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/udev_rules.c b/udev_rules.c index ee4632513a..03b3f2a116 100644 --- a/udev_rules.c +++ b/udev_rules.c @@ -401,7 +401,6 @@ void udev_rules_apply_format(struct udevice *udev, char *string, size_t maxsize) SUBST_PARENT, SUBST_TEMP_NODE, SUBST_ROOT, - SUBST_MODALIAS, SUBST_ENV, }; static const struct subst_map { @@ -421,7 +420,6 @@ void udev_rules_apply_format(struct udevice *udev, char *string, size_t maxsize) { .name = "parent", .fmt = 'P', .type = SUBST_PARENT }, { .name = "tempnode", .fmt = 'N', .type = SUBST_TEMP_NODE }, { .name = "root", .fmt = 'r', .type = SUBST_ROOT }, - { .name = "modalias", .fmt = 'A', .type = SUBST_MODALIAS }, { .name = "env", .fmt = 'E', .type = SUBST_ENV }, { NULL, '\0', 0 } }; @@ -618,24 +616,6 @@ found: strlcat(string, udev_root, maxsize); dbg("substitute udev_root '%s'", udev_root); break; - case SUBST_MODALIAS: - { - const char *value; - static int warn = 1; - - if (warn) { - err("$modalias is deprecated, use $env{MODALIAS} or " - "$sysfs{modalias} instead."); - warn = 0; - } - - value = sysfs_attr_get_value(udev->dev->devpath, "modalias"); - if (value != NULL) { - strlcat(string, value, maxsize); - dbg("substitute MODALIAS '%s'", temp2); - } - } - break; case SUBST_ENV: if (attr == NULL) { dbg("missing attribute"); @@ -730,24 +710,6 @@ static int match_rule(struct udevice *udev, struct udev_rule *rule) if (match_key("NAME", rule, &rule->name, udev->name)) goto nomatch; - if (rule->modalias.operation != KEY_OP_UNSET) { - const char *value; - static int warn = 1; - - if (warn) { - err("MODALIAS is deprecated, use ENV{MODALIAS} or SYSFS{modalias} instead."); - warn = 0; - } - - value = sysfs_attr_get_value(udev->dev->devpath, "modalias"); - if (value == NULL) { - dbg("MODALIAS value not found"); - goto nomatch; - } - if (match_key("MODALIAS", rule, &rule->modalias, value)) - goto nomatch; - } - for (i = 0; i < rule->env.count; i++) { struct key_pair *pair = &rule->env.keys[i]; |