From: Stephen Hemminger <shemminger@vyatta.com>
To: davem@davemloft.net
Cc: netdev@vger.kernel.org
Subject: [PATCH net-next 7/8] virtio: make some structures const
Date: Mon, 29 Oct 2012 17:57:38 -0700 [thread overview]
Message-ID: <20121030005835.810565784@vyatta.com> (raw)
In-Reply-To: 20121030005731.843020405@vyatta.com
[-- Attachment #1: virtio-const.patch --]
[-- Type: text/plain, Size: 979 bytes --]
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
--- a/drivers/net/virtio_net.c 2012-10-26 12:27:23.911918635 -0700
+++ b/drivers/net/virtio_net.c 2012-10-26 12:52:28.632806729 -0700
@@ -1274,12 +1274,12 @@ static int virtnet_restore(struct virtio
}
#endif
-static struct virtio_device_id id_table[] = {
+static const struct virtio_device_id id_table[] = {
{ VIRTIO_ID_NET, VIRTIO_DEV_ANY_ID },
{ 0 },
};
-static unsigned int features[] = {
+static const unsigned int features[] = {
VIRTIO_NET_F_CSUM, VIRTIO_NET_F_GUEST_CSUM,
VIRTIO_NET_F_GSO, VIRTIO_NET_F_MAC,
VIRTIO_NET_F_HOST_TSO4, VIRTIO_NET_F_HOST_UFO, VIRTIO_NET_F_HOST_TSO6,
@@ -1290,7 +1290,7 @@ static unsigned int features[] = {
VIRTIO_NET_F_GUEST_ANNOUNCE,
};
-static struct virtio_driver virtio_net_driver = {
+static struct virtio_driver virtio_net_driver __read_mostly = {
.feature_table = features,
.feature_table_size = ARRAY_SIZE(features),
.driver.name = KBUILD_MODNAME,
next prev parent reply other threads:[~2012-10-30 1:06 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-30 0:57 [PATCH net-next 0/8] bridge: new security features Stephen Hemminger
2012-10-30 0:57 ` [PATCH net-next 1/8] bridge: bridge port parameters over netlink Stephen Hemminger
2012-10-30 18:48 ` Tommy S. Christensen
2012-10-30 21:00 ` Stephen Hemminger
2012-10-31 14:01 ` John Fastabend
2012-10-31 21:30 ` Stephen Hemminger
2012-11-01 1:33 ` John Fastabend
2012-10-30 0:57 ` [PATCH net-next 2/8] bridge: add template for bridge port flags Stephen Hemminger
2012-10-30 0:57 ` [PATCH net-next 3/8] bridge: implement BPDU blocking Stephen Hemminger
2012-10-31 2:38 ` Cong Wang
2012-10-31 20:57 ` Stephen Hemminger
2012-10-30 0:57 ` [PATCH net-next 4/8] bridge: add root port blocking Stephen Hemminger
2012-10-30 0:57 ` [PATCH net-next 5/8] bridge: add bpdu filter Stephen Hemminger
2012-10-30 0:57 ` [PATCH net-next 6/8] tun: implement byte queue limits Stephen Hemminger
2012-10-30 1:09 ` Stephen Hemminger
2012-10-30 0:57 ` Stephen Hemminger [this message]
2012-10-30 1:09 ` [PATCH net-next 7/8] virtio: make some structures const Stephen Hemminger
2012-10-30 0:57 ` [PATCH net-next 8/8] iproute2: handle new bridge PROTINFO format Stephen Hemminger
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=20121030005835.810565784@vyatta.com \
--to=shemminger@vyatta.com \
--cc=davem@davemloft.net \
--cc=netdev@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;
as well as URLs for NNTP newsgroup(s).