mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Terje Kvernes <terjekv@math.uio.no>
To: linux-kernel@vger.kernel.org
Cc: torvalds@osdl.org, akpm@osdl.org
Subject: 2.5.74 - sbp2 fails to compile, missing include of <linux/pci.h>?
Date: Wed, 09 Jul 2003 08:28:48 +0200	[thread overview]
Message-ID: <wxxadbo8b8f.fsf@nommo.uio.no> (raw)

  
  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

                 reply	other threads:[~2003-07-09  6:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=wxxadbo8b8f.fsf@nommo.uio.no \
    --to=terjekv@math.uio.no \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®