Installing kernels

AmigaOne X5000 platform specific issues related to Linux only.
Post Reply
Roland
Posts: 825
Joined: Tue May 02, 2017 7:23 am

Installing kernels

Post by Roland »

I would need some clarification about this subject... So far I have only used the 'cyrus_5020.dtb' and 'uImage-cyrus...' files (boot), and at least Ubuntu Live DVD works ok just with them. But there seems to be other files/subdirs in these kernel packages, too. Should they always be installed, or are they just some 'extra' not necessarily needed? Where should they be copied? Here is an example of the driectory three of a recent kernel pacakge:

Code: Select all

Cyrus-4.12.0-jm
---------------------
boot
  cyrus_5020_poweroff.dtb
  uImage-cyrus-4.12.0-jm

lib
  firmware
     av7110 (dir)
     cpia2 (dir)
     kaweth (dir)
     ttusb-budget (dir)
  modules
     4.12.0-X5000-jm (dir)

cyrus-4.12.0-jm.config 
System.map
Should the subdirs/files in 'lib' be copied into the respective places in 'root' partition of each distro? What if there are already similar subdirs/files (like in 'firmware') present, should they be deleted? Some Kernels also seem to have in 'firmware' an additional subdirectory level, named obviously by the version of the Kernel. In the example above there is no such level... Is there some logic behind that difference?

And how about these last two files, 'cyrus-4.12.0-jm.config' and 'System.map', where should they go?
- Roland -
Spectre660
Posts: 1525
Joined: Sat Jun 18, 2011 2:16 pm
Location: Montserrat

Re: Installing kernels

Post by Spectre660 »

@Roland

The modules and firmware provide support for some extra devices. Examples would be bluetooth and webcams and wifi dongles.
They are only loaded if a matching device is found in your system.
There is enough support built in to the kernel for most devices to operate .
To install you copy the modules directory to /libs/modules/ of your root directory.
The firmware would go to /libs/firmware/.
Don't delete the root /libs/modules or /libs//firmware directories.
You can clean up any old modules subdirectory in /libs/modules if you are no longer using that kernel version.

The cyrus-4.12.0-jm.config and System.map are for information and debugging respectively.
They are not needed by the normal user.
Sam460ex : Radeon Rx550 Single slot Video Card : SIL3112 SATA card
Roland
Posts: 825
Joined: Tue May 02, 2017 7:23 am

Re: Installing kernels

Post by Roland »

Spectre660 wrote:@Roland

The modules and firmware provide support for some extra devices. Examples would be bluetooth and webcams and wifi dongles.
They are only loaded if a matching device is found in your system.
There is enough support built in to the kernel for most devices to operate .
To install you copy the modules directory to /libs/modules/ of your root directory.
The firmware would go to /libs/firmware/.
Don't delete the root /libs/modules or /libs//firmware directories.
You can clean up any old modules subdirectory in /libs/modules if you are no longer using that kernel version.
Thanks for this clarifying info! Do you also have to compile into the Kernel some info about these additional modules, or can you just drop there new modules if needed?

There seem to be (at least in Ubuntu 16.04) also in /sys/modules similar type of harware modules... Are all these automatically available, or do you have to 'actvate' each of them in Kernel? How can you see which of them are really active, is there some tool for that?

BTW, when trying to boot openSUSE 11 with your kernels, it seemed to necessarily need at least some subdirectory (in libs) which is used for those modules. Did not yet test whether it also needs some files...
- Roland -
Spectre660
Posts: 1525
Joined: Sat Jun 18, 2011 2:16 pm
Location: Montserrat

Re: Installing kernels

Post by Spectre660 »

The kernel is built with and index of the modules to be included that individual kernel version.
Once installed in /lib/modules the modules are available for the kernel to load once the matching device is found.
if you need modules that were not included for a kernel version then usually you recompile a new version of the kernel with the required modules included or in some cases removed.

A matching /lib/modules directory for the kernel that you are using is sometimes required as you would have noticed with the openSUSE 11 .
My ramdisk installers for Ubuntu and Debian use a pre installation script entry to create an empty /lib/modules directory matching the kernel version that is being used before the main installation begins .


Roland wrote:
Spectre660 wrote:@Roland

The modules and firmware provide support for some extra devices. Examples would be bluetooth and webcams and wifi dongles.
They are only loaded if a matching device is found in your system.
There is enough support built in to the kernel for most devices to operate .
To install you copy the modules directory to /libs/modules/ of your root directory.
The firmware would go to /libs/firmware/.
Don't delete the root /libs/modules or /libs//firmware directories.
You can clean up any old modules subdirectory in /libs/modules if you are no longer using that kernel version.
Thanks for this clarifying info! Do you also have to compile into the Kernel some info about these additional modules, or can you just drop there new modules if needed?

There seem to be (at least in Ubuntu 16.04) also in /sys/modules similar type of harware modules... Are all these automatically available, or do you have to 'actvate' each of them in Kernel? How can you see which of them are really active, is there some tool for that?

BTW, when trying to boot openSUSE 11 with your kernels, it seemed to necessarily need at least some subdirectory (in libs) which is used for those modules. Did not yet test whether it also needs some files...
Sam460ex : Radeon Rx550 Single slot Video Card : SIL3112 SATA card
Post Reply