Sort modules according to modules.order

Patch from SuSE by Tejun Heo <htejun@gmail.com>

Kbuild now generates and installs modules.order along with modules.
This patch updates depmod such that it sorts module list according to
the file before generating output files.  Modules which aren't on
modules.order are put after modules which are ordered by
modules.order.

This makes modprobe to prioritize modules according to kernel
Makefile's just as built-in modules are link-ordered by them.

Signed-off-by: Scott James Remnant <scott@ubuntu.com>
1 file changed