]> git.hungrycats.org Git - linux/commitdiff
[PATCH] Re: Building sym 2.1.18f on linux/alpha
authorMatthew Wilcox <willy@debian.org>
Wed, 14 Jan 2004 06:47:05 +0000 (01:47 -0500)
committerJames Bottomley <jejb@mulgrave.(none)>
Wed, 14 Jan 2004 06:47:05 +0000 (01:47 -0500)
On Tue, Jan 13, 2004 at 06:02:08PM +0300, Sergey Tikhonov wrote:
> The final kernel could not pass linking stage with 2.1.18f version
> (included into 2.6.1 kernel patch).
> The linker complains that :
> drivers/built-in.o(.init.text+0x8cec): In function 'sym2_probe':
> : undfined reference to 'local symbols in discarded section .exit.text'
>
> I compared arch/alpha/kernel/vmlinux.lds.S with one from the i386 tree.
> The '.exit.text' and '.exit.data'
> sections were moved out of DISCARD attributes in the i386 version. I did
> the same with alpha version
> and it helped.

Thanks for this report; you uncovered a real bug.  Actually two real
bugs; one is that parisc is not discarding the .init.text and .exit.text
sections (so I didn't notice this bug) and the other is that sym_detach
is marked __devexit, yet called from a __devinit function.

drivers/scsi/sym53c8xx_2/sym_glue.c

index 70b9cb911aef0a7450bb69719c7b705938ab7f6d..ced9f511c0e12a0c488ced27c78862982e3fb0d5 100644 (file)
@@ -2177,7 +2177,7 @@ sym53c8xx_pci_init(struct pci_dev *pdev, struct sym_device *device)
  *  Detach the host.
  *  We have to free resources and halt the NCR chip.
  */
-static int __devexit sym_detach(struct sym_hcb *np)
+static int sym_detach(struct sym_hcb *np)
 {
        printk("%s: detaching ...\n", sym_name(np));