LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 06-05-2006, 07:17 AM   #1
maartenvdbent
LQ Newbie
 
Registered: May 2006
Posts: 6

Rep: Reputation: 0
Slackware kernel with Serial port support as module


Note: I am very new to Linux and Slackware, so I may ask some silly questions.

Although installing Slackware wasn't that hard I encountered a problem with serial port support later on.

I installed Slackware 10.2 in a very light version on my Pentium II PC. My sound card (a C-Media CM8738 based card) and my network card work perfectly well (mpg321 plays mp3's and Links shows up the internet), but I can't get LIRC installed. The LIRC documentation says this is a common problem, and that a solution for this problem is to compile a new kernel with serial port support as a module (instead of directly compiling it into the kernel).

I compiled a few kernels but none of them seems to work for my soundcard, although LIRC installs well on the new kernels. On some of them I had internet, on some of them not.

I compiled some kernels with Sound Card support for the CM8738, but that didn't work. Then I heard somewhere that I should try to compile a kernel WITHOUT sound support and let ALSA do the job, but ALSA also wouldn't detect my card.

As I said, I am a newbie and I have the feeling I'm not that good at compiling my own kernel. As it consumes a lot of time, I get a bit tired of compiling a not working kernel all the time.

Are there any out-of-the-box kernels with serial port as a module (if there are, how do I install these?), or do you people know why my kernels don't work with sound support, so that I can compile a kernel succesfully?

Thanks in advance,

Maarten
 
Old 06-06-2006, 12:11 AM   #2
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
Welcome to LQ. Your questions arn't silly at all, you seem to have the right idea, just missing a few needed details.

Unfortunately you will need to learn to compile your kernel if you are to get the most out of Linux. I will try to address some of the issue you talked about here but I would suggest reading this post by Alien Bob for a really simple yet thorough guide.

Quote:
I compiled some kernels with Sound Card support for the CM8738, but that didn't work. Then I heard somewhere that I should try to compile a kernel WITHOUT sound support and let ALSA do the job, but ALSA also wouldn't detect my card.
As far as sound support goes, you will need to enable alsa in your kernel. the alsa-driver slackware package is specific to the kernel version you are running and will not work if you upgrade kernels. In order for it to work for me, I had to enable Sound Support, alsa, and my sound card under the alsa menu all as modules. Then you will need to run 'alsaconf' and 'alsamixer' to configure alsa with the new kernel driver.


Quote:
I compiled a few kernels but none of them seems to work for my soundcard, although LIRC installs well on the new kernels. On some of them I had internet, on some of them not.
There usually isn't much to this one, just make sure you have the right network card enabled as a module under device drivers so 'netconfig' can load it properly.


In general, the best advice given to me was don't take anything out from the kernel config until you know what you are doing. All you should be doing at this point is adding in what you know you will need.

Just post back if you need any additional help with this.

regards,
...drkstr

Last edited by drkstr; 06-06-2006 at 12:13 AM.
 
Old 06-09-2006, 03:29 PM   #3
maartenvdbent
LQ Newbie
 
Registered: May 2006
Posts: 6

Original Poster
Rep: Reputation: 0
I tried to install a new kernel but it went wrong very badly this time... I compiled a new 2.4.31 kernel (source was already installed with slackware) but I guess that because I didn't use the EXTRAVERSION in the Makefile my new kernel messed up with the old kernel, which was a 2.4.31 too (guess I'm right about this one?).

My souncard AND my network card don't work in both kernels now.

Also I didn't see any option in the kernel compile to compile ALSA with it, maybe because it's a legacy kernel?

Anyway, I guess I'm gonna reinstall Slackware again and then try the 2.6... kernel... Hopefully that kernel does have ALSA support (Yes, I will use the 2.6 kernel compile instructions instead of the instructions for 2.4).
 
Old 06-09-2006, 05:10 PM   #4
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
Quote:
I didn't use the EXTRAVERSION in the Makefile my new kernel messed up with the old kernel, which was a 2.4.31 too (guess I'm right about this one?).
This shouldn't be nesisary. If you installed the kernel source, then the source in the /usr/src directory is the same one that is installed in your system. You can configure it however many times you want, but if you want to revert back to your old configuration, you will need to back up your /boot/vmlinuz first.

Quote:
Also I didn't see any option in the kernel compile to compile ALSA with it, maybe because it's a legacy kernel?
Hardware is supported much better in the 2.6 kernel. I would recomend using it instead. I think the 2.4 kernel still support alsa, but not very well.

Quote:
My souncard AND my network card don't work in both kernels now.
Keep at it. It took me a few times before I finally got it right. Now it's as easy as brushing my teeth. Before you configure the kernel with 'make menuconfig' make sure you do a 'lspci' to view your hardware information. Use this info to select the right modules in your kernel, then compile it with
Code:
make clean && make && make modules && make modules_install && make install
Just make sure you back up your original kernel first because this will automatically install the new one.

let me know if you need any more help.
...drkstr
 
Old 06-09-2006, 05:21 PM   #5
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
The Slackware kernels do not come with ALSA (nor OSS) modules enabled. Instead, separate alsa packages are installed. What happened when you re-built your 2.4.31 kernel (indeed without giving the EXTRAVERSION a value) your "make modules_install" replaced the existing /lib/modules/2.4.31 directory tree with that of your kernel build... removing the alsa driver modules as well.
If you re-install the alsa-driver package (like this one on a mirror: http://slackware.mirrors.tds.net/pub....31-i486-1.tgz) you will at least have your sound back. Re-install using the command
Code:
upgradepkg --reinstall alsa-driver-1.0.9b_2.4.31-i486-1.tgz
What happened to the kernel module for your network card is probably you forgot to enable it in your "make menuconfig" step.
Word of advice for the novice: use a kernel configuration file that was used to generate the Slackware kernel a copy of which is stored in /boot: for instance (check the exact file name on your machine) run
Code:
cp /boot/config-ide-2.4.31 /usr/src/linux/.config
Then "cd /usr/src/linux" or wherever you have your kernel source and run a "make menuconfig". The defaults to all configurable options will now be the Slackware defaults, and you can start disabling whatever you don't need, and enabling stuff where Slackware defaults are too conservative. Read my wiki article on kernel compiling if you are interested - especially when you want to give 2.6 a try: http://www.slackware.com/~alien/doku...kernelbuilding

Eric
 
Old 06-09-2006, 05:50 PM   #6
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
Good advice Mr. Bob. I wish I had read some of your posts when I started playing around with my kernel for the first time.


Quote:
removing the alsa driver modules as well.
If you re-install the alsa-driver package (like this one on a mirror: http://slackware.mirrors.tds.net/pub....31-i486-1.tgz) you will at least have your sound back
I have always just used the kernel support for alsa since I have had better luck with it. I have always used the 2.6 kernel ..except for the brief period when I was learning what a kernel was Is alsa supported in the 2.4 kernel at all? I need to get this strait so I don't give people bum advice.

thanks!
...drkstr
 
Old 06-09-2006, 06:04 PM   #7
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Quote:
Originally Posted by drkstr
Good advice Mr. Bob. I wish I had read some of your posts when I started playing around with my kernel for the first time.
Thank you drkstr (noticed you had tried to contact me on IRC)

Quote:
I have always just used the kernel support for alsa since I have had better luck with it. I have always used the 2.6 kernel ..except for the brief period when I was learning what a kernel was Is alsa supported in the 2.4 kernel at all? I need to get this strait so I don't give people bum advice.
Indeed, ALSA was added to the kernel after 2.4 (I think somewhere in 2.5, but I never followed 2.5 development). The 2.4 kernel only has OSS.

Eric
 
Old 06-09-2006, 06:18 PM   #8
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
Quote:
Thank you drkstr (noticed you had tried to contact me on IRC)
So it was you! That was my first time on IRC. I clicked on it by accident in my Seamonkey browser and decided to check it out. I should get on it more often, you never know who you might bump into.

...drkstr
 
Old 06-10-2006, 01:29 PM   #9
maartenvdbent
LQ Newbie
 
Registered: May 2006
Posts: 6

Original Poster
Rep: Reputation: 0
I reinstalled Slackware 10.2 (without a kernel source). After the fresh install everything went fine again...

Then I followed the kernel compile instruction by Alien Bob on his Wiki. I downloaded kernel 2.6.16.18 just like Alien Bob did in his manual (from the link in the Manual), and downloaded Pat's config file (Pat's file was for kernel version 2.6.16.20, I hope that doesn't matter very much?).

I followed all the instructions, exept that I used menuconfig instead of xconfig, because I don't have the X environment installed. In menuconfig I added ALSA support and changed the CPU setting from 486 to Pentium II (which is the machine I use).

"make bzImage modules" went fine I guess, but "make modules_install" caused an error:

Code:
INSTALL arch/i386/crypto/aes-i586.ko
cp: cannot stat 'arch/i386/crypto/aes-i586.ko': No such file or directory
make[1]: *** [arch/i386/crypto/aes-i586.ko] Error 1
make: *** [_modinst_] Error 2
Can you tell me what I did wrong? And how do I compile another kernel now? I guess that will be different because I partly compiled this kernel...

Last edited by maartenvdbent; 06-10-2006 at 01:31 PM.
 
Old 06-10-2006, 01:43 PM   #10
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
Quote:
INSTALL arch/i386/crypto/aes-i586.ko
cp: cannot stat 'arch/i386/crypto/aes-i586.ko': No such file or directory
make[1]: *** [arch/i386/crypto/aes-i586.ko] Error 1
make: *** [_modinst_] Error 2
I wouldn't use a config file for a diffrent kernel version. It looks like it may have some extra stuff that isn't in the kernel you ran your 'make menuconfig' on. I would get the 2.6.16.20 kernel from kernel.org and start over.

Quote:
And how do I compile another kernel now? I guess that will be different because I partly compiled this kernel...
It doesn't really matter as long as the kernel wasn't installed (which it doesn't look like it was). It may have installed some of the modules though, so if you want to compile the 2.6.16.20 kernel you might want to 'rm -rf /lib/modules/2.6.16.18' to get rid of them.

regards
...drkstr
 
Old 06-10-2006, 02:02 PM   #11
maartenvdbent
LQ Newbie
 
Registered: May 2006
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks for the fast reply! I think I'm gonna try 2.6.16.20 then. I already am reinstalling Slackware (because I didn't know what to do and I am pretty fast at it now ). Is there a 2.6 kernel included in the Slack installation CD? I used to choose "skip" when the installation asked me what kernel to install (it installs a default kernel then) but I can try install another kernel from the beginning...

When I compiled a 2.4 kernel I used to give the commands "make dep" and "make clean", but I guess that isn't necessary for 2.6 kernels? Also, I don't have to uncomment the INSTALLPATH=/boot line in the 2.6 kernel Makefile? (I had to in 2.4 kernels)
 
Old 06-10-2006, 02:10 PM   #12
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
Quote:
Originally Posted by maartenvdbent
Thanks for the fast reply! I think I'm gonna try 2.6.16.20 then. I already am reinstalling Slackware (because I didn't know what to do and I am pretty fast at it now ). Is there a 2.6 kernel included in the Slack installation CD? I used to choose "skip" when the installation asked me what kernel to install (it installs a default kernel then) but I can try install another kernel from the beginning...

When I compiled a 2.4 kernel I used to give the commands "make dep" and "make clean", but I guess that isn't necessary for 2.6 kernels? Also, I don't have to uncomment the INSTALLPATH=/boot line in the 2.6 kernel Makefile? (I had to in 2.4 kernels)
- patrick has 2.6.16.20 in testing... you can find the binary package here... but my suggestion would be to compile yourself a stripped-down version, starting with patrick's config as a base...

(sorry if that is redundant - i haven't read the thread yet...)

- the 2.6 kernel on the slackware 10.2 cd is an old version, of course...

- AFAIK "make dep" isn't needed for 2.6...

- you don't need to edit the makefile on 2.4, and i assume on 2.6 either... what was the reason why you had to do that??

just my ...

Last edited by win32sux; 06-10-2006 at 02:17 PM.
 
Old 06-10-2006, 02:20 PM   #13
maartenvdbent
LQ Newbie
 
Registered: May 2006
Posts: 6

Original Poster
Rep: Reputation: 0
I meant an out-of-the-box kernel actually which is installed by installing slackware, but thanks anyway! But I think I'm gonna use there the same kernel as I always do. I hope I'm gonna get through with this kernel...

Just to make sure... I can use this ( http://alien.slackbook.org/dokuwiki/...kernelbuilding ) manual for an 2.6.16.20 kernel?

I skip this section:

Code:
echo $DISPLAY                  # you'll be needing this value 3 lines below
sudo -i                        # or "su -" on older Slackwares
xauth merge ~alien/.Xauthority # use your own username here instead of "alien"
export DISPLAY=:0.0            # use the value of DISPLAY you've seen 3 lines before
because I don't have the X environment installed, that isn't a problem??
And I use menuconfig instead of xconfig, that isn't a problem too?

Hope it works now,

Thanks for all the help given so far
 
Old 06-10-2006, 02:24 PM   #14
win32sux
LQ Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
Quote:
Originally Posted by maartenvdbent
because I don't have the X environment installed, that isn't a problem??
And I use menuconfig instead of xconfig, that isn't a problem too?
yeah, you should be fine if you skip any X stuff (although i honestly havent read that howto)... i also prefer to compile without X and using menuconfig... here's another howto you might like:

http://www.digitalhermit.com/linux/K...ild-HOWTO.html

Last edited by win32sux; 06-10-2006 at 02:28 PM.
 
Old 06-11-2006, 06:17 AM   #15
maartenvdbent
LQ Newbie
 
Registered: May 2006
Posts: 6

Original Poster
Rep: Reputation: 0
Still not succeeding...

I think I didn't make a mistake when compiling this time: I downloaded the 2.6.16.20 kernel source package, installed it, downloaded the generic config file from Pat, installed it, ran "oldconfig" ran "menuconfig" (added support for my soundcard and changed CPU from 486 to Pentium II), ran "make clean", ran "make bzImage" and ran "make modules".

When running "make modules_install" I got the same error as before:

Code:
INSTALL arch/i386/crypto/aes-i586.ko
cp: cannot stat 'arch/i386/crypto/aes-i586.ko': No such file or directory
make[1]: *** [arch/i386/crypto/aes-i586.ko] Error 1
make: *** [_modinst_] Error 2
I think I might know what my problem is. I think I need to install some packages that are necessary for compiling a 2.6 kernel. I run a light version of slackware with only these packages installed

Quote:
===A===
kernel-ide
gawk
glibc-zoneinfo
kbd
===AP===
alsa-utils
amp
aumix
mpg321
rexima
sox
vim
vorbistools
workbone
===D===
autoconf
automake
bin86
binutils
bison
gcc
gcc-g++
guile
kernel-headers
libtool
make
pkgconfig
pmake
===L===
alsa-driver
alsa-lib
alsa-oss
arts
audiofile
esound
glibc
glibc-i18n
libao
libid3tag
libmad
libogg
libusb
libvorbis
ncurses
svgalib
taglib
zlib
===N===
autofs
dhcpcd
dhcp
inetd
iptables
iptraf
lftp
links
lynx
netwatch
openssh
openssl
pidentd
portmap
ppp
proftpd
rp-pppoe
samba
tcpip
wget
When compiling I often get the error

Code:
cmp: command not found
I also remember linux outputting that I hadn't perl installed (which I indeed haven't).

after running "make bzImage" I got this error:

Code:
Inconsistent kallsyms data
Try setting CONFIG_KALLSYMS_EXTRA_PASS
make: *** [vmlinux] Error 1
Do I need to install some more packages before compiling a 2.6 kernel? If so, which?

Thanks in advance
 
  


Reply



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
Serial Port issues and Kernel 2.6 derryp Linux - Newbie 1 07-24-2007 04:52 PM
complie kernel for multi port serial card chai_itm Linux - Hardware 1 03-18-2005 07:05 AM
still no module support for new kernel?? linuxhippy Slackware 4 03-11-2005 03:48 PM
questions on use of serial port when debugging kernel by vmware+kgdb sunzen.w Linux - Software 0 08-05-2004 01:31 AM
Installing Slackware over a serial port using ppp spyke555 Slackware - Installation 2 01-19-2004 08:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 03:45 PM.

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