mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* 2.5.74 - sbp2 fails to compile, missing include of <linux/pci.h>?
@ 2003-07-09  6:28 Terje Kvernes
  0 siblings, 0 replies; only message in thread
From: Terje Kvernes @ 2003-07-09  6:28 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, akpm

  
  without adding the inclusion of <linux/pci.h> in
  drivers/ieee1394/sbp2.c I am unable to build the module (see below
  for a patch):

[x200 /usr/src/linux-2.5.74] # make modules
make[1]: `arch/i386/kernel/asm-offsets.s' is up to date.
  CC [M]  drivers/ieee1394/sbp2.o
drivers/ieee1394/sbp2.c: In function `sbp2util_create_command_orb_pool':
drivers/ieee1394/sbp2.c:422: warning: implicit declaration of function
`pci_map_single'
drivers/ieee1394/sbp2.c:424: `PCI_DMA_BIDIRECTIONAL' undeclared (first use in
this function)
drivers/ieee1394/sbp2.c:424: (Each undeclared identifier is reported only once
drivers/ieee1394/sbp2.c:424: for each function it appears in.)
drivers/ieee1394/sbp2.c: In function `sbp2util_remove_command_orb_pool':
drivers/ieee1394/sbp2.c:454: warning: implicit declaration of function
`pci_unmap_single'
drivers/ieee1394/sbp2.c:456: `PCI_DMA_BIDIRECTIONAL' undeclared (first use in
this function)
drivers/ieee1394/sbp2.c: In function `sbp2util_free_command_dma':
drivers/ieee1394/sbp2.c:567: warning: implicit declaration of function
`pci_unmap_page'
drivers/ieee1394/sbp2.c:576: warning: implicit declaration of function
`pci_unmap_sg'
drivers/ieee1394/sbp2.c: In function `sbp2_start_device':
drivers/ieee1394/sbp2.c:817: warning: implicit declaration of function
`pci_alloc_consistent'
drivers/ieee1394/sbp2.c:818: warning: assignment makes pointer from integer
without a cast
drivers/ieee1394/sbp2.c:826: warning: assignment makes pointer from integer
without a cast
drivers/ieee1394/sbp2.c:834: warning: assignment makes pointer from integer
without a cast
drivers/ieee1394/sbp2.c:842: warning: assignment makes pointer from integer
without a cast
drivers/ieee1394/sbp2.c:850: warning: assignment makes pointer from integer
without a cast
drivers/ieee1394/sbp2.c:858: warning: assignment makes pointer from integer
without a cast
drivers/ieee1394/sbp2.c:862: warning: implicit declaration of function
`pci_free_consistent'
drivers/ieee1394/sbp2.c: In function `sbp2_create_command_orb':
drivers/ieee1394/sbp2.c:1837: warning: implicit declaration of function
`pci_map_page'
drivers/ieee1394/sbp2.c:1850: warning: implicit declaration of function `pci_map_sg'
drivers/ieee1394/sbp2.c: In function `sbp2_link_orb_command':
drivers/ieee1394/sbp2.c:2015: warning: implicit declaration of function
`pci_dma_sync_single'
drivers/ieee1394/sbp2.c:2017: `PCI_DMA_BIDIRECTIONAL' undeclared (first use in
this function)
drivers/ieee1394/sbp2.c: In function `sbp2_handle_status_write':
drivers/ieee1394/sbp2.c:2447: `PCI_DMA_BIDIRECTIONAL' undeclared (first use in
this function)
drivers/ieee1394/sbp2.c: In function `sbp2scsi_complete_all_commands':
drivers/ieee1394/sbp2.c:2639: `PCI_DMA_BIDIRECTIONAL' undeclared (first use in
this function)
drivers/ieee1394/sbp2.c: In function `sbp2scsi_abort':
drivers/ieee1394/sbp2.c:2798: `PCI_DMA_BIDIRECTIONAL' undeclared (first use in
this function)
make[2]: *** [drivers/ieee1394/sbp2.o] Error 1
make[1]: *** [drivers/ieee1394] Error 2
make: *** [drivers] Error 2

  however, a similar problem exists in drivers/message/i2o/i2o_scsi.c,
  where the module will compile, but complain about missing symbols.
  this problem is also solved by including linux/pci.h.

  I'm unsure if this is a problem that should be solved at a higher
  level somewhere?  otherwise, here are the patches for
  drivers/ieee1394/sbp2.c and for drivers/message/i2o/i2o_scsi.c.  

--- sbp2.c.orig 2003-07-09 08:09:41.334346927 +0200
+++ sbp2.c      2003-07-09 07:39:18.675714299 +0200
@@ -54,6 +54,7 @@
 #include <linux/proc_fs.h>
 #include <linux/blk.h>
 #include <linux/smp_lock.h>
+#include <linux/pci.h>
 #include <linux/init.h>
 #include <linux/version.h>
 #include <asm/current.h>

--- i2o_scsi.c.orig     2003-07-09 08:24:10.509751640 +0200
+++ i2o_scsi.c  2003-07-09 07:55:53.926397019 +0200
@@ -49,6 +49,7 @@
 #include <linux/delay.h>
 #include <linux/proc_fs.h>
 #include <linux/prefetch.h>
+#include <linux/pci.h>
 #include <asm/dma.h>
 #include <asm/system.h>
 #include <asm/io.h>
  
-- 
Terje

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-07-09  6:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-09  6:28 2.5.74 - sbp2 fails to compile, missing include of <linux/pci.h>? Terje Kvernes

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

all inboxes | Powered by JetHome®