Skip to content

Commit f94741f

Browse files
committed
net/9p: remove virtio default hack and set appropriate bits instead
A few releases back a patch made virtio the default transport, however it was done in a way which side-stepped the mechanism put in place to allow for this selection. This patch cleans that up while maintaining virtio as the default transport. Signed-off-by: Eric Van Hensbergen <ericvh@gmail.com>
1 parent dd2a0a3 commit f94741f

3 files changed

Lines changed: 2 additions & 5 deletions

File tree

‎net/9p/client.c‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1011,9 +1011,6 @@ struct p9_client *p9_client_create(const char *dev_name, char *options)
10111011
if (err < 0)
10121012
goto destroy_tagpool;
10131013

1014-
if (!clnt->trans_mod)
1015-
clnt->trans_mod = v9fs_get_trans_by_name("virtio");
1016-
10171014
if (!clnt->trans_mod)
10181015
clnt->trans_mod = v9fs_get_default_trans();
10191016

‎net/9p/trans_fd.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1048,7 +1048,7 @@ p9_fd_create(struct p9_client *client, const char *addr, char *args)
10481048
static struct p9_trans_module p9_tcp_trans = {
10491049
.name = "tcp",
10501050
.maxsize = MAX_SOCK_BUF,
1051-
.def = 1,
1051+
.def = 0,
10521052
.create = p9_fd_create_tcp,
10531053
.close = p9_fd_close,
10541054
.request = p9_fd_request,

‎net/9p/trans_virtio.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -698,7 +698,7 @@ static struct p9_trans_module p9_virtio_trans = {
698698
* page in zero copy.
699699
*/
700700
.maxsize = PAGE_SIZE * (VIRTQUEUE_NUM - 3),
701-
.def = 0,
701+
.def = 1,
702702
.owner = THIS_MODULE,
703703
};
704704

0 commit comments

Comments
 (0)