From: Wei Hu (Xavier) Date: Tue, 29 Nov 2016 23:10:28 +0000 (+0000) Subject: IB/hns: Delete the redundant memset operation X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=19a408efa099e6ebe5458d4fc1ba4630d9daf9d4;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git IB/hns: Delete the redundant memset operation It deleted the redundant memset operation because the memory allocated by ib_alloc_device has been set zero. Signed-off-by: Wei Hu (Xavier) Signed-off-by: Salil Mehta Signed-off-by: Doug Ledford --- diff --git a/drivers/infiniband/hw/hns/hns_roce_main.c b/drivers/infiniband/hw/hns/hns_roce_main.c index 5e620f9f13d2..28a8f24366df 100644 --- a/drivers/infiniband/hw/hns/hns_roce_main.c +++ b/drivers/infiniband/hw/hns/hns_roce_main.c @@ -843,9 +843,6 @@ static int hns_roce_probe(struct platform_device *pdev) if (!hr_dev) return -ENOMEM; - memset((u8 *)hr_dev + sizeof(struct ib_device), 0, - sizeof(struct hns_roce_dev) - sizeof(struct ib_device)); - hr_dev->pdev = pdev; platform_set_drvdata(pdev, hr_dev);