From patchwork Wed Sep 28 14:38:36 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yongjun X-Patchwork-Id: 9353985 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 2428260756 for ; Wed, 28 Sep 2016 14:39:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 14FCB2962D for ; Wed, 28 Sep 2016 14:39:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 08DCA29632; Wed, 28 Sep 2016 14:39:01 +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=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI 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 9A39D2962D for ; Wed, 28 Sep 2016 14:38:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932695AbcI1Oiz (ORCPT ); Wed, 28 Sep 2016 10:38:55 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:34173 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932600AbcI1Oio (ORCPT ); Wed, 28 Sep 2016 10:38:44 -0400 Received: by mail-pf0-f196.google.com with SMTP id 21so2247733pfy.1 for ; Wed, 28 Sep 2016 07:38:44 -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=zESt5qze+Ohzir8PSc0arGWP9Oa+p6aKm9jb4lpM21U=; b=nvsQBgewuJcn7tquQhgOihqj1STMTsyu42sEJWsZg8ewhorKRflJlyUtpAJK/ioUkd bMvtU5HMozEHgQCtJm7O+Pv8fPSW9LSv73zVNdLyR4OP5iy8d/n9iIXTCzrMtfbigk+w +egrh1auLYikVesOiKwqoGOPSNHWn7SiNqmtDSPT0rxtWfHtJlkctL5iETa4DM+FPbFV g7ad1ArEUvmDZgpk2kmpfVy/3HWzyFje8GxL76zTu4CVPpA5nt7d2vjI50EQziinLu84 vCykT6A86NKVLKbqch/n6Sfj5kXgaFiU45BpR1mGyf9Ui0Zhdj0NGd3h7kIEGgeVhdjJ jhmA== 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=zESt5qze+Ohzir8PSc0arGWP9Oa+p6aKm9jb4lpM21U=; b=EpYt0QjS5wbQk/EamM98NhtkFdnuw7uEtagj3TakbpB7N48V+OlVC2VnDkxo7cxeN1 NDwfJTBTop62hdOgFhdKUzG9VNBM3eyuKpXhQ+duvQi8zT3nbRAZjvnXwmbVrNID7T9K QIcq4toTRU9LRMHIPZagr+MxHlFBodbThjv4XWyfeOoH2GOobilLgqQ5J+ogmxvZ4Yqo ct069SriI4jRPD0Hs9dhDjA23F7ULvaeTWW9ERmLeIXkHEgbrbIh+SrIlHYQoge9oq2o j8hAGHdTmmaoNgzE1ayGRId6GxoaBo792woRQ5PWwE0pIqr9UTX9yssi4h7x+PAv+jlF fHjg== X-Gm-Message-State: AE9vXwPh5fTFr6BMpcyljRxjmOCi5FfA3NCv7TMoc4l58f2U09ebagP3tqbJRSpni2tz1Q== X-Received: by 10.98.137.145 with SMTP id n17mr57232597pfk.170.1475073524144; Wed, 28 Sep 2016 07:38:44 -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 u1sm13229388pfb.62.2016.09.28.07.38.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 28 Sep 2016 07:38:43 -0700 (PDT) From: Wei Yongjun To: Kalle Valo , Bruno Herrera , Tony Lindgren Cc: Wei Yongjun , linux-wireless@vger.kernel.org Subject: [PATCH -next] wlcore: sdio: drop kfree for memory allocated with devm_kzalloc Date: Wed, 28 Sep 2016 14:38:36 +0000 Message-Id: <1475073516-7328-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 It's not necessary to free memory allocated with devm_kzalloc and using kfree leads to a double free. Fixes: d776fc86b82f ("wlcore: sdio: Populate config firmware data") Signed-off-by: Wei Yongjun Acked-by: Tony Lindgren --- drivers/net/wireless/ti/wlcore/sdio.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/wireless/ti/wlcore/sdio.c b/drivers/net/wireless/ti/wlcore/sdio.c index a6e94b1..47fe7f9 100644 --- a/drivers/net/wireless/ti/wlcore/sdio.c +++ b/drivers/net/wireless/ti/wlcore/sdio.c @@ -391,7 +391,6 @@ static void wl1271_remove(struct sdio_func *func) pm_runtime_get_noresume(&func->dev); platform_device_unregister(glue->core); - kfree(glue); } #ifdef CONFIG_PM