Added a slightly modified version of Ron Alder's insmod patch.

Very cool stuff.
 -Erik
This commit is contained in:
Eric Andersen 2000-06-12 23:11:16 +00:00
parent 44760d058c
commit 9f16d61408
5 changed files with 5452 additions and 101 deletions

View File

@ -1,12 +1,17 @@
0.44 0.44
* Added BB_FEATURE_TRIVIAL_HELP which compiles out most all of the * Added BB_FEATURE_TRIVIAL_HELP which compiles out most all of the
help messages (i.e --help). Saves 17k over a full compile. help messages (i.e --help). Saves 17k over a full compile.
* Added mktemp, contributed by Daniel Jacobowitz <dan@debian.org>
* Added setkeycodes, for those that have wierd keyboard buttons.
* Added cut and tr from minix, since due to the license change, * Added cut and tr from minix, since due to the license change,
we can now use minix code. Minix tr saves 4k. we can now use minix code. Minix tr saves 4k.
* insmod now works. It costs 29k, but imagine an initrd with a
staticly linked busybox containing only insmod and sh, a few /dev
entries, and a kernel module or two... It doesn't get smaller
then this folks (I pity the fool that writes insmod in asm ;-).
Many kudos go to Ron Alder <alder@lineo.com> for finishing this off!!!
* Added a mini ar archive utility, especially written for BusyBox by * Added a mini ar archive utility, especially written for BusyBox by
Glenn McGrath <bug1@netconnect.com.au> Glenn McGrath <bug1@netconnect.com.au>
* Added mktemp, contributed by Daniel Jacobowitz <dan@debian.org>
* Added setkeycodes, for those that have wierd keyboard buttons.
* Added 'grep -v' option (inverted search) and updated * Added 'grep -v' option (inverted search) and updated
docs accordingly. -beppu docs accordingly. -beppu
* Wrote which * Wrote which

View File

@ -40,8 +40,7 @@
#define BB_HOSTNAME #define BB_HOSTNAME
#define BB_ID #define BB_ID
#define BB_INIT #define BB_INIT
// Don't bother turning BB_INSMOD on. It doesn't work yet. #define BB_INSMOD
//#define BB_INSMOD
#define BB_KILL #define BB_KILL
#define BB_KILLALL #define BB_KILLALL
#define BB_KLOGD #define BB_KLOGD
@ -219,6 +218,15 @@
//Turn on extra fbset options //Turn on extra fbset options
//#define BB_FEATURE_FBSET_FANCY //#define BB_FEATURE_FBSET_FANCY
// //
// You must enable one or both of these features
// Support installing modules from pre 2.1 kernels
//#define BB_FEATURE_INSMOD_OLD_KERNEL
// Support installing modules from kernel versions after 2.1.18
#define BB_FEATURE_INSMOD_NEW_KERNEL
//
// Support module version checking
//#define BB_FEATURE_INSMOD_VERSION_CHECKING
//
// //
// End of Features List // End of Features List
// //
@ -271,3 +279,9 @@
#define BB_FEATURE_USE_TERMIOS #define BB_FEATURE_USE_TERMIOS
#endif #endif
#endif #endif
//
#if defined BB_INSMOD
#ifndef BB_FEATURE_INSMOD_OLD_KERNEL
#define BB_FEATURE_INSMOD_NEW_KERNEL
#endif
#endif

2756
insmod.c

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -33,8 +33,8 @@
|| defined (BB_INSMOD) || defined (BB_INSMOD)
/* same conditions as recursiveAction */ /* same conditions as recursiveAction */
#define bb_need_name_too_long #define bb_need_name_too_long
#define bb_need_memory_exhausted
#endif #endif
#define bb_need_memory_exhausted
#define BB_DECLARE_EXTERN #define BB_DECLARE_EXTERN
#include "messages.c" #include "messages.c"
@ -1056,7 +1056,7 @@ extern int replace_match(char *haystack, char *needle, char *newNeedle,
#endif /* ! BB_REGEXP && (BB_GREP || BB_SED) */ #endif /* ! BB_REGEXP && (BB_GREP || BB_SED) */
#if defined BB_FIND #if defined BB_FIND || defined BB_INSMOD
/* /*
* Routine to see if a text string is matched by a wildcard pattern. * Routine to see if a text string is matched by a wildcard pattern.
* Returns TRUE if the text is matched, or FALSE if it is not matched * Returns TRUE if the text is matched, or FALSE if it is not matched
@ -1156,7 +1156,7 @@ extern int check_wildcard_match(const char *text, const char *pattern)
return TRUE; return TRUE;
} }
#endif /* BB_FIND */ #endif /* BB_FIND || BB_INSMOD */