stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 3.18.y] IB/mlx5: Fix leaking stack memory to userspace
@ 2019-08-12 10:48 Alessio Balsini
  2019-08-12 10:51 ` [PATCH 4.4.y] " Alessio Balsini
  0 siblings, 1 reply; 6+ messages in thread
From: Alessio Balsini @ 2019-08-12 10:48 UTC (permalink / raw)
  To: gregkh
  Cc: stable, linux-kernel, kernel-team, Jason Gunthorpe,
	Leon Romanovsky, Alessio Balsini

From: Jason Gunthorpe <jgg@mellanox.com>

mlx5_ib_create_qp_resp was never initialized and only the first 4 bytes
were written.

Fixes: 41d902cb7c32 ("RDMA/mlx5: Fix definition of mlx5_ib_create_qp_resp")
Cc: <stable@vger.kernel.org>
Acked-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Alessio Balsini <balsini@android.com>
---
 drivers/infiniband/hw/mlx5/qp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/infiniband/hw/mlx5/qp.c b/drivers/infiniband/hw/mlx5/qp.c
index 5edb09e674a6..82c4e29c1213 100644
--- a/drivers/infiniband/hw/mlx5/qp.c
+++ b/drivers/infiniband/hw/mlx5/qp.c
@@ -811,7 +811,7 @@ static int create_qp_common(struct mlx5_ib_dev *dev, struct ib_pd *pd,
 			    struct ib_udata *udata, struct mlx5_ib_qp *qp)
 {
 	struct mlx5_ib_resources *devr = &dev->devr;
-	struct mlx5_ib_create_qp_resp resp;
+	struct mlx5_ib_create_qp_resp resp = {};
 	struct mlx5_create_qp_mbox_in *in;
 	struct mlx5_general_caps *gen;
 	struct mlx5_ib_create_qp ucmd;
-- 
2.23.0.rc1.153.gdeed80330f-goog


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-08-13 10:01 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-12 10:48 [PATCH 3.18.y] IB/mlx5: Fix leaking stack memory to userspace Alessio Balsini
2019-08-12 10:51 ` [PATCH 4.4.y] " Alessio Balsini
2019-08-12 10:55   ` [PATCH 4.9.y 4.14.y] " Alessio Balsini
2019-08-12 14:23     ` Greg KH
2019-08-13  9:27       ` Alessio Balsini
2019-08-13 10:01         ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).