LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 07-31-2003, 01:42 PM   #1
taids
Member
 
Registered: Jul 2003
Location: Wales, UK
Distribution: Slackware/Ubuntu/iWhax
Posts: 31

Rep: Reputation: 15
Question Kernel compile error/system hangs, APIC/ACPI


Hey,

First off, sorry if this is an unappropriate area to post, but I feel that ACPI is kind of hardware related, and a lot of other questions to do with it seemed to appear in the search results under this area.

Anyways, my problem....

In short:

2.4.21 kernel (+ACPI 2.4.21 patch) compiles but system hangs on boot, 2.4.21 kernel (+ACPI 2.4.21 patch) won't compile with APIC support disabled

Detailed explanation:

In an effort to get power management (specifically some kind of battery monitor/status indicator) support under Linux on my laptop, I looked into kernel compilation to add support for my requirements..

I installed Slackware 9; this prooved to be the best distribution I had found for the most support (devices, full screen console, etc), but running anything to do with APM would give errors stating that there was no APM support in the kernel.

anyway, after recompiling my kernel with APM support, I found out that what I needed was ACPI support instead, so I downloaded the ACPI 2.4.21 patch for my kernel, and applied it, then recompiled with ACPI support.

This all went well until I rebooted with the new kernel. Now it hangs on a line saying:

Executing all Device _STA and_INI Methods:....

after some research, I read that some people suggested disabling Local APIC support in the kernel and it should sort the problem. I re-ran the kernel configurator, and couldn't find any options for APIC, so I manually edited the .config file, and found the line:
CONFIG_X86_LOCAL_APIC=y

and changed it to

CONFIG_X86_LOCAL_APIC=n

make dep, make modules, and make modules_install all go smoothly without any errors, but make bzImage goes fine for a while but then chokes with loads of errors, which all appear to be undefined reference to '<some function>' in kernel.o (and also some other files like lib.a and drivers.o)

can anyone suggest a fix for this problem, or a work around? or any reasons for the problem occuring?

Brief details of my hardware/software:

Slackware 9 (stable)
Compaq/HP Evo nx9005
Athlon XP 2000+
256MB RAM


I can supply more detailed information/output if necessary,
Thanks in advance.
 
Old 08-01-2003, 12:39 PM   #2
taids
Member
 
Registered: Jul 2003
Location: Wales, UK
Distribution: Slackware/Ubuntu/iWhax
Posts: 31

Original Poster
Rep: Reputation: 15
alas no luck

I'm still no closer to finding a solution to this problem, so I'm downloading the 2.4.18 kernel and I'm hoping it will compile with no problems; perhaps I should go for a newer kernel instead, but they still seem to be in development.

Maybe there is another solution for the kernel hanging problem, rather than trying to disable local APIC?

Initially, I thought I had success by telling the kernel to use a second PCI configuration (in LILO):
append "pci=conf2"

The kernel didn't hang and booted up normally, but only later did I realise that it was booting because the PCI devices weren't initialising at all. Does this means the problem is PCI related? I've also tried things such as pci=noacpi, noapic, but they don't help either

Any suggestions/advice greatly appreciated!
 
Old 08-01-2003, 02:24 PM   #3
taids
Member
 
Registered: Jul 2003
Location: Wales, UK
Distribution: Slackware/Ubuntu/iWhax
Posts: 31

Original Poster
Rep: Reputation: 15
Well, I've now tried to compile with 2.4.18 kernel, and I am getting the same errors, so I'm not really sure what my next course of action is....

Heres some of the output if anyone can advise on it...

net/network.o(.text+0x22bd): In function `socket_get_info':
: undefined reference to `smp_num_cpus'
net/network.o(.text+0x248b): In function `_text_lock_socket':
: undefined reference to `kernel_flag'
net/network.o(.text+0x875d): In function `dev_proc_stats':
: undefined reference to `smp_num_cpus'
net/network.o(.text+0x8816): In function `dev_proc_stats':
: undefined reference to `smp_num_cpus'
net/network.o(.text+0x123cd): In function `rt_cache_stat_get_info':
: undefined reference to `smp_num_cpus'
net/network.o(.text+0x12490): In function `rt_cache_stat_get_info':
: undefined reference to `smp_num_cpus'
net/network.o(.text+0x16842): In function `fold_prot_inuse':
: undefined reference to `smp_num_cpus'
net/network.o(.text+0x16983): more undefined references to `smp_num_cpus' follow
net/network.o(.text+0x4dd5e): In function `rpciod':
: undefined reference to `kernel_flag'
net/network.o(.text+0x4e894): In function `_text_lock_sched':
: undefined reference to `kernel_flag'
/root/kernelstuff/linux-2.4.18/arch/i386/lib/lib.a(delay.o)(.text+0x8c): In func
tion `__udelay':
: undefined reference to `cpu_data'
/root/kernelstuff/linux-2.4.18/arch/i386/lib/lib.a(delay.o)(.text+0xb6): In func
tion `__const_udelay':
: undefined reference to `cpu_data'
/root/kernelstuff/linux-2.4.18/lib/lib.a(brlock.o)(.text+0x4): In function `__br
_write_lock':
: undefined reference to `smp_num_cpus'
/root/kernelstuff/linux-2.4.18/lib/lib.a(brlock.o)(.text+0x20): In function `__b
r_write_lock':
: undefined reference to `smp_num_cpus'
/root/kernelstuff/linux-2.4.18/lib/lib.a(brlock.o)(.text+0x34): In function `__b
r_write_unlock':
: undefined reference to `smp_num_cpus'
/root/kernelstuff/linux-2.4.18/lib/lib.a(brlock.o)(.text+0x4e): In function `__b
r_write_unlock':
: undefined reference to `smp_num_cpus'
make: *** [vmlinux] Error 1

 
Old 08-09-2003, 02:59 PM   #4
Minoru
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
I have the same problem as you in a HP Pavilion ze4334EA laptop. I've compiled kernel-2.4.18, 2.4.20, 2.4.21, 2.6.0-test1 and 2.6.0-test2 in order to find a functional kernel with acpi support (I thought that was a kernel version problem), but the kernel hangs on boot showing:

Executing all Device _STA and_INI Methods:....


Note: In windows works perfectly
 
Old 08-09-2003, 06:07 PM   #5
taids
Member
 
Registered: Jul 2003
Location: Wales, UK
Distribution: Slackware/Ubuntu/iWhax
Posts: 31

Original Poster
Rep: Reputation: 15
Indeed, Wind0ws was indeed fine.

I'm sure the solution is as simple as just including the missing (header?) files somewhere before it gets compiled. I'm not sure exactly which file(s), but I've done some searching through the source and usually for each function with an error, it comes up with between 1 - 5 files, e.g.

grep -l -r "undefined_ref_name_here" /usr/src/linux/*

I haven't had any luck in finding a patch for any version of the kernel source, via google. Geocrawler has some kind of useful archives, but no actual solution (that I've found)

alas.
 
Old 08-11-2003, 10:20 AM   #6
Minoru
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
I am begining to think that there's no solution xDD. Maybe nobody else knows this problem. What will we do? I can't program something like ACPI xDDDDD (but anyway, I've started to read the kernel code).
---NEED HELP!!!!!---
 
Old 08-11-2003, 10:36 AM   #7
Zappa
LQ Newbie
 
Registered: Jul 2003
Location: Sweden
Distribution: Slackware
Posts: 19

Rep: Reputation: 0
I've got a Compaq EVO N610c and it runs with the 2.4.21 kernel with full ACPI support within the kernel, so far no problems at all.

All I did was gettin the lastest kernel from Slackware and config it and recompile.

/Zappa
 
Old 08-11-2003, 11:21 AM   #8
Minoru
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
I did de same in debian, but it didnīt work. Nothing else...
 
Old 08-11-2003, 03:29 PM   #9
taids
Member
 
Registered: Jul 2003
Location: Wales, UK
Distribution: Slackware/Ubuntu/iWhax
Posts: 31

Original Poster
Rep: Reputation: 15
if this is any use

I've got a full list of errors churned out by make bzImage, using:

make bzImage 2> errors.txt

Hope that helps (if anyone is on their way to a solution)
 
Old 08-11-2003, 03:50 PM   #10
Minoru
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
I don't remember my bzImage compiling with so many errors. Anyway, the result is the same xDDDD :

Executing all Device _STA and_INI Methods:....
(and then: x_x )

This is scary xDD.
 
Old 08-20-2003, 08:25 AM   #11
Minoru
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
Still doesn't work

I tried to use kernel-2.6.0-test1, test2 and test3 and after compiling, the result is the same . Has anybody solved his problem? I think that there won't be ACPI support in my laptop (...uinstall linux??.... ).
 
Old 08-20-2003, 09:57 AM   #12
adz
Senior Member
 
Registered: Jun 2003
Location: Sydney
Distribution: Debian, FreeBSD
Posts: 1,713

Rep: Reputation: 53
I don't think this will cause hangs but if you enable symmetric multiprocessing then it disables APM and possibly even ACPI (even if you ony have one processor). A possibility however slim.
 
Old 08-20-2003, 12:16 PM   #13
taids
Member
 
Registered: Jul 2003
Location: Wales, UK
Distribution: Slackware/Ubuntu/iWhax
Posts: 31

Original Poster
Rep: Reputation: 15
Talking The solution....

Well, I think I've found the solution, but I can't say for sure, I can only say that it seems to have solved the problems for me....

if you get a newer version of the kernel source (I got 2.4.22-pre9 patch, due to getting some new Netgear WG511 wireless card drivers working), there is an option for 'relaxed AML checking', enabling this (under the ACPI settings), seems to stop the kernel from hanging at boot after that message! which means that the system boots, and most of the ACPI stuff works! and you don't need to disable any of the APIC stuff at all

I'm still having a few problems, since some of the ACPI stuff isn't working, like I can't get the battery charge percentage via /proc/acpi, but under X, battery charge monitors work, like gnome battery applet, and KDE laptop monitor (kdelaptopdeamon?)

I hope this works for you all.
 
Old 08-21-2003, 03:31 PM   #14
helmut_hed
Member
 
Registered: Jul 2003
Location: San Francisco, CA, USA
Distribution: Kubuntu Hardy
Posts: 103

Rep: Reputation: 15
Yikes, sorry to hear about your troubles.
My SuSE 8.2 works fine on my laptop with acpi enabled, battery indicator working, etc. I have an XP too. That's a 2.4.20 kernel.
I can look at parameters if you want...
 
Old 08-23-2003, 06:11 AM   #15
Minoru
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
YES! IT WORKS!

With kernel-2.4.22-pre9 it seems to work. I can get the battery charge percentage both in console mode and in KDE. I have debian (testing, Sarge) distribution with the acpi package installed, so I can see all acpi settings with "acpi" command (temperature, battery charge, etc).

Thanks a lot!!
 
  


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
kernel: APIC error on CPU1: 02(02) Cronjob Linux - Hardware 1 03-22-2005 09:24 PM
Kernel: APIC error on CPU - What to do? robberttheman Linux - Hardware 6 01-26-2005 02:03 PM
ACPI >> APIC support / compiling kernel jmrich Linux - Newbie 2 06-30-2004 10:41 AM
To Compile my kernel with Local & IO APIC or not? haimeltjnfg Linux - Software 0 05-31-2004 01:14 PM
ACPI patch and kernel compile error crisponions Linux - Laptop and Netbook 3 10-29-2003 06:52 PM


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

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration