public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
* [Linux-ia64] USB driver does not build in kernel
@ 2001-12-05 13:51 Xavier Bru
  2001-12-05 18:24 ` Greg KH
  0 siblings, 1 reply; 2+ messages in thread
From: Xavier Bru @ 2001-12-05 13:51 UTC (permalink / raw)
  To: linux-ia64

Hello,

I try to build a kernel that integrates the usb-uhci driver and I get
an error at ld time (gcc 2.96 & gcc 3.0.1):

drivers/usb/usbdrv.o: In function `alloc_uhci':
drivers/usb/usbdrv.o(.text.init+0x802): relocation truncated to fit: PCREL21B uhci_pci_remove

I think this is due to uhci_pci_remove() being declared as:

_static void __devexit uhci_pci_remove (struct pci_dev *dev)

and being called by alloc_uhci().

I removed the __devexit attribute and all seems to be OK.
As __devexit should mean "only used at exit time", according to init.h.

A possible patch could be:

--- linux-2.4.16-ori/drivers/usb/usb-uhci.c	Fri Nov  9 22:41:42 2001
+++ linux-2.4.16/drivers/usb/usb-uhci.c	Wed Dec  5 14:49:40 2001
@@ -2845,7 +2845,7 @@
 	s->running = 1;
 }
 
-_static void __devexit
+_static void
 uhci_pci_remove (struct pci_dev *dev)
 {
 	uhci_t *s = pci_get_drvdata(dev);

-- 

 Sincères salutations.
_____________________________________________________________________
 
Xavier BRU                 BULL ISD/R&D/INTEL office:     FREC B1-422
tel : +33 (0)4 76 29 77 45                    http://www-frec.bull.fr
fax : +33 (0)4 76 29 77 70                 mailto:Xavier.Bru@bull.net
addr: BULL, 1 rue de Provence, BP 208, 38432 Echirolles Cedex, FRANCE
_____________________________________________________________________




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Linux-ia64] USB driver does not build in kernel
  2001-12-05 13:51 [Linux-ia64] USB driver does not build in kernel Xavier Bru
@ 2001-12-05 18:24 ` Greg KH
  0 siblings, 0 replies; 2+ messages in thread
From: Greg KH @ 2001-12-05 18:24 UTC (permalink / raw)
  To: linux-ia64

On Wed, Dec 05, 2001 at 02:51:36PM +0100, Xavier Bru wrote:
> Hello,
> 
> I try to build a kernel that integrates the usb-uhci driver and I get
> an error at ld time (gcc 2.96 & gcc 3.0.1):

A way around this is to enable CONFIG_HOTPLUG, which you probably want
to do anyway if you are using USB.  There is a better patch and
description of why this is happening on linux-kernel right now.

thanks,

greg k-h


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2001-12-05 18:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-12-05 13:51 [Linux-ia64] USB driver does not build in kernel Xavier Bru
2001-12-05 18:24 ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox