Message ID | 1257409037-29916-1-git-send-email-u.kleine-koenig@pengutronix.de |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
From: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Date: Thu, 5 Nov 2009 09:17:17 +0100 > Commit > > 3d1285b (move virtnet_remove to .devexit.text) > > introduced the first reference to __devexit in struct virtio_driver > virtio_net which upset modpost ("Section mismatch in reference from the > variable virtio_net to the function .devexit.text:virtnet_remove()"). > > Fix this by renaming virtio_net to virtio_net_driver. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> > Reported-by: Michael S. Tsirkin <mst@redhat.com> > Blame-taken-by: Rusty Russell <rusty@rustcorp.com.au> Applied, thanks. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index 05630f2..b9e002f 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -998,7 +998,7 @@ static unsigned int features[] = { VIRTIO_NET_F_CTRL_RX, VIRTIO_NET_F_CTRL_VLAN, }; -static struct virtio_driver virtio_net = { +static struct virtio_driver virtio_net_driver = { .feature_table = features, .feature_table_size = ARRAY_SIZE(features), .driver.name = KBUILD_MODNAME, @@ -1011,12 +1011,12 @@ static struct virtio_driver virtio_net = { static int __init init(void) { - return register_virtio_driver(&virtio_net); + return register_virtio_driver(&virtio_net_driver); } static void __exit fini(void) { - unregister_virtio_driver(&virtio_net); + unregister_virtio_driver(&virtio_net_driver); } module_init(init); module_exit(fini);
Commit 3d1285b (move virtnet_remove to .devexit.text) introduced the first reference to __devexit in struct virtio_driver virtio_net which upset modpost ("Section mismatch in reference from the variable virtio_net to the function .devexit.text:virtnet_remove()"). Fix this by renaming virtio_net to virtio_net_driver. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reported-by: Michael S. Tsirkin <mst@redhat.com> Blame-taken-by: Rusty Russell <rusty@rustcorp.com.au> Cc: Sam Ravnborg <sam@ravnborg.org> Cc: David S. Miller <davem@davemloft.net> Cc: Alex Williamson <alex.williamson@hp.com> Cc: Mark McLoughlin <markmc@redhat.com> Cc: netdev@vger.kernel.org --- Hello, @Rusty: IMHO there's no need to apologize. The driver was enhanced by 3d1285b and I consider it OK not to notice the (false) section warning. (But if you think it was you who took my first patch, then you forgot to add you S-o-b which is a worse trespass :-) Best regards Uwe drivers/net/virtio_net.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-)