Bug 40123

Summary: Rebuild of custom kernel fails with 'undefined reference'
Product: [Retired] Red Hat Linux Reporter: Matthias Haase <matthias_haase>
Component: kernelAssignee: Arjan van de Ven <arjanv>
Status: CLOSED RAWHIDE QA Contact: Brock Organ <borgan>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1   
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-05-10 19:09:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Matthias Haase 2001-05-10 19:09:26 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.77 [de] (X11; U; Linux 2.4.2-2 i686)

Description of problem:
Rebuild of custom kernel from RH.7.1 kernel source rpm fails with
"arch/i386/kernel/kernel.o: In function `pci_fixup_vt8363':
arch/i386/kernel/kernel.o(.text.init+0x3727): undefined reference to
`noautodma'." Comes up always with gcc and kgcc too.

How reproducible:
Always

Steps to Reproduce:
1. cd /usr/src/linux-2.4.2
2. make xconfig
3. make dep
4. make clean
5. make bzImage fails always in all cases.
	

Actual Results:  make bzImage stops with error. No bzImage is compiled.

Expected Results:  A clean compile for custom kernels.

Additional info:

arch/i386/kernel/kernel.o: In function `pci_fixup_vt8363':
arch/i386/kernel/kernel.o(.text.init+0x3727): undefined reference to
`noautodma'.

I think - this code should fix the hardware-bug in vt8363 chips, but the
source is broken with an simple small error inside.

Comment 1 Arjan van de Ven 2001-05-10 19:23:42 UTC
Indeed. If you don't compile IDE in your kernel, you can just remove the
contents of the offending funtion (eg the reference to the noautodma) to make it
work. This is perfectly safe as for a non-IDE system you don't need the
workaround.

I've corrected this error for the next kernel we're going to release, I will 
therefore close it as "fixed in rawhide".
 
Thanks for the report!

Comment 2 Matthias Haase 2001-05-11 11:56:54 UTC
Our server is pure SCSI. I have found the function `pci_fixup_vt8363' in
/usr/scr/linux-2.4.2/arch/i368/kernel/pci-pc.c

But I'm not firm in C... Should I remove there
line 957:  extern int noautodma; 
and the following subroutine too...

static void __init pci_fixup_vt8363(struct pci_dev *d)
{

...for clean custom kernel recompiling without ATAPI/IDE?

regards
Matthias



Comment 3 Arjan van de Ven 2001-05-11 12:10:56 UTC
Not exactly. The "extern" line is fine.
Removing the function entirely will not work, you should remove everything
inside the { } (but not including the { and the }) of that function.

Comment 4 Matthias Haase 2001-05-11 13:04:37 UTC
o.k. so I have leaved the 'extern int...' call,
maked an empty and useless function
static void __init pci_fixup_vt8363(struct pci_dev *d) {
}
Compiles right now. Thanks.