linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* git-scsi-misc build error
@ 2007-07-31 22:27 Andrew Morton
  2007-07-31 22:30 ` James Bottomley
  0 siblings, 1 reply; 5+ messages in thread
From: Andrew Morton @ 2007-07-31 22:27 UTC (permalink / raw)
  To: James Bottomley, FUJITA Tomonori; +Cc: linux-scsi

ERROR: "scsi_tgt_it_nexus_create" [drivers/scsi/scsi_transport_srp.ko] undefined!
ERROR: "scsi_tgt_it_nexus_destroy" [drivers/scsi/scsi_transport_srp.ko] undefined!

This bug was reported about seven times against 2.6.23-rc1-mm1's
git-scsi-target, and now it has been moved into git-scsi-misc.




From: Andrew Morton <akpm@linux-foundation.org>

- Fix this:

ERROR: "scsi_tgt_it_nexus_create" [drivers/scsi/scsi_transport_srp.ko] undefined!
ERROR: "scsi_tgt_it_nexus_destroy" [drivers/scsi/scsi_transport_srp.ko] undefined!

- Also avoid anonymous args in the function prototypes: adding the names has
  commentary value, and makes it easier to check the stubbed inline function
  against the out-of-line declaration.

Cc: James Bottomley <James.Bottomley@steeleye.com>
Cc: FUJITA Tomonori <tomof@acm.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 include/scsi/scsi_tgt.h |   19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)

diff -puN include/scsi/scsi_tgt.h~scsi-fix-build-for-config_scsi_tgt=n include/scsi/scsi_tgt.h
--- a/include/scsi/scsi_tgt.h~scsi-fix-build-for-config_scsi_tgt=n
+++ a/include/scsi/scsi_tgt.h
@@ -17,5 +17,20 @@ extern int scsi_tgt_tsk_mgmt_request(str
 extern struct scsi_cmnd *scsi_host_get_command(struct Scsi_Host *,
 					       enum dma_data_direction,	gfp_t);
 extern void scsi_host_put_command(struct Scsi_Host *, struct scsi_cmnd *);
-extern int scsi_tgt_it_nexus_create(struct Scsi_Host *, u64, char *);
-extern int scsi_tgt_it_nexus_destroy(struct Scsi_Host *, u64);
+
+#ifdef CONFIG_SCSI_TGT
+extern int scsi_tgt_it_nexus_create(struct Scsi_Host *shost, u64 itn_id,
+				char *initiator);
+extern int scsi_tgt_it_nexus_destroy(struct Scsi_Host *shost, u64 itn_id);
+#else
+static inline int scsi_tgt_it_nexus_create(struct Scsi_Host *shost,
+				u64 itn_id, char *initiator)
+{
+	return 0;
+}
+
+static inline int scsi_tgt_it_nexus_destroy(struct Scsi_Host *shost, u64 itn_id)
+{
+	return 0;
+}
+#endif
_


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

end of thread, other threads:[~2007-08-01 22:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-31 22:27 git-scsi-misc build error Andrew Morton
2007-07-31 22:30 ` James Bottomley
2007-07-31 22:41   ` Andrew Morton
2007-07-31 22:46     ` James Bottomley
2007-08-01 22:22     ` FUJITA Tomonori

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).