Skip to content

Commit

Permalink
net/9p: remove virtio default hack and set appropriate bits instead
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Eric Van Hensbergen committed Nov 23, 2013
1 parent dd2a0a3 commit f94741f
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
3 changes: 0 additions & 3 deletions net/9p/client.c
Original file line number Diff line number Diff line change
Expand Up @@ -1011,9 +1011,6 @@ struct p9_client *p9_client_create(const char *dev_name, char *options)
if (err < 0)
goto destroy_tagpool;

if (!clnt->trans_mod)
clnt->trans_mod = v9fs_get_trans_by_name("virtio");

if (!clnt->trans_mod)
clnt->trans_mod = v9fs_get_default_trans();

Expand Down
2 changes: 1 addition & 1 deletion net/9p/trans_fd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1048,7 +1048,7 @@ p9_fd_create(struct p9_client *client, const char *addr, char *args)
static struct p9_trans_module p9_tcp_trans = {
.name = "tcp",
.maxsize = MAX_SOCK_BUF,
.def = 1,
.def = 0,
.create = p9_fd_create_tcp,
.close = p9_fd_close,
.request = p9_fd_request,
Expand Down
2 changes: 1 addition & 1 deletion net/9p/trans_virtio.c
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,7 @@ static struct p9_trans_module p9_virtio_trans = {
* page in zero copy.
*/
.maxsize = PAGE_SIZE * (VIRTQUEUE_NUM - 3),
.def = 0,
.def = 1,
.owner = THIS_MODULE,
};

Expand Down

0 comments on commit f94741f

Please sign in to comment.