From: dwalker@mvista.com
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org
Cc: James.Bottomley@steeleye.com
Subject: [PATCH -mm] scsi: compile error on module_refcount
Date: Sat, 09 Sep 2006 09:26:35 -0700 [thread overview]
Message-ID: <20060909162635.746696000@mvista.com> (raw)
Fixes the following compile error,
LD .tmp_vmlinux1
drivers/built-in.o(.text+0x8e1f9): In function `scsi_device_put':
drivers/scsi/scsi.c:887: undefined reference to `module_refcount'
make: *** [.tmp_vmlinux1] Error 1
There are only two users of module_refcount() outside of kernel/module.c
and the other one uses ifdef's similar to this.
---
drivers/scsi/scsi.c | 2 ++
1 files changed, 2 insertions(+)
Index: linux-2.6.17/drivers/scsi/scsi.c
===================================================================
--- linux-2.6.17.orig/drivers/scsi/scsi.c
+++ linux-2.6.17/drivers/scsi/scsi.c
@@ -882,10 +882,12 @@ void scsi_device_put(struct scsi_device
{
struct module *module = sdev->host->hostt->module;
+#ifdef CONFIG_MODULE_UNLOAD
/* The module refcount will be zero if scsi_device_get()
* was called from a module removal routine */
if (module && module_refcount(module) != 0)
module_put(module);
+#endif
put_device(&sdev->sdev_gendev);
}
EXPORT_SYMBOL(scsi_device_put);
--
next reply other threads:[~2006-09-09 16:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-09 16:26 dwalker [this message]
2006-09-09 16:31 ` Daniel Walker
2006-09-09 16:48 ` James Bottomley
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=20060909162635.746696000@mvista.com \
--to=dwalker@mvista.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.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®