Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2330162imu; Wed, 21 Nov 2018 09:56:59 -0800 (PST) X-Google-Smtp-Source: AFSGD/W3Rg9/9vbA/3uid79fJ7AeLF0OCeYtjBrBazNvhwpV3w7U0zfO7A/YbMO4qdFo0vADLc93 X-Received: by 2002:a63:68c4:: with SMTP id d187mr6819663pgc.11.1542823019404; Wed, 21 Nov 2018 09:56:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542823019; cv=none; d=google.com; s=arc-20160816; b=VHoU8kkSJGyzm8fJV9aaQxyjbfwkcfGB/G/1a+p8ZOnCO1T4EuAxJsg29zFbofPjHz laqPDm/uGHQhdsNPnNyjGnwtSXm/2riMIKnXWUW8kTpuzULm/3cUh2QjFAFahUnXKME6 Vm4CXWqiD+dQo2p0EuP4HTl475ShSqQ6lRbM9EVHzsTU0e5NsI7Mau9QGBE7J0stXXH9 m53p5IvzIVbkJ+GQykfauB6LhJQt7o07UaAVKKPOzffPWGuQejojGm7mPpC9Cc6y4GUT +ZjPzP2Y0gENalrQYbavys9DgqFxx0tIEmL+iMT5+IJ04Q0T25c9p17fcntS0LYwEAPu dSUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=C2EwwsLBwBer8z1z07IXta+Tj2VvEVIyAWVTe+k8hyU=; b=a59TGF2aKSaAg/ImqtI0vkmFaYJlipqVKPjpT3v97gebq0Mcz2ll8yoEk8wEn77swW aeoJLIbFKmXcFJlIzxWAyd/0/W/M1gPUc6TInHYnhTkJM7hQa0/7Z3czWv0LRu5bhmIH pF+RNFAWXPXydWVmWgw34Z86xN7uS6DDn6xztLmw4aQGPBRMjU3elnVh8IBGKH1fKwxD +hYyoOYAS0oviJlwrV+7AA/UztIHMB+SOanbqVPfradWhQ7vrIznMFPd3TFimCt26n8s wXB6E1sU3jsvM/tMj9mBrz9R1S3ztxhsjZaAONxSNnfG/YHdKM2auXK/Tq6sM0zDlVfV Dn+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=cLsjMr1Q; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o68si18324058pfo.140.2018.11.21.09.56.44; Wed, 21 Nov 2018 09:56:59 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=cLsjMr1Q; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731301AbeKVB3i (ORCPT + 99 others); Wed, 21 Nov 2018 20:29:38 -0500 Received: from mail-ed1-f67.google.com ([209.85.208.67]:33839 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731262AbeKVB3g (ORCPT ); Wed, 21 Nov 2018 20:29:36 -0500 Received: by mail-ed1-f67.google.com with SMTP id b3so5139342ede.1 for ; Wed, 21 Nov 2018 06:54:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=C2EwwsLBwBer8z1z07IXta+Tj2VvEVIyAWVTe+k8hyU=; b=cLsjMr1Q/kSvxNrxhE9FmIoaUyBOLq8eWEPJ97xlPViDY1dHYTAQTh7Zk4kM5wTRT3 moc28pg0FrMxIC+/tgwRHpgbAhynlRVvgojGH7trWbxlYoesCZ/TVndNwWz1tpVxXiTg 6oI2e4kVfElWZ4PGbI/oKSD6moNWa9Q5Ukg/P0Q6efd+JtvqLqMplcki5S9IcGnLN+fM m0p1h/bsF2v2ecihYnSptEH4pf97s3Q5Vp+xQWioxC00jXm+g+mV7tB/SeESXHOv+5A3 0puFRGqnJyQRbx8ORo4E6XYRmLc7XXRTBgodJ8vVncsocs5XjEyo2G8BNy9+t7ZeMQHV rtRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=C2EwwsLBwBer8z1z07IXta+Tj2VvEVIyAWVTe+k8hyU=; b=YRo4toHMXzUtRrncfjajOy3khcJmvVbnZt7MZbVNd0RCL8X3w2l2vzFctnxn/BsHKd jY8cuvsiC1tmM30bRRYY7Ur5o/HyVn/Mx8kdDsWNxHsHMrBLAn4Mejy8QsbAev0XsOar lRVtXevNKoEMXwMmJ7GbUaU0k4Na4c4fpbM8uZa1pLyIPoCqY1vHw1aQ0ubhYeENetEw DhuKf/2F3so1kV2adh4yfZN38xqnMj0SYkluCPKlBSNpgWZUYg+S10l/jDZTC/Kbz0Hc 3pH+BRUmF6b/oyW0nSjgW2yL2x3snbmQ6P1WctBf+a4QyUHHIxod4q3dSh2SI+7LC2nJ nTow== X-Gm-Message-State: AGRZ1gKH0UMYUjL/ZZyuUS9SebKUPPeeb/MkdVSU8hyp5Esb05TCI47+ 8/puEMHWN1sNDhMxd0mIM/t4mfOg X-Received: by 2002:a17:906:3603:: with SMTP id q3-v6mr5374528ejb.164.1542812090459; Wed, 21 Nov 2018 06:54:50 -0800 (PST) Received: from localhost (pD9E511F8.dip0.t-ipconnect.de. [217.229.17.248]) by smtp.gmail.com with ESMTPSA id k31sm12295989ede.5.2018.11.21.06.54.49 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 21 Nov 2018 06:54:49 -0800 (PST) From: Thierry Reding To: Jassi Brar Cc: linux-kernel@vger.kernel.org Subject: [PATCH 13/19] mailbox: mtk-cmdq: Remove needless devm_kfree() calls Date: Wed, 21 Nov 2018 15:54:23 +0100 Message-Id: <20181121145429.7582-14-thierry.reding@gmail.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181121145429.7582-1-thierry.reding@gmail.com> References: <20181121145429.7582-1-thierry.reding@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Thierry Reding Memory allocated through device-managed functions doesn't need to be explicitly freed, so these calls can be removed. Signed-off-by: Thierry Reding --- drivers/mailbox/mtk-cmdq-mailbox.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/mailbox/mtk-cmdq-mailbox.c b/drivers/mailbox/mtk-cmdq-mailbox.c index d9c3ec3667a8..22811784dc7d 100644 --- a/drivers/mailbox/mtk-cmdq-mailbox.c +++ b/drivers/mailbox/mtk-cmdq-mailbox.c @@ -339,14 +339,6 @@ static int cmdq_remove(struct platform_device *pdev) clk_unprepare(cmdq->clock); - if (cmdq->mbox.chans) - devm_kfree(&pdev->dev, cmdq->mbox.chans); - - if (cmdq->thread) - devm_kfree(&pdev->dev, cmdq->thread); - - devm_kfree(&pdev->dev, cmdq); - return 0; } -- 2.19.1