From patchwork Tue Jan 10 19:15:54 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bart Van Assche X-Patchwork-Id: 9508409 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id D3F6F6075F for ; Tue, 10 Jan 2017 19:16:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C60C927F89 for ; Tue, 10 Jan 2017 19:16:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BAC1D28596; Tue, 10 Jan 2017 19:16:39 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 19423284EA for ; Tue, 10 Jan 2017 19:16:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S939750AbdAJTQa (ORCPT ); Tue, 10 Jan 2017 14:16:30 -0500 Received: from mail-by2nam03on0046.outbound.protection.outlook.com ([104.47.42.46]:47751 "EHLO NAM03-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S941384AbdAJTQO (ORCPT ); Tue, 10 Jan 2017 14:16:14 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sandiskcorp.onmicrosoft.com; s=selector1-sandisk-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Dxby3ym+myFm9+AIJmG3TTGw9D+kgaNn3M9b+nsBWKM=; b=KOl+5t92bKVksrgjuPHz4OMhpiIknDkPdqxBzi8EPSqQHaBVqavHc9ZEkf+7qhb8TkMlITmQCVQaf8/VzpZFZoabK6It6IBl4a66WTwLe3d7CzylrrxIGs4Hzryy345OQCVLwyd51kABu0avQQHni9ZdgqkMZ5gl0zaVZdM0HmU= Received: from CY4PR02CA0029.namprd02.prod.outlook.com (10.175.57.143) by BN1PR02MB040.namprd02.prod.outlook.com (10.242.210.155) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.829.7; Tue, 10 Jan 2017 19:15:58 +0000 Received: from BL2FFO11FD045.protection.gbl (2a01:111:f400:7c09::108) by CY4PR02CA0029.outlook.office365.com (2603:10b6:903:117::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.829.7 via Frontend Transport; Tue, 10 Jan 2017 19:15:59 +0000 Authentication-Results: spf=pass (sender IP is 63.163.107.21) smtp.mailfrom=sandisk.com; vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=bestguesspass action=none header.from=sandisk.com; Received-SPF: Pass (protection.outlook.com: domain of sandisk.com designates 63.163.107.21 as permitted sender) receiver=protection.outlook.com; client-ip=63.163.107.21; helo=milsmgep15.sandisk.com; Received: from milsmgep15.sandisk.com (63.163.107.21) by BL2FFO11FD045.mail.protection.outlook.com (10.173.161.207) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.803.8 via Frontend Transport; Tue, 10 Jan 2017 19:15:58 +0000 Received: from MILHUBIP04.sdcorp.global.sandisk.com (Unknown_Domain [10.201.67.162]) (using TLS with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by (Symantec Messaging Gateway) with SMTP id 20.B9.65426.84035785; Tue, 10 Jan 2017 11:04:40 -0800 (PST) Received: from milsmgip11.sandisk.com (10.177.9.6) by MILHUBIP04.sdcorp.global.sandisk.com (10.177.9.97) with Microsoft SMTP Server id 14.3.319.2; Tue, 10 Jan 2017 11:15:55 -0800 X-AuditID: 0ac94369-7f3ff7000001ff92-39-58753048bce1 Received: from exp-402881.sdcorp.global.sandisk.com ( [10.177.9.6]) by (Symantec Messaging Gateway) with SMTP id 5F.48.16817.AE235785; Tue, 10 Jan 2017 11:15:54 -0800 (PST) From: Bart Van Assche To: Doug Ledford CC: , Andrew Boyer , "Moni Shoua" Subject: [PATCH v2 15/15] IB/rxe: Fix an skb leak Date: Tue, 10 Jan 2017 11:15:54 -0800 Message-ID: <20170110191554.17359-16-bart.vanassche@sandisk.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170110191554.17359-1-bart.vanassche@sandisk.com> References: <20170110191554.17359-1-bart.vanassche@sandisk.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrGLMWRmVeSWpSXmKPExsXCddJ5ka6HQWmEwY/DmhbX2vexWrw8/4HV 4tmhXhaLDe/XsDuweEyaOYPZ49n0w0we7/ddZfP4vEkugCWKyyYlNSezLLVI3y6BK+PL7+ns Bf+FK+btW8XYwNjE38XIySEhYCKxbud8xi5GLg4hgaVMErc//WCBcLYxSizvnsQKU3Xh/WNW iMRGRokTD88wgSTYBIwkvr2fyQJiiwioSWx6tYgdxGYWyJS4NfcfM4gtLGAosW3LFLB6FgFV iRmP1jKC2LwCDhK/TvxkhFggL7Gr7SLYMk6g+IcF94HqOYCW2UtMWWUMsldC4BeLxJpXa9kg egUlTs58wgKxS0Li4IsXYLuEBNQlTi6ZzzSBUWgWkrJZSMoWMDKtYhTLzcwpzk1PLTA01StO zEvJLM7WS87P3cQICe3MHYx3n3gfYhTgYFTi4X3woiRCiDWxrLgy9xCjBAezkghvql5phBBv SmJlVWpRfnxRaU5q8SFGaQ4WJXFet3tfwoQE0hNLUrNTUwtSi2CyTBycUg2Mez8FVRX6aa5f Zn7SKqz8QHVXS+X7Rdd8zy7ctrZu/wmGy8tuFLvGRNtk3PFnmcLm3bVOYrFge2xV+6Oq0l96 F+qf5mX2Xrxr2jJbe/KywxvTMhLKFgUo/lP8a7gxNUVv43qZWVm3GcNfW8Y0CZ+7vatwh8ux nuS7CxN2tCRtPnnsveS+71NWKrEUZyQaajEXFScCAMG6F+5pAgAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprFJMWRmVeSWpSXmKPExsXCtZGTTfeVUWmEwZnFOhbX2vexWrw8/4HV 4tmhXhaLDe/XsDuweEyaOYPZ49n0w0we7/ddZfP4vEkugCWKyyYlNSezLLVI3y6BK+PL7+ns Bf+FK+btW8XYwNjE38XIySEhYCJx4f1j1i5GLg4hgfWMEis2N7GCJNgEjCS+vZ/JAmKLCKhJ bHq1iL2LkYODWSBT4uwqOZCwsIChxLYtU5hAbBYBVYkZj9Yygti8Ag4Sj65+YIKYLy+xq+0i 2EhOoPiHBfeZQMYICdhLTFllPIGRewEjwypGsdzMnOLc9MwCQ0O94sS8lMzibL3k/NxNjBDf R+5gfDrR/BAjEwenVAPjWebrnxxZc3enzjHifRPs3LQ+oFiUXeubgPm0+qMiX1g4/q2PmXph G2tPW/qeWufczMOfqu0/S1/TypOuFS+dsGDvrujW9X0u52ac7n8g7q0cOVN0pq7bLBGpkAq3 r8ym3gc7lQzjDgpOPP59lxEL+yOfifHGiR7v7zWypBkd3uK+ckPSWxMlluKMREMt5qLiRADf v9ilrQEAAA== MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:63.163.107.21; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(7916002)(39850400002)(39860400002)(39410400002)(39840400002)(39450400003)(2980300002)(438002)(199003)(189002)(626004)(81156014)(6916009)(2950100002)(8936002)(33646002)(69596002)(81166006)(8676002)(36756003)(5660300001)(110136003)(356003)(76176999)(2270400002)(106466001)(50986999)(47776003)(92566002)(189998001)(97736004)(86362001)(305945005)(50466002)(48376002)(2906002)(1076002)(4326007)(8666007)(50226002)(68736007)(77096006)(38730400001)(5003940100001)(54906002); DIR:OUT; SFP:1101; SCL:1; SRVR:BN1PR02MB040; H:milsmgep15.sandisk.com; FPR:; SPF:Pass; PTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BL2FFO11FD045; 1:4xTW4vqBtTsH9rvnLwOxzk6u2Wez8UNdCJeLAeiUCjoOc2JMGfMfBgSbQj+J3TRgfOcT83IgT8gSGU3xssFXQpDWQPvBavVpxbGnZ+TMSgHzeITcsB+XR/4FOZoeMaRaMzb0UE4NixF4W7tfIkFqLfnnuX6zG1CXlUr8o0n5HkgkVU0J8bia7w3Q+87cZBIYh5SCQMcd2zQAM54bwc3a2SpxmrQf1gUqXpwAQD2ANG72s2c8aUzeOjqwQUZBxfsZRr9kb+uKpNAxiSC05xry/uNN+aT/nAv29O29Fygw43oU/cXG8c0yeUriWs/EouBC8rtQjL9vwvi9SWvUXI+1cam3zU+m4HFpU833BWsfz8otrGOclfygz7/Tiy1c+CanVRLtmjv88tx63oRB1SIFnrEkZJssd4dYMH9Ao3+wwkC1O2Ug99R+qEotsjKqmZYLzdZhLNBaf28te23dDkJz41IeNDcVMcYFalSJFewOl+uA/8O9gJ7wW5Omf39qzUMZSsoRy0k/JnxnAF7mV9xExw== X-MS-Office365-Filtering-Correlation-Id: 534ca4d6-6ac3-4713-d98c-08d4398d1bf9 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(8251501002); SRVR:BN1PR02MB040; X-Microsoft-Exchange-Diagnostics: 1; BN1PR02MB040; 3:6RXs+nTjNxj7adB2zxLv9l2WqaMQMRcQmvA7M50O7UKPz+Z32jlMVEKvQouIQwzyXaWTuYZC8Lm2/FSkLQDMwSxRSBG4fvqEuaLnAqcjW2E/gm7BXG4YJYZJkzhMatBHb/gWXsTfWXhPUJ7968PzaaIvAjpfMCT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/NCCG+iuZGwezhxUml/FDRxbzwiE9olsqnZVBSPSvxJXdzIRNtccGksnhgcZ7Hfpw0JFh6N2zsYMbe7XobVw58co0zPTc6rglBHq8U4D412OvAeXrUyuafQ0JdzIN2QM+iD6dIcf25NXjINaIhPtxunhGV5aXWabbWSNWQ0v8+Ymaj10ptzfeL6g6IWadrVg0C5hokqJwxBdjvAZaLiRGFbQBEfQmzsMCssuj+v4AFqZA0L3WNHAC6Fqt2ghaEBSWQtVao0kKLf9DZX7I6sKGp3iEE0uMUpKZiI9NXXie3XFZfLeOf3mV4kv+QfxAzM77JbyyqA8nQM8LylHbt1oLgFKPGmcREj6/diy9u7Cej+zG/i5jLxVy4CInKpENBYMNdH6+mC1C1jwvDnM6YrwtvXNWI8FBBP8q18pZR9IjoET3LGq3hLZEkspIRJToygERk4DEFZwhosyVguHyEYr X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(56004941905204)(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(13016025)(13018025)(5005006)(8121501046)(3002001)(10201501046)(6055026)(6041248)(20161123562025)(20161123555025)(20161123564025)(20161123560025)(6072148); SRVR:BN1PR02MB040; BCL:0; PCL:0; RULEID:; SRVR:BN1PR02MB040; X-Microsoft-Exchange-Diagnostics: 1; BN1PR02MB040; 4:s8j+GdkEbaCPCQjBTwF0va3qQKrBkpvYSTfASeU/GO+FviN7OXnvD82mo4F0SP8tRSccTDd8wzVKKkcHio7sTHrXqikaOgjSOr6ZkFALeAv0Q5z3+OfEZxqJo6SgJPVqXqfYG4ugZ8gfhVPIx65aKWKFQFz89mepvq+bKqhTb/6XIf5D+rysLm/B2iuskEMbXMxbPW+dyiDW8+4AvJgN9DOGalCfF/Lm1S8Tqk5jICc3MlQ0gamWOPbpocAu2x2JujHOUPCTCrKUHEmJVuwP1o+oF3zt3QlD+sczc/LtSnTAeeEgXtJUA2q4Z1RWkQr+gPz1UPPbs2n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A0Gc2PMS5xiqhILQeJgkef1HQVPxw5FoUCisa2k64C2Mb4AghDp3D2yHt0M5VlaoQOgpZwlsX20dn0Oq9BMKLmRH8hhnRi7hQiVlQiZXFMOvKPoFLrnz/XNB2juDxthfXzpNgN7kDZSTZZzCn+ds2DXUfIcRDHo9wqnAV5ACuYVHrRGRPiAkrv9qvqAnEh7E5SYYAk88vnFWnvi91Src34JNzloudR+41FgWHNwec25l2w==; 5:Jxm2dGFp0UpOkq5tS8NL/FU3KSOqxNudHc1fK4tTByrh/aBL5KUwQF7GEq8YuxST1iH75zTmCQNS7PE2DToNxOO/QMlefDtfVYx8XcsABcpHmZUPJfFyBjS3k7rvxSWhG0vPMWx6sShbs/QrGlHnpvocrzkunT/9+1hjl2ilfUs=; 24:TZ3TuzdCqgDO3KgCzJD9162BOt5r0L6Hk057yfsm7t3g/lJS+YbNS7u+XDTfzYijJB93sp/UXqvzVIOyl0v4nFBvdeiC1Uf1kyKPZg6TrEE= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BN1PR02MB040; 7:KH/pg2Pxd8XmyMIWaVfQnd6F0fju0XvxLcTlQfy1bgPTHM6HlopBS19F8AgWy46O8wcxbc70wfFSuuixciuzQSSf7i71ufVczw2+0TXSsCbe5b+EemoAznFq2/+0otNUnM+Oc+N9yeN2jLTURiqhMUc6+4IhUiL/6ikcGJsKDqilYdHqXExlZGQY9NJSxDMoQW+j4xtMjT0tdcr6l+ILMu59nM4X/G4u8ZGEti/hiwEvwQJ71PXO5zsuSewtDwsx/DB9/2417UWnD6KQRSdUCwH/oefxQbz95/huWF/e79eAICP1jXcddmEd47NUkRE25q05LOozfFO5xyMmGX8yA68Au7vM66AfhOLSlRk6sVtALrcOF8XNS7xDxMg7DxSdTibrToLnjViRctf2lgxkNGCWjlmpRfxKIDeIeA0MZmvtWFBE3tUIS8uasS53RklGuoXMiDKYJaSPDx2vBIEWlA== X-OriginatorOrg: sandisk.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Jan 2017 19:15:58.3777 (UTC) X-MS-Exchange-CrossTenant-Id: fcd9ea9c-ae8c-460c-ab3c-3db42d7ac64d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=fcd9ea9c-ae8c-460c-ab3c-3db42d7ac64d; Ip=[63.163.107.21]; Helo=[milsmgep15.sandisk.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN1PR02MB040 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Additionally, make it easier to detect skb leaks by issuing a warning if a leak occurs. Signed-off-by: Bart Van Assche Reviewed-by: Leon Romanovsky Cc: Andrew Boyer Cc: Moni Shoua --- drivers/infiniband/sw/rxe/rxe_comp.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/drivers/infiniband/sw/rxe/rxe_comp.c b/drivers/infiniband/sw/rxe/rxe_comp.c index 91317c159b9a..4cd55d5617f7 100644 --- a/drivers/infiniband/sw/rxe/rxe_comp.c +++ b/drivers/infiniband/sw/rxe/rxe_comp.c @@ -630,6 +630,7 @@ int rxe_completer(void *arg) if (pkt) { rxe_drop_ref(pkt->qp); kfree_skb(skb); + skb = NULL; } goto done; @@ -653,6 +654,7 @@ int rxe_completer(void *arg) qp->qp_timeout_jiffies) mod_timer(&qp->retrans_timer, jiffies + qp->qp_timeout_jiffies); + WARN_ON_ONCE(skb); goto exit; case COMPST_ERROR_RETRY: @@ -665,8 +667,10 @@ int rxe_completer(void *arg) */ /* there is nothing to retry in this case */ - if (!wqe || (wqe->state == wqe_state_posted)) + if (!wqe || (wqe->state == wqe_state_posted)) { + WARN_ON_ONCE(skb); goto exit; + } if (qp->comp.retry_cnt > 0) { if (qp->comp.retry_cnt != 7) @@ -688,8 +692,10 @@ int rxe_completer(void *arg) if (pkt) { rxe_drop_ref(pkt->qp); kfree_skb(skb); + skb = NULL; } + WARN_ON_ONCE(skb); goto exit; } else { @@ -709,6 +715,9 @@ int rxe_completer(void *arg) mod_timer(&qp->rnr_nak_timer, jiffies + rnrnak_jiffies(aeth_syn(pkt) & ~AETH_TYPE_MASK)); + rxe_drop_ref(pkt->qp); + kfree_skb(skb); + skb = NULL; goto exit; } else { wqe->status = IB_WC_RNR_RETRY_EXC_ERR; @@ -724,8 +733,10 @@ int rxe_completer(void *arg) if (pkt) { rxe_drop_ref(pkt->qp); kfree_skb(skb); + skb = NULL; } + WARN_ON_ONCE(skb); goto exit; } } @@ -734,6 +745,7 @@ int rxe_completer(void *arg) /* we come here if we are done with processing and want the task to * exit from the loop calling us */ + WARN_ON_ONCE(skb); rxe_drop_ref(qp); return -EAGAIN; @@ -741,6 +753,7 @@ int rxe_completer(void *arg) /* we come here if we have processed a packet we want the task to call * us again to see if there is anything else to do */ + WARN_ON_ONCE(skb); rxe_drop_ref(qp); return 0; }