Without conciously designing one, I don't think you'll just
run across a random object file that will pass initial sanity
checks to be loaded as a module.
> Better would be if
> modules were fully version-locked in some way, so that there was a
> high probability that if a module was incompatible with a particular
> kernel, it would not load at all.
There is a spot in both the old and new module formats to store
the version of the kernel that the module was built against. This
value _is_ checked before anything else happens.
> And, ideally, if the kernel were
> changed but still compatible with a particular module, the module
> could be loaded unchanged. (Unfortunately, I don't understand the
> module system well enough to know to what degree MODVERSIONS takes
> care of this.)
To an absurdly high degree of probability, MODVERSIONS does let
this happen safely.
r~