Using OpenWrt SVN and batman-advanced SVN (yay!).
When I "opkg remove kmod-batman-adv-kernelland", the kernel module stays loaded, so when I "opkg install kmod-batman-adv-[newer version]" the old module stays loaded. A simple rmmod gets rid of the old module.
There is a script in the openwrt SVN called postinst that inserts the module after install. Very convenient. A similar script could be added, called prerm, that would remove the module before removing the ipk. There are several ways to rmmod; "rmmod -f batman-adv" might be best for removing the package.
When I create the file in my build_dir, make just deletes it, so I leave this up to someone else (Marek?).
Jake