problems with modprobe on kernel 2.4

Denys Vlasenko vda.linux at googlemail.com
Thu Apr 2 02:32:25 UTC 2009


On Thursday 02 April 2009 00:50, Guenter wrote:
> Hi Denys,
> Guenter schrieb:
> > attached patch is a diff -u against modutils-24.c from current svn
> > trunk; it does not yet patch obj_load_progbits() since there another
> > function for loading is used, and was unsure if I can replace there in
> > same way as I did in obj_load(); also I want to hear your comments first
> > if my patch is what you expect to see...
> seems its needed to free m_image finally, or? I forgot in my patch...
> 
> but while reading through the code here some other observasions/questions:
> 
>     uname(&uts);
> is called always directly at beginning although the uts struct is only
> used within '#if ENABLE_FEATURE_INSMOD_VERSION_CHECKING/#endif' --
> shouldnt we move it just inside the #if block?
> 
> I think same applies to m_has_modinfo too:
>     m_has_modinfo = (get_modinfo_value(f, "kernel_version") != NULL);
> is just before the #if block where it is used...
> 
> if the feature ENABLE_FEATURE_INSMOD_VERSION_CHECKING is disabled then
> these calls are wasted cpu cycles...

Feel free to send a patch which fixes this.
--
vda


More information about the busybox mailing list