projects
/
openwrt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ramips: rt305x: add dwc_otg driver
[openwrt.git]
/
package
/
busybox
/
patches
/
470-insmod_search.patch
diff --git
a/package/busybox/patches/470-insmod_search.patch
b/package/busybox/patches/470-insmod_search.patch
index
ef170a2
..
b5314e3
100644
(file)
--- a/
package/busybox/patches/470-insmod_search.patch
+++ b/
package/busybox/patches/470-insmod_search.patch
@@
-1,6
+1,6
@@
--- a/modutils/insmod.c
+++ b/modutils/insmod.c
--- a/modutils/insmod.c
+++ b/modutils/insmod.c
-@@ -
9,6 +9,99
@@
+@@ -
11,6 +11,106
@@
#include "libbb.h"
#include "modutils.h"
#include "libbb.h"
#include "modutils.h"
@@
-37,20
+37,27
@@
+ char *module_dir, real_module_dir[FILENAME_MAX];
+ int len, slen, ret = ENOENT, k_version;
+ struct utsname myuname;
+ char *module_dir, real_module_dir[FILENAME_MAX];
+ int len, slen, ret = ENOENT, k_version;
+ struct utsname myuname;
-+ const char *suffix;
++ const char *suffix
= ".ko"
;
+ struct stat st;
+
+ /* check the kernel version */
+ struct stat st;
+
+ /* check the kernel version */
-+ if (
(uname(&myuname) != 0) || (myuname.release[0] != '2')
)
++ if (
uname(&myuname) != 0
)
+ return EINVAL;
+
+ return EINVAL;
+
-+ k_version = myuname.release[2] - '0';
++ k_version = myuname.release[0] - '0';
++
++ if (k_version < 2 || k_version > 9)
++ return EINVAL;
++
++ if (k_version == 2) {
++ int k_patchlevel = myuname.release[2] - '0';
++ if (k_patchlevel <= 4)
+#if ENABLE_FEATURE_2_4_MODULES
+#if ENABLE_FEATURE_2_4_MODULES
-+
if (k_version <= 4)
-+
suffix = ".o";
-+
else
++
suffix = ".o";
++
#else
++
return EINVAL;
+#endif
+#endif
-+
suffix = ".ko";
++
}
+
+ len = strlen(filename);
+ slen = strlen(suffix);
+
+ len = strlen(filename);
+ slen = strlen(suffix);
@@
-100,7
+107,7
@@
/* 2.6 style insmod has no options and required filename
* (not module name - .ko can't be omitted) */
/* 2.6 style insmod has no options and required filename
* (not module name - .ko can't be omitted) */
-@@ -5
5,9 +148
,15 @@ int insmod_main(int argc UNUSED_PARAM, c
+@@ -5
9,9 +159
,15 @@ int insmod_main(int argc UNUSED_PARAM, c
if (!filename)
bb_show_usage();
if (!filename)
bb_show_usage();
@@
-119,12
+126,12
@@
}
--- a/modutils/Config.src
+++ b/modutils/Config.src
}
--- a/modutils/Config.src
+++ b/modutils/Config.src
-@@ -22
8,7 +228
,7 @@ config FEATURE_MODUTILS_SYMBOLS
+@@ -22
9,7 +229
,7 @@ config FEATURE_MODUTILS_SYMBOLS
config DEFAULT_MODULES_DIR
string "Default directory containing modules"
default "/lib/modules"
- depends on DEPMOD || MODPROBE || MODPROBE_SMALL || MODINFO
config DEFAULT_MODULES_DIR
string "Default directory containing modules"
default "/lib/modules"
- depends on DEPMOD || MODPROBE || MODPROBE_SMALL || MODINFO
-+ depends on DEPMOD ||
MODPROBE || MODPROBE_SMALL || MODINFO || INSMOD
++ depends on DEPMOD ||
INSMOD || MODPROBE || MODPROBE_SMALL || MODINFO
help
Directory that contains kernel modules.
Defaults to "/lib/modules"
help
Directory that contains kernel modules.
Defaults to "/lib/modules"
This page took
0.024366 seconds
and
4
git commands to generate.