X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=net%2Frxrpc%2Fconnection.c;h=929b82f48aeba9a91b5baf6e12354109de4235bf;hb=9bf4aaab3e101692164d49b7ca357651eb691cb6;hp=a923806d63f04dee07311df73574edadfd06faff;hpb=db216c3d5e4c040e557a50f8f5d35d5c415e8c1c;p=linux-2.6.git diff --git a/net/rxrpc/connection.c b/net/rxrpc/connection.c index a923806d6..929b82f48 100644 --- a/net/rxrpc/connection.c +++ b/net/rxrpc/connection.c @@ -518,7 +518,7 @@ int rxrpc_conn_newmsg(struct rxrpc_connection *conn, struct rxrpc_call *call, uint8_t type, int dcount, - struct iovec diov[], + struct kvec diov[], int alloc_flags, struct rxrpc_message **_msg) { @@ -620,7 +620,6 @@ int rxrpc_conn_sendmsg(struct rxrpc_connection *conn, struct rxrpc_message *msg) { struct msghdr msghdr; - mm_segment_t oldfs; int ret; _enter("%p{%d}", conn, ntohs(conn->addr.sin_port)); @@ -634,8 +633,6 @@ int rxrpc_conn_sendmsg(struct rxrpc_connection *conn, /* set up the message to be transmitted */ msghdr.msg_name = &conn->addr; msghdr.msg_namelen = sizeof(conn->addr); - msghdr.msg_iov = msg->data; - msghdr.msg_iovlen = msg->dcount; msghdr.msg_control = NULL; msghdr.msg_controllen = 0; msghdr.msg_flags = MSG_CONFIRM | MSG_DONTWAIT; @@ -647,15 +644,11 @@ int rxrpc_conn_sendmsg(struct rxrpc_connection *conn, htons(conn->addr.sin_port)); /* send the message */ - oldfs = get_fs(); - set_fs(KERNEL_DS); - ret = sock_sendmsg(conn->trans->socket, &msghdr, msg->dsize); - set_fs(oldfs); - + ret = kernel_sendmsg(conn->trans->socket, &msghdr, + msg->data, msg->dcount, msg->dsize); if (ret < 0) { msg->state = RXRPC_MSG_ERROR; - } - else { + } else { msg->state = RXRPC_MSG_SENT; ret = 0;