linux-stable/net/rds
Dotan Barak f4e58dc5f8 net/rds: Fix error handling in rds_ib_add_one()
[ Upstream commit d64bf89a75 ]

rds_ibdev:ipaddr_list and rds_ibdev:conn_list are initialized
after allocation some resources such as protection domain.
If allocation of such resources fail, then these uninitialized
variables are accessed in rds_ib_dev_free() in failure path. This
can potentially crash the system. The code has been updated to
initialize these variables very early in the function.

Signed-off-by: Dotan Barak <dotanb@dev.mellanox.co.il>
Signed-off-by: Sudhakar Dindukurti <sudhakar.dindukurti@oracle.com>
Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-07 18:55:20 +02:00
..
af_rds.c RDS: validate the requested traces user input against max supported 2017-01-06 22:14:26 -05:00
bind.c rds: fix refcount bug in rds_sock_addref 2019-02-12 19:46:10 +01:00
cong.c RDS: split out connection specific state from rds_connection to rds_conn_path 2016-06-14 23:50:41 -07:00
connection.c rds: tcp: correctly sequence cleanup on netns deletion. 2018-02-25 11:07:50 +01:00
ib.c net/rds: Fix error handling in rds_ib_add_one() 2019-10-07 18:55:20 +02:00
ib.h rds: rds_ib_recv_alloc_cache() should call alloc_percpu_gfp() instead 2018-10-13 09:27:29 +02:00
ib_cm.c rds: rds_ib_recv_alloc_cache() should call alloc_percpu_gfp() instead 2018-10-13 09:27:29 +02:00
ib_fmr.c net: rds: exchange of 8K and 1M pool 2019-05-02 09:40:33 +02:00
ib_frmr.c RDS: IB: fix 'passing zero to ERR_PTR()' warning 2018-09-15 09:45:31 +02:00
ib_mr.h rds: ib: add the static type to the function 2017-03-13 23:20:05 -07:00
ib_rdma.c net: rds: fix memory leak in rds_ib_flush_mr_pool 2019-06-11 12:21:45 +02:00
ib_recv.c rds: rds_ib_recv_alloc_cache() should call alloc_percpu_gfp() instead 2018-10-13 09:27:29 +02:00
ib_ring.c
ib_send.c rds: Fix inaccurate accounting of unsignaled wrs 2017-10-26 17:35:57 +09:00
ib_stats.c RDS: IB: add few useful cache stasts 2017-01-02 14:02:51 -08:00
ib_sysctl.c
info.c
info.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
Kconfig
loop.c rds: avoid unenecessary cong_update in loop transport 2018-07-22 14:28:49 +02:00
loop.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
message.c net, rds: convert rds_message.m_refcount from atomic_t to refcount_t 2017-07-04 22:35:18 +01:00
page.c rds: remove dead code 2016-12-26 21:35:39 -05:00
rdma.c RDS: null pointer dereference in rds_atomic_free_op 2018-01-17 09:45:21 +01:00
rdma_transport.c RDS: RDMA: start rdma listening after init 2017-01-02 14:02:45 -08:00
rdma_transport.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
rds.h rds: avoid unenecessary cong_update in loop transport 2018-07-22 14:28:49 +02:00
rds_single_path.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
recv.c rds: avoid unenecessary cong_update in loop transport 2018-07-22 14:28:49 +02:00
send.c rds: MP-RDS may use an invalid c_path 2018-04-19 08:56:15 +02:00
stats.c
sysctl.c net: rds: fix coding style issues 2016-06-18 21:34:09 -07:00
tcp.c net: rds: force to destroy connection if t_sock is NULL in rds_tcp_kill_sock(). 2019-04-17 08:37:46 +02:00
tcp.h rds: tcp: atomically purge entries from rds_tcp_conn_list during netns delete 2018-02-25 11:07:51 +01:00
tcp_connect.c rds: cancel send/recv work before queuing connection shutdown 2017-07-16 19:07:35 -07:00
tcp_listen.c rds: Incorrect reference counting in TCP socket creation 2018-05-30 07:52:10 +02:00
tcp_recv.c RDS: add receive message trace used by application 2017-01-02 14:02:59 -08:00
tcp_send.c rds: cancel send/recv work before queuing connection shutdown 2017-07-16 19:07:35 -07:00
tcp_stats.c
threads.c rds: cancel send/recv work before queuing connection shutdown 2017-07-16 19:07:35 -07:00
transport.c rds: remove unnecessary returned value check 2017-03-03 09:51:22 -08:00