summaryrefslogtreecommitdiff
path: root/namedev_parse.c
diff options
context:
space:
mode:
authorkay.sievers@vrfy.org <kay.sievers@vrfy.org>2004-11-13 14:43:24 +0100
committerGreg KH <gregkh@suse.de>2005-04-26 22:27:34 -0700
commit7efa217db0db946e68e6274e2b9cbe0a973ec47a (patch)
tree80c697681846807293352b05ee2e5b9e9ef7af79 /namedev_parse.c
parentd4a32aa2e4804de9189574213749616dda57faa7 (diff)
[PATCH] add NAME{ignore_remove} attribute
Some broken ide drivers are generating high event traffic, with add/remove events. With this attribute, it can be specified, that the node is always available. It may be used in conjunction with the new DRIVER= match to catch specific kernel device drivers.
Diffstat (limited to 'namedev_parse.c')
-rw-r--r--namedev_parse.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/namedev_parse.c b/namedev_parse.c
index 4afa85cfa9..cb1760fd57 100644
--- a/namedev_parse.c
+++ b/namedev_parse.c
@@ -278,10 +278,16 @@ static int namedev_parse_rules(const char *filename, void *data)
if (strncasecmp(temp2, FIELD_NAME, sizeof(FIELD_NAME)-1) == 0) {
attr = get_key_attribute(temp2 + sizeof(FIELD_NAME)-1);
- if (attr != NULL && strcasecmp(attr, ATTR_PARTITIONS) == 0) {
+ if (attr != NULL) {
+ if (strstr(attr, ATTR_PARTITIONS) != NULL) {
dbg_parse("creation of partition nodes requested");
dev.partitions = PARTITIONS_COUNT;
}
+ if (strstr(attr, ATTR_IGNORE_REMOVE) != NULL) {
+ dbg_parse("remove event should be ignored");
+ dev.ignore_remove = 1;
+ }
+ }
strfieldcpy(dev.name, temp3);
valid = 1;
continue;