diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2007-04-04 22:08:22 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-04-05 00:12:47 -0400 |
commit | 2363cc0264c42636e9e7622f78dde5c2f66beb8e (patch) | |
tree | 33136de9f38ad6cfc7ce9b6d4d10f1227239a05b | |
parent | c75fd0ee6e1750e6e527ed1d4aeee66739d9ad79 (diff) |
[PATCH] remove protection of LANANA-reserved majors
Revert all this. It can cause device-mapper to receive a different major from
earlier kernels and it turns out that the Amanda backup program (via GNU tar,
apparently) checks major numbers on files when performing incremental backups.
Which is a bit broken of Amanda (or tar), but this feature isn't important
enough to justify the churn.
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | block/genhd.c | 2 | ||||
-rw-r--r-- | drivers/base/core.c | 14 | ||||
-rw-r--r-- | fs/char_dev.c | 2 | ||||
-rw-r--r-- | include/linux/kdev_t.h | 2 |
4 files changed, 0 insertions, 20 deletions
diff --git a/block/genhd.c b/block/genhd.c index 050a1f0f3a86..441432a142f2 100644 --- a/block/genhd.c +++ b/block/genhd.c | |||
@@ -62,8 +62,6 @@ int register_blkdev(unsigned int major, const char *name) | |||
62 | /* temporary */ | 62 | /* temporary */ |
63 | if (major == 0) { | 63 | if (major == 0) { |
64 | for (index = ARRAY_SIZE(major_names)-1; index > 0; index--) { | 64 | for (index = ARRAY_SIZE(major_names)-1; index > 0; index--) { |
65 | if (is_lanana_major(index)) | ||
66 | continue; | ||
67 | if (major_names[index] == NULL) | 65 | if (major_names[index] == NULL) |
68 | break; | 66 | break; |
69 | } | 67 | } |
diff --git a/drivers/base/core.c b/drivers/base/core.c index ad0f4a2f25c4..d7fcf823a42a 100644 --- a/drivers/base/core.c +++ b/drivers/base/core.c | |||
@@ -28,20 +28,6 @@ int (*platform_notify)(struct device * dev) = NULL; | |||
28 | int (*platform_notify_remove)(struct device * dev) = NULL; | 28 | int (*platform_notify_remove)(struct device * dev) = NULL; |
29 | 29 | ||
30 | /* | 30 | /* |
31 | * Detect the LANANA-assigned LOCAL/EXPERIMENTAL majors | ||
32 | */ | ||
33 | bool is_lanana_major(unsigned int major) | ||
34 | { | ||
35 | if (major >= 60 && major <= 63) | ||
36 | return 1; | ||
37 | if (major >= 120 && major <= 127) | ||
38 | return 1; | ||
39 | if (major >= 240 && major <= 254) | ||
40 | return 1; | ||
41 | return 0; | ||
42 | } | ||
43 | |||
44 | /* | ||
45 | * sysfs bindings for devices. | 31 | * sysfs bindings for devices. |
46 | */ | 32 | */ |
47 | 33 | ||
diff --git a/fs/char_dev.c b/fs/char_dev.c index 78ced721554d..164a45cdaf5f 100644 --- a/fs/char_dev.c +++ b/fs/char_dev.c | |||
@@ -109,8 +109,6 @@ __register_chrdev_region(unsigned int major, unsigned int baseminor, | |||
109 | /* temporary */ | 109 | /* temporary */ |
110 | if (major == 0) { | 110 | if (major == 0) { |
111 | for (i = ARRAY_SIZE(chrdevs)-1; i > 0; i--) { | 111 | for (i = ARRAY_SIZE(chrdevs)-1; i > 0; i--) { |
112 | if (is_lanana_major(i)) | ||
113 | continue; | ||
114 | if (chrdevs[i] == NULL) | 112 | if (chrdevs[i] == NULL) |
115 | break; | 113 | break; |
116 | } | 114 | } |
diff --git a/include/linux/kdev_t.h b/include/linux/kdev_t.h index 4c2c3737e415..2dacab8beccb 100644 --- a/include/linux/kdev_t.h +++ b/include/linux/kdev_t.h | |||
@@ -87,8 +87,6 @@ static inline unsigned sysv_minor(u32 dev) | |||
87 | return dev & 0x3ffff; | 87 | return dev & 0x3ffff; |
88 | } | 88 | } |
89 | 89 | ||
90 | bool is_lanana_major(unsigned int major); | ||
91 | |||
92 | #else /* __KERNEL__ */ | 90 | #else /* __KERNEL__ */ |
93 | 91 | ||
94 | /* | 92 | /* |