DKMS now handles obsolete modules

Gary_Lerhaupt@Dell.com Gary_Lerhaupt@Dell.com
Wed Nov 5 17:19:00 2003


Yup, exactly.

BUILT_MODULE_NAME[0]="bcm5700"
MODULES_CONF_ALIAS_TYPE[0]="eth"
MODULES_CONF_OBSOLETES[0]="tg3"

Of course, if your kernel had an original bcm5700 in it and you did a remove
--all, it would stick with bcm5700 and not go back to tg3 even if that's
what you were using before installing the DKMS package.

Gary

> -----Original Message-----
> From: John_Hull@dell.com 
> Sent: Wednesday, November 05, 2003 5:03 PM
> To: Lerhaupt, Gary; dkms-devel@lists.us.dell.com
> Subject: RE: DKMS now handles obsolete modules
> 
> 
> So if I have "alias eth0 tg3" in modules.conf, and I add/build/install
> bcm5700 to my system (with MODULES_CONF_OBSOLETES[0]="tg3", and
> "MODULES_CONF_ALIAS_TYPE[0]="eth" in dkms.conf), then 
> modules.conf will now
> say "alias eth0 bcm5700"? And if I do a dkms remove --all, it 
> will put it
> back to tg3?
> 
> That will definitely be helpful...
> 
> 
> -----Original Message-----
> From: Gary_Lerhaupt@dell.com 
> Sent: Wednesday, November 05, 2003 4:00 PM
> To: dkms-devel@lists.us.dell.com
> Subject: DKMS now handles obsolete modules
> 
> 
> DKMS 0.44.05 is out (lerhaupt.com/dkms)
> 
> With it, I added the DKMS directive array 
> MODULES_CONF_OBSOLETES[#].  This
> is a comma-delimited list of modules that your newer module 
> oboletes.  If a
> corresponding entry in the MODULES_CONF_ALIAS_TYPE[#] is set 
> and any of
> these entries are found in /etc/modules.conf, the obsolete 
> references are
> replaced with the new module references during install of your module.
> 
> Likewise, during uninstall, this also helps DKMS.  If an 
> original_module
> name of the newer module was found in your kernel, then the 
> new module name
> in modules.conf will persist.  However, if no original module 
> exists in your
> kernel, but an obsolete module does, DKMS will first put this obsolete
> module reference in modules.conf before remaking your initrd. 
>  If neither an
> original module or an obsolete module exists, it just removes 
> the reference
> all together.
> 
> If DKMS puts back the reference to the obsolete one, then 
> after making the
> initrd it will then put it back to the new reference.  This is so
> /etc/modules.conf remains generally consistent while your 
> module is still
> added to the DKMS tree.  Generally, I am of the opinion that 
> there should be
> one modules.conf file per kernel since each kernel has or could have
> different module configurations.  Since this is not a reality 
> now, DKMS has
> to try to do what is best and most consistent.  So with the 
> new OBSOLETES
> array, it allows for an automatic remaking of an initrd with 
> an obsolete
> reference but then makes sure to switch back 
> /etc/modules.conf to the newer
> reference because, after all, this is what is in your DKMS tree.
> 
> When you finally remove the module from your DKMS tree, only 
> then will it
> permanently remove the new reference from your tree (unless 
> your kernel has
> an original module by that name).
> 
> If you made it this far, you are likely confused, but I 
> assure you that
> after much deliberation, this is the right way to go about 
> it.  In a perfect
> world, we'd have a 1:1 ration between modules.conf files and kernels.
> 
> Gary Lerhaupt
> Dell Linux Development
> 
> _______________________________________________
> DKMS-devel mailing list
> DKMS-devel@lists.us.dell.com
> http://lists.us.dell.com/mailman/listinfo/dkms-devel
> 
> _______________________________________________
> DKMS-devel mailing list
> DKMS-devel@lists.us.dell.com
> http://lists.us.dell.com/mailman/listinfo/dkms-devel
>