From: Herbert Xu <herbert@gondor.apana.org.au>
To: Matt Mackall <mpm@selenic.com>,
Rusty Russell <rusty@rustcorp.com.au>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: hwrng: virtio - Rename driver object to remove section mismatch warning
Date: Fri, 11 Dec 2009 23:36:58 +0800 [thread overview]
Message-ID: <20091211153658.GA1207@gondor.apana.org.au> (raw)
Hi:
Finally found the cause of the section mismatch warning in hwrng.
Apparently in addition to __devexit_p we now have to name the
variable in a certain way.
I'll add this patch.
commit 8afb602bb676ed7da3cba154f2f5edf3971a582b
Author: Herbert Xu <herbert@gondor.apana.org.au>
Date: Fri Dec 11 23:35:06 2009 +0800
hwrng: virtio - Rename driver object to remove section mismatch warning
The section mismatch warning shows up unless the __devexit referencing
variable is named in a certain way.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
diff --git a/drivers/char/hw_random/virtio-rng.c b/drivers/char/hw_random/virtio-rng.c
index bdaef8e..64fe0a7 100644
--- a/drivers/char/hw_random/virtio-rng.c
+++ b/drivers/char/hw_random/virtio-rng.c
@@ -114,7 +114,7 @@ static struct virtio_device_id id_table[] = {
{ 0 },
};
-static struct virtio_driver virtio_rng = {
+static struct virtio_driver virtio_rng_driver = {
.driver.name = KBUILD_MODNAME,
.driver.owner = THIS_MODULE,
.id_table = id_table,
@@ -124,12 +124,12 @@ static struct virtio_driver virtio_rng = {
static int __init init(void)
{
- return register_virtio_driver(&virtio_rng);
+ return register_virtio_driver(&virtio_rng_driver);
}
static void __exit fini(void)
{
- unregister_virtio_driver(&virtio_rng);
+ unregister_virtio_driver(&virtio_rng_driver);
}
module_init(init);
module_exit(fini);
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
next reply other threads:[~2009-12-11 15:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-11 15:36 Herbert Xu [this message]
2009-12-11 19:25 ` hwrng: virtio - Rename driver object to remove section mismatch warning Matt Mackall
2009-12-11 20:08 ` Randy Dunlap
2009-12-12 0:21 ` Sam Ravnborg
2009-12-12 0:33 ` Matt Mackall
2009-12-12 7:21 ` Sam Ravnborg
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=20091211153658.GA1207@gondor.apana.org.au \
--to=herbert@gondor.apana.org.au \
--cc=linux-kernel@vger.kernel.org \
--cc=mpm@selenic.com \
--cc=rusty@rustcorp.com.au \
/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;
as well as URLs for NNTP newsgroup(s).