From patchwork Thu Sep 29 14:57:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yongjun X-Patchwork-Id: 9356567 X-Patchwork-Delegate: kvalo@adurom.com 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 9521D6077B for ; Thu, 29 Sep 2016 14:58:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 875D529AD2 for ; Thu, 29 Sep 2016 14:58:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7BE7629B02; Thu, 29 Sep 2016 14:58:11 +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.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM 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 7E4EF29AD2 for ; Thu, 29 Sep 2016 14:58:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933713AbcI2O6J (ORCPT ); Thu, 29 Sep 2016 10:58:09 -0400 Received: from mail-pa0-f65.google.com ([209.85.220.65]:32868 "EHLO mail-pa0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932221AbcI2O6H (ORCPT ); Thu, 29 Sep 2016 10:58:07 -0400 Received: by mail-pa0-f65.google.com with SMTP id oz2so3552719pac.0 for ; Thu, 29 Sep 2016 07:58:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=I6aNKfhPhnDcaf3pUPRptDx1YL7rmWDlJuNjcSIC/xk=; b=W2bWmKTZpU6979mGzS02H9KoXNrqCc7x7qYAlXW4KEnz1yIFvmwxJk2umjapPUUIv2 NLe+QlN9d7mRv6GRF8xAlZom5DEq16bDHLMEWg3lb5H9xSQxh0kipA/YllV+ZgN7BLxG vH3O3LkyQBpbeTG50hzyAO4TVT4tigNpqsp0pk1bUQOvXaJN+i3a8FVtQV3NYtuX+cAC mkPZbBPz1g+1dezJsSqP5qDa0UBsiCfvy7QKPfkS0rA/nv7tNuYSTsx+t+18Rm4HqBzK 3WxPvYovfScCzgCgvpTgZLD6FRZ6OeOcIQwKehI1vrABMHp62vPSEIdi7qRVuhytm5xc c4bw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=I6aNKfhPhnDcaf3pUPRptDx1YL7rmWDlJuNjcSIC/xk=; b=YxlECDyzYYfVHGhU2UMZBdyHOm3ZmJ2Y7HTacJDnCz2mCRgysxLOFOoaqPttF3geKp xBNhuMAFBLOA0DG2FzgksgtIL0m1pGsObe4AZPq3TdbydJkGQyixNKsg7qvGXIldKEaA HYuG72sQH1VJtGuL79m4fJeauLS7AwHwc8WnZMi/VY2Juri6ASu8Fttd7AiwFsUOr0d/ lnsJclOGA6K/jx9RC+a5WDVMB8y16A+r2Oyr5m2qxM2nsZjt544Jju+KmdxgMJ2piqi/ KNh3s9E6ztHgRs9iSfrK/pUbXxeWtnINNH3JUBLSOjI9vYnuCBhB2UELZB4zSocGkY6o OdtA== X-Gm-Message-State: AA6/9Rm58bw7StImxHDAOuTxS2O0+keVZzzCC7XBaH8nHJrTfCGxruK9bm70Qh9bg5RCPA== X-Received: by 10.66.158.233 with SMTP id wx9mr3143248pab.2.1475161087000; Thu, 29 Sep 2016 07:58:07 -0700 (PDT) Received: from 192.168.0.37 (ec2-52-192-197-227.ap-northeast-1.compute.amazonaws.com. [52.192.197.227]) by smtp.gmail.com with ESMTPSA id ad15sm21044447pac.33.2016.09.29.07.58.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 29 Sep 2016 07:58:06 -0700 (PDT) From: Wei Yongjun To: Amitkumar Karwar , Nishant Sarmukadam , Kalle Valo Cc: Wei Yongjun , linux-wireless@vger.kernel.org Subject: [PATCH -next] mwifiex: fix missing destroy_workqueue() on error in mwifiex_add_virtual_intf() Date: Thu, 29 Sep 2016 14:57:56 +0000 Message-Id: <1475161076-1409-1-git-send-email-weiyj.lk@gmail.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Wei Yongjun Add the missing destroy_workqueue() before return from mwifiex_add_virtual_intf() in the error handling case. Signed-off-by: Wei Yongjun --- drivers/net/wireless/marvell/mwifiex/cfg80211.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/wireless/marvell/mwifiex/cfg80211.c b/drivers/net/wireless/marvell/mwifiex/cfg80211.c index 39ce76a..5fd5876 100644 --- a/drivers/net/wireless/marvell/mwifiex/cfg80211.c +++ b/drivers/net/wireless/marvell/mwifiex/cfg80211.c @@ -3016,6 +3016,8 @@ struct wireless_dev *mwifiex_add_virtual_intf(struct wiphy *wiphy, priv->netdev = NULL; memset(&priv->wdev, 0, sizeof(priv->wdev)); priv->wdev.iftype = NL80211_IFTYPE_UNSPECIFIED; + destroy_workqueue(priv->dfs_cac_workqueue); + priv->dfs_cac_workqueue = NULL; return ERR_PTR(-ENOMEM); }