Merge tag v4.15 of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
To resolve conflicts in: drivers/infiniband/hw/mlx5/main.c drivers/infiniband/hw/mlx5/qp.c From patches merged into the -rc cycle. The conflict resolution matches what linux-next has been carrying. Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
This commit is contained in:
@@ -183,7 +183,7 @@ static int __rds_rdma_map(struct rds_sock *rs, struct rds_get_mr_args *args,
|
||||
long i;
|
||||
int ret;
|
||||
|
||||
if (rs->rs_bound_addr == 0) {
|
||||
if (rs->rs_bound_addr == 0 || !rs->rs_transport) {
|
||||
ret = -ENOTCONN; /* XXX not a great errno */
|
||||
goto out;
|
||||
}
|
||||
@@ -525,6 +525,9 @@ int rds_rdma_extra_size(struct rds_rdma_args *args)
|
||||
|
||||
local_vec = (struct rds_iovec __user *)(unsigned long) args->local_vec_addr;
|
||||
|
||||
if (args->nr_local == 0)
|
||||
return -EINVAL;
|
||||
|
||||
/* figure out the number of pages in the vector */
|
||||
for (i = 0; i < args->nr_local; i++) {
|
||||
if (copy_from_user(&vec, &local_vec[i],
|
||||
@@ -874,6 +877,7 @@ int rds_cmsg_atomic(struct rds_sock *rs, struct rds_message *rm,
|
||||
err:
|
||||
if (page)
|
||||
put_page(page);
|
||||
rm->atomic.op_active = 0;
|
||||
kfree(rm->atomic.op_notifier);
|
||||
|
||||
return ret;
|
||||
|
@@ -1009,6 +1009,9 @@ static int rds_rdma_bytes(struct msghdr *msg, size_t *rdma_bytes)
|
||||
continue;
|
||||
|
||||
if (cmsg->cmsg_type == RDS_CMSG_RDMA_ARGS) {
|
||||
if (cmsg->cmsg_len <
|
||||
CMSG_LEN(sizeof(struct rds_rdma_args)))
|
||||
return -EINVAL;
|
||||
args = CMSG_DATA(cmsg);
|
||||
*rdma_bytes += args->remote_vec.bytes;
|
||||
}
|
||||
|
@@ -90,9 +90,10 @@ void rds_tcp_nonagle(struct socket *sock)
|
||||
sizeof(val));
|
||||
}
|
||||
|
||||
u32 rds_tcp_snd_nxt(struct rds_tcp_connection *tc)
|
||||
u32 rds_tcp_write_seq(struct rds_tcp_connection *tc)
|
||||
{
|
||||
return tcp_sk(tc->t_sock->sk)->snd_nxt;
|
||||
/* seq# of the last byte of data in tcp send buffer */
|
||||
return tcp_sk(tc->t_sock->sk)->write_seq;
|
||||
}
|
||||
|
||||
u32 rds_tcp_snd_una(struct rds_tcp_connection *tc)
|
||||
|
@@ -54,7 +54,7 @@ void rds_tcp_set_callbacks(struct socket *sock, struct rds_conn_path *cp);
|
||||
void rds_tcp_reset_callbacks(struct socket *sock, struct rds_conn_path *cp);
|
||||
void rds_tcp_restore_callbacks(struct socket *sock,
|
||||
struct rds_tcp_connection *tc);
|
||||
u32 rds_tcp_snd_nxt(struct rds_tcp_connection *tc);
|
||||
u32 rds_tcp_write_seq(struct rds_tcp_connection *tc);
|
||||
u32 rds_tcp_snd_una(struct rds_tcp_connection *tc);
|
||||
u64 rds_tcp_map_seq(struct rds_tcp_connection *tc, u32 seq);
|
||||
extern struct rds_transport rds_tcp_transport;
|
||||
|
@@ -86,7 +86,7 @@ int rds_tcp_xmit(struct rds_connection *conn, struct rds_message *rm,
|
||||
* m_ack_seq is set to the sequence number of the last byte of
|
||||
* header and data. see rds_tcp_is_acked().
|
||||
*/
|
||||
tc->t_last_sent_nxt = rds_tcp_snd_nxt(tc);
|
||||
tc->t_last_sent_nxt = rds_tcp_write_seq(tc);
|
||||
rm->m_ack_seq = tc->t_last_sent_nxt +
|
||||
sizeof(struct rds_header) +
|
||||
be32_to_cpu(rm->m_inc.i_hdr.h_len) - 1;
|
||||
@@ -98,7 +98,7 @@ int rds_tcp_xmit(struct rds_connection *conn, struct rds_message *rm,
|
||||
rm->m_inc.i_hdr.h_flags |= RDS_FLAG_RETRANSMITTED;
|
||||
|
||||
rdsdebug("rm %p tcp nxt %u ack_seq %llu\n",
|
||||
rm, rds_tcp_snd_nxt(tc),
|
||||
rm, rds_tcp_write_seq(tc),
|
||||
(unsigned long long)rm->m_ack_seq);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user