module: check kernel param length at compile time, not runtime
The kparam code tries to handle over-length parameter prefixes at runtime. Not only would I bet this has never been tested, it's not clear that truncating names is a good idea either. So let's check at compile time. We need to move the #define to moduleparam.h to do this, though. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
#define MODULE_SYMBOL_PREFIX ""
|
||||
#endif
|
||||
|
||||
#define MODULE_NAME_LEN (64 - sizeof(unsigned long))
|
||||
#define MODULE_NAME_LEN MAX_PARAM_PREFIX_LEN
|
||||
|
||||
struct kernel_symbol
|
||||
{
|
||||
|
Reference in New Issue
Block a user