Home page of this blog

Sunday, June 26, 2011

Custom kernel ubuntu amd64 packages optimized for i3,i5 and i7 processors

This package is created in Ubuntu 11.04 and should install fine in all versions of Ubuntu Linux 11.04 (as well 10.10) and Linux Mint 11 (as well Mint 10) (should as well in debian squeeze but not sure about dkms)

The build is for 64bit i3, i5 and i7 processors

The following are the configuration settings

  1. Kernel Timer Frequency set to 1000 HZ
  2. Processor is selected as CORE2
  3. main Makefile modified to use -Ofast of gcc 4.6
  4. Makefile and Makefile_32 modified to reflect march settings and mtune settings to corei7 (new arch of gcc 4.6)
  5. Scheduled autogroup enabled
  6. Transparent hugepage support enabled
  7. Enabled BT_L2CAP and BT_SCO bluetooth in kernel config explicitly to build bluetooth modules inside kernel
  9. Copied kernel source to /usr/src and built from /usr/src folder to avoid symlink issues with the built packages (actually when built from /home/sankaran, the built binary will have symlinks to /home/sankaran which is ludicrous)
  10. Used enterprise linux kernel config as the base config and the kernel mostly seems to have no kernel debug prints because of it. Hence it runs considerably faster than stock Ubuntu kernel (well we can feel it) (I extracted the srpm to recreate the el6 config, the el6 srpm can be downloaded from http://ftp.redhat.com/redhat/linux/enterprise/6Workstation/en/os/SRPMS/kernel-2.6.32-131.0.15.el6.src.rpm)

How to install

To install

sudo dpkg -i linux-image- linux-headers-

followed by (these steps update-initramfs and update-grub are not required for mint10 or maverick, these were required when using Ubuntu Lucid)

sudo update-initramfs -c -k

and final step of

sudo update-grub

before rebooting and reboot into the newly installed kernel from grub

How to build yourself

follow my blog on how to build kernel in ten steps at

Kernel Source

I downloaded the kernel source tarball from kernel.org



ef7057e2b1a8360b65b03d466717f03d  CONFIGCORE2SWIFT
ef068ed5219af442b483b86c15d48dba  linux-headers-
01ab3fff56f2fe706d9b61c9d15e61bb  linux-image-
b4f5f52cad36654d38e28c74d59a8e2f  Readme.odt
8558ab56c81421c53bf461978acf3bc8  Readme.pdf


c4f885c39f1c8673fa1a5b063e032a40f340c1e31e47560a5c9040ca333f1ed6  CONFIGCORE2SWIFT
d39e58af20727e50d41f0378eae9d003a4b3ced61fa31c63ae3cb2434da99c40  linux-headers-
faa9410c332c2ba3ae5e805becdb9624f2243bb55b72470a2378d1b93b069648  linux-image-
a6ea2ce8401b31b1dc8eedb3dbefbf2900e63caea0e2f0fc86be806f83827d32  Readme.odt
b0b0525d736be4fcdf06c4322727bf5b790412425da484ea6db690795127e0e4  Readme.pdf

Dropbox Links


  1. new arch in gcc 4.6 is corei7, so mtune settings should be set to corei7 not core2

  2. sorry, gave corei7 only forgot to change it in the article, thanks

  3. To compile nvidia modules, do you need to update gcc to 4.6 ?

  4. nvidia modules fail to compile with this kernel.

  5. for me it is compiling fine, i have 270.41.06 which came with Ubuntu 11.04, it may be due to the fact that I have gcc 4.6

  6. yeah it's gcc. after update it worked fine.

  7. anyone has tried with ATI cards, checked and fglrx crashed completly, right now trying .2 hope it works, testing on a fresh 11.04 install

  8. Hey, any change you can post the Makefile diffs you've made?

  9. ok I will post Makefile diffs from next build