LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 01-28-2009, 06:24 AM   #1
sreeharsha.t
Member
 
Registered: Jan 2009
Location: Mumbai, India
Distribution: Fedora 9, 10,11, RHEL 5
Posts: 67

Rep: Reputation: 18
Modules for SATA devices for kernel 2.8.26


Hi all,

I am trying to compile kernel 2.8.28 minimistically to work on a machine which has a SATA drive with out using any initrd image. I have compiled some SATA device driver modules into the kernel but when I boot from grub with the new kernel, it is not able to detect my harddisk and gives a kernel panic 'unable to mount root filesystem' error. The same kernel image boots up when tried on a machine with PATA harddisk.

So I guess I am missing some needed SATA modules in the new kernel...

i selected the following device drivers under
--- Serial ATA (prod) and Parallel ATA (experimental) drivers
[*] SATA Port Multiplier support

<*> AHCI SATA support

<*> Silicon Image 3124/3132 SATA support
[*] ATA SFF support

<*> Intel ESB, ICH, PIIX3, PIIX4 PATA/SATA support


and In the File systems section
I have included everything under ext2 and ext3 file systems.. My hard disk is formatted with ext3 filesystem..and my motherboard is an intel chipset..

Am i missing anything here? If so, what modules should I need to include in the kernel?

Last edited by sreeharsha.t; 01-28-2009 at 06:27 AM.
 
Old 01-28-2009, 11:01 PM   #2
Quakeboy02
Senior Member
 
Registered: Nov 2006
Distribution: Debian Linux 11 (Bullseye)
Posts: 3,407

Rep: Reputation: 141Reputation: 141
I believe you mean 2.6.28. Right?

Have you ever managed to compile a working kernel before? If yes, was it this same kernel? There is one step that needs to be taken before reinstalling the same kernel: you have to remove /lib/module/<kernel version>. Usually it's best to just rename it until you reboot into the new one, like so:
Code:
sudo mv /lib/modules/`uname -r` /lib/modules/`uname -r`.bak
Note that those are backquotes, not single quotes.

If you haven't managed to make a working kernel before, then please get that part of it working, before you try to make changes.

What distro are you using? That might help us. Did you start with the .config from your old kernel? If not, try again, using that. Also, in the .config file, the CONFIG_ATA module must be set to "*".
 
Old 01-28-2009, 11:24 PM   #3
sreeharsha.t
Member
 
Registered: Jan 2009
Location: Mumbai, India
Distribution: Fedora 9, 10,11, RHEL 5
Posts: 67

Original Poster
Rep: Reputation: 18
Hi Quakeboy02,

My bad.. I mistakenly referred to kernel 2.8.28..(which doesnt exist as of now..)and what you guessed is correct.Its 2.6.28..

I am using RHEL 5, I am not compiling this new kernel for upgrading my existing kernel. I want to build a minimal kernel which is required to run on a machine which has SATA hard disk.
I didnt start compiling the kernel from the old .config file of my existing kernel as I dont want all the modules into this new kernel, I want to make it as minimal as possible by using some utils from busybox.
I tested this newly compilied kernel on a machine which has a PATA hard disk and it worked fine. but, the same gives a kernel panic on a machine which has SATA hard disk and the reason being no partitions on the hard disk found even after including some SATA device drivers(Both machines are of same architecture-i686)

I have CONFIG_ATA set to * in the new .config which I have used for the compilation.
this is some excerpt from my .config file

# CONFIG_SCSI_DC390T is not set
# CONFIG_SCSI_NSP32 is not set
# CONFIG_SCSI_DEBUG is not set
# CONFIG_SCSI_SRP is not set
# CONFIG_SCSI_DH is not set

CONFIG_ATA=y
# CONFIG_ATA_NONSTANDARD is not set
CONFIG_SATA_PMP=y
CONFIG_SATA_AHCI=y
CONFIG_SATA_SIL24=y
CONFIG_ATA_SFF=y
# CONFIG_SATA_SVW is not set
CONFIG_ATA_PIIX=y

# CONFIG_SATA_MV is not set
# CONFIG_SATA_NV is not set
# CONFIG_PDC_ADMA is not set
# CONFIG_SATA_QSTOR is not set
# CONFIG_SATA_PROMISE is not set
# CONFIG_SATA_SX4 is not set
# CONFIG_SATA_SIL is not set
# CONFIG_SATA_SIS is not set
# CONFIG_SATA_ULI is not set
# CONFIG_SATA_VIA is not set
# CONFIG_SATA_VITESSE is not set
# CONFIG_SATA_INIC162X is not set
# CONFIG_PATA_ALI is not set
# CONFIG_PATA_AMD is not set
# CONFIG_PATA_ARTOP is not set
# CONFIG_PATA_ATIIXP is not set
# CONFIG_PATA_CMD640_PCI is not set
# CONFIG_PATA_CMD64X is not set
# CONFIG_PATA_CS5520 is not set
# CONFIG_PATA_CS5530 is not set
# CONFIG_PATA_CS5535 is not set
# CONFIG_PATA_CS5536 is not set
# CONFIG_PATA_CYPRESS is not set
# CONFIG_PATA_EFAR is not set
# CONFIG_ATA_GENERIC is not set
# CONFIG_PATA_HPT366 is not set
# CONFIG_PATA_HPT37X is not set
# CONFIG_PATA_HPT3X2N is not set
# CONFIG_PATA_HPT3X3 is not set
# CONFIG_PATA_IT821X is not set
# CONFIG_PATA_IT8213 is not set
# CONFIG_PATA_JMICRON is not set
# CONFIG_PATA_TRIFLEX is not set
# CONFIG_PATA_MARVELL is not set
# CONFIG_PATA_MPIIX is not set
# CONFIG_PATA_OLDPIIX is not set
# CONFIG_PATA_NETCELL is not set
# CONFIG_PATA_NINJA32 is not set
# CONFIG_PATA_NS87410 is not set
# CONFIG_PATA_NS87415 is not set
# CONFIG_PATA_OPTI is not set
# CONFIG_PATA_OPTIDMA is not set
# CONFIG_PATA_PDC_OLD is not set
# CONFIG_PATA_RADISYS is not set
# CONFIG_PATA_RZ1000 is not set
# CONFIG_PATA_SC1200 is not set
# CONFIG_PATA_SERVERWORKS is not set
# CONFIG_PATA_PDC2027X is not set
# CONFIG_PATA_SIL680 is not set
# CONFIG_PATA_SIS is not set
# CONFIG_PATA_VIA is not set
# CONFIG_PATA_WINBOND is not set
# CONFIG_PATA_SCH is not set
# CONFIG_MD is not set
# CONFIG_FUSION is not set


Do I have to include any more modules?
 
Old 01-29-2009, 12:34 AM   #4
Quakeboy02
Senior Member
 
Registered: Nov 2006
Distribution: Debian Linux 11 (Bullseye)
Posts: 3,407

Rep: Reputation: 141Reputation: 141
Quote:
Originally Posted by sreeharsha.t View Post
I am using RHEL 5
Just to let you know, I'm a Debian user, so if I say anything that is just plain dumb when applied to RHEL, please let me know.

Quote:
I am not compiling this new kernel for upgrading my existing kernel.
My question was meant to find out if you've ever successfully compiled a kernel, and to see whether you were using a config that actually works on this machine with this kernel, to start with. Sometimes it's easier to subtract than it is to figure out what to add.

So, you could either do it that way, or we can try to figure out which things to add back. We could start with a diff of the running config and this new one, but that's probably going to be pretty large. Maybe you could do the diff and grep on ATA to narrow it down? (ATA not SATA just to be sure you're not using a PATA driver currently.) Also, do an "lspci -v" and look for the kernel module that controls your disk controller. But, my preference would be to get you running using your existing config and then work backwards. It's pretty easy to use "make xconfig" and uncheck boxes to make it minimal.

I think that has it covered for now. It's 1:30 AM, so I may not get back to this till tomorrow.
 
Old 01-29-2009, 09:46 AM   #5
sreeharsha.t
Member
 
Registered: Jan 2009
Location: Mumbai, India
Distribution: Fedora 9, 10,11, RHEL 5
Posts: 67

Original Poster
Rep: Reputation: 18
Hey, Thanks a lot..

Quote:
Originally Posted by Quakeboy02 View Post
Sometimes it's easier to subtract than it is to figure out what to add.

So, you could either do it that way, or we can try to figure out which things to add back. We could start with a diff of the running config and this new one, but that's probably going to be pretty large. Maybe you could do the diff and grep on ATA to narrow it down?
I went this way and included everything under SATA in the kernel.. and it worked!
Now.. I will subtract those SATA modules half at a time to see which one fits it.
 
Old 01-29-2009, 12:29 PM   #6
Quakeboy02
Senior Member
 
Registered: Nov 2006
Distribution: Debian Linux 11 (Bullseye)
Posts: 3,407

Rep: Reputation: 141Reputation: 141
If you will run the following command, it should tell you which module controls each bit of hardware. Just look for your disk controllers.
Code:
lspci -v
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Built-in modules for PCI devices michael_chen Linux - Kernel 0 12-03-2007 03:47 PM
SATA and mixed devices gloomy Linux - Hardware 2 07-20-2006 01:01 PM
Automatic loading of firewire modules and devices Ilici Linux - Software 1 04-09-2005 07:26 AM
Sata,no devices found,cant install any distro period! dfitzner Linux - Newbie 0 12-16-2004 11:40 AM
sarge installtion & sata devices cyberfunk Debian 1 04-19-2004 11:10 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 02:43 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration