busybox: add 1.23.1 patch to fix modinfo
authorGustavo Zacarias <gustavo@zacarias.com.ar>
Mon, 23 Feb 2015 11:19:18 +0000 (08:19 -0300)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Mon, 23 Feb 2015 11:25:46 +0000 (12:25 +0100)
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/busybox/0005-modinfo.patch [new file with mode: 0644]

diff --git a/package/busybox/0005-modinfo.patch b/package/busybox/0005-modinfo.patch
new file mode 100644 (file)
index 0000000..0a221f7
--- /dev/null
@@ -0,0 +1,17 @@
+Fix broken modinfo.
+
+From upstream: http://busybox.net/downloads/fixes-1.23.1/busybox-1.23.1-modinfo.patch
+
+Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
+
+--- busybox-1.23.1/modutils/modinfo.c
++++ busybox-1.23.1-modinfo/modutils/modinfo.c
+@@ -154,7 +154,7 @@ int modinfo_main(int argc UNUSED_PARAM,
+               if (colon == NULL)
+                       continue;
+               *colon = '\0';
+-              filename2modname(tokens[0], name);
++              filename2modname(bb_basename(tokens[0]), name);
+               for (i = 0; argv[i]; i++) {
+                       if (fnmatch(argv[i], name, 0) == 0) {
+                               modinfo(tokens[0], uts.release, &env);