Jump to content
XPEnology Community

Kernel Sources 3.10 released


haydibe

Recommended Posts

They compile well with some warning , usefull to add new drivers not included in standard synology distribution.

A usefull kernel module is config.ko, it exports kernel config into /proc

 

Do you compile using their scripts/tools? It would've being great if you could write some instructions on what is needed to compile the kernel from source.

Link to comment
Share on other sites

They compile well with some warning , usefull to add new drivers not included in standard synology distribution.

A usefull kernel module is config.ko, it exports kernel config into /proc

 

Do you compile using their scripts/tools? It would've being great if you could write some instructions on what is needed to compile the kernel from source.

I will arrange a Howto in the afternoon

Link to comment
Share on other sites

They compile well with some warning , usefull to add new drivers not included in standard synology distribution.

A usefull kernel module is config.ko, it exports kernel config into /proc

 

Do you compile using their scripts/tools? It would've being great if you could write some instructions on what is needed to compile the kernel from source.

I will arrange a Howto in the afternoon

 

Much appreciated. :cool:

Link to comment
Share on other sites

They compile well with some warning , usefull to add new drivers not included in standard synology distribution.

A usefull kernel module is config.ko, it exports kernel config into /proc

 

Do you compile using their scripts/tools? It would've being great if you could write some instructions on what is needed to compile the kernel from source.

I will arrange a Howto in the afternoon

 

Would be very nice :smile:

Link to comment
Share on other sites

First of all, this howto will not cover making a booloader, it covers only making modules.

What we need?

Only one linux box, not important which distro, and, of course, your knwoledge in linux.

I use Centos7 so my screen is related to centos, and i don't use any window manager, only console.

refer to your distro and install all packets needed for kernel compiling.

 

We need only two pieces, toolchains and kernel source.

First, make a folder where downoload packages will downloaded

in my case i use my root home.

-rw-r--r--.  1 root root 300814480 14 mar 04.25 braswell-gcc493_glibc220_linaro_x86_64-GPL.tar
-rw-r--r--.  1 root root  78099976 15 mar 04.46 linux-3.10.x.txz
root@dev-linux:~#

And, link for that

https://downloads.sourceforge.net/project/dsgpl/Synology%20NAS%20GPL%20Source/15047branch/braswell-source/linux-3.10.x.txz?r=https%3A%2F%2Fsourceforge.net%2Fprojects%2Fdsgpl%2Ffiles%2FSynology%2520NAS%2520GPL%2520Source%2F15047branch%2Fbraswell-source%2F&ts=1490265668&use_mirror=netix

https://downloads.sourceforge.net/project/dsgpl/DSM%206.1%20Tool%20Chains/Intel%20x86%20Linux%203.10.102%20%28Braswell%29/braswell-gcc493_glibc220_linaro_x86_64-GPL.txz?r=https%3A%2F%2Fsourceforge.net%2Fprojects%2Fdsgpl%2Ffiles%2FDSM%25206.1%2520Tool%2520Chains%2FIntel%2520x86%2520Linux%25203.10.102%2520%2528Braswell%2529%2F&ts=1490265766&use_mirror=netix

use wget and rename files at the and of download.

As you can see we have toolchain and source.

 

Go into /usr/local and expand toolchains to obtain something like this

root@dev-linux:/usr/local#ls -l
totale 94104
drwxr-xr-x. 3 root root       17  5 nov 16.38 bin
drwxr-xr-x. 8 root root     4096 15 ago  2013 x86_64-pc-linux-gnu
root@dev-linux:/usr/local#

As you can see we have a folder called

drwxr-xr-x. 8 root root     4096 15 ago  2013 x86_64-pc-linux-gnu

In which there is all we need to compile.

I don't like digit long comman, so i added an alias to my .bashrc

alias dsm6.1make='make ARCH=x86_64 CROSS_COMPILE=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-'

As you know, if you choose another folder, you have to reflect the name of the folder as you can see in alias.

Now we unpack kernel source, it's' not important where you expand source, in my case kernel fodler is in my home ( root in my case, yes, i'm almost insane to work as root :grin: )

root@dev-linux:~#ls -l
totale 546856
drwxr-xr-x. 26 root root      4096 21 mar 18.37 linux-3.10.x
root@dev-linux:~#

Now, the fun part, in kernel source there is a folder where are located several config already prepared by Synology

root@dev-linux:~/linux-3.10.x/synoconfigs#ls -l
totale 1044
-rwxr-xr-x. 1 root root 104078 23 feb 13.42 avoton
-rw-r--r--. 1 root root  42522 14 feb 17.25 back-porting-records
-rw-r--r--. 1 root root 105510 23 feb 13.42 braswell
-rw-r--r--. 1 root root 105948 23 feb 13.42 broadwell
-rw-r--r--. 1 root root 105611 23 feb 13.42 bromolow
-rw-r--r--. 1 root root 103555 23 feb 13.42 cedarview
-rw-r--r--. 1 root root 103184 23 feb 13.42 dockerx64
-rw-r--r--. 1 root root 106337 23 feb 13.42 grantley
-rw-r--r--. 1 root root    317 15 mar 04.35 Kconfig
-rwxr-xr-x. 1 root root   5842 15 mar 04.35 Kconfig.basic
-rw-r--r--. 1 root root  22639 15 mar 04.35 Kconfig.devices
-rw-r--r--. 1 root root  18956 15 mar 04.35 Kconfig.fs
-rw-r--r--. 1 root root   2068 15 mar 04.35 Kconfig.misc
-rw-r--r--. 1 root root   1492 15 mar 04.35 Kconfig.network
-rw-r--r--. 1 root root    922 15 mar 04.35 Kconfig.platform
-rw-r--r--. 1 root root 104946 23 feb 13.42 kvmx64
-rw-r--r--. 1 root root 101368 23 feb 13.42 x86_64
root@dev-linux:~/linux-3.10.x/synoconfigs#

As you can see we have brasweel, broadwell and bromolow, so choose right config that reflect you system.

at now simple copy one file into . config in upper folder

root@dev-linux:~/linux-3.10.x/synoconfigs#cp braswell ../.config

Notice, in every unix syste, filename with "." ( dot ) for firts character, means hidden file, and can be showed using command ls -a -l to have liisting view

root@dev-linux:~/linux-3.10.x#ls -a -l
totale 50540
drwxr-xr-x.  26 root root     4096 28 mar 13.50 .
dr-xr-x---.  14 root root     4096 28 mar 13.49 ..
drwxr-xr-x.  33 root root     4096 16 mar 16.48 arch
drwxr-xr-x.   3 root root     4096 21 mar 17.24 block
-rw-r--r--.   1 root root   105510 28 mar 13.50 .config
-rw-r--r--.   1 root root    18693 29 lug  2015 COPYING
-rw-r--r--.   1 root root    95317 29 lug  2015 CREDITS
drwxr-xr-x.   5 root root     8192 21 mar 18.37 crypto
root@dev-linux:~/linux-3.10.x#

as you can see there is a file named .config that is a clean config file used by synology.

At this moment we have to run kernel configuration simply running our alias alreadi defined in our .bashrc and proced with regular ketnel config like we want.

root@dev-linux:~/linux-3.10.x#dsm6.1make menuconfig

at end of you configuration, run compilation via

root@dev-linux:~/linux-3.10.x#dsm6.1make modules

At end of compilation you have all modules compiled in several folder, they are named something.ko

To have a complete list of modules you can use find to found every .ko and copy them into some folder, for example, /root/newmodules/

root@dev-linux:~#find ./linux-3.10.x/ -iname "*.ko" -type f -exec cp -p {} ./newmodules/ \;

in folder HOME/newmodules, there are all new compiled modules, or, if you know which modules you need, you can simply scp in your nas.

 

I hope is clear, if you find some errors, or something you don't understand, let me know.

I'm not native English speaking, so it's highly possibile there are some grammar errors :grin: so, be patient

 

Thanks

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...