Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1056508imu; Thu, 20 Dec 2018 09:23:02 -0800 (PST) X-Google-Smtp-Source: AFSGD/U64wW+2iw1pCe5LPW2Q5+V92D/KtzRd5A3lrTkid3BuXnrkj2wzSolPJG8EMO15DRTmQWb X-Received: by 2002:a17:902:82c2:: with SMTP id u2mr24918926plz.110.1545326582466; Thu, 20 Dec 2018 09:23:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545326582; cv=none; d=google.com; s=arc-20160816; b=Wp1wNUJ/QdCrh1h57BAsUE9qf0uP1KFeQej98IRny8mcVaCT/eF3Zza+Pf5Prygfvq /Pxav9VyTHRhhcaCrUU3pf0zD+tjdJnFWMOapehOJwqYZ9FV4vc2kPD5O9qpu8Jq7iit vIbYa2jATKnfrMEwd0j/t3xYWcjAqb8HfAEsC39vIE7CtzoCOxNLyaMGC5rCPwiJUXqk s9mbRJiCr/Q+sTtfat2taK+wseLOOJuiyOr0xs+MrsfCPPwWCVK+O+y9DK1ufOR4ib4q cOz63pnXWpmGH4xzXA+qavISvTKN8JbdMj9hBUAkl5QDWe6ZguHGbIlro3y+AUrdw6I2 SB6A== 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=JFNTWqFhpeKazwnOj39UERk6OY0Ka+1WIfdnXbFYyQU=; b=nqRGZlsu3IEtr7NZQ9ps/oYHqbIZNSfwKL5fHHsbgc94YgQFv6wpP5UFWK9pv2L+Fv r0WLC10qtKUfkMNvZlRYexk5293cu8tAc9wo0gLizFlhlx9dszILkfgnpliVyDOIl9bB 1qthAouRU4Vf1a/0TQjZrXqOIDkvEATozLRNYLXrCuNdkjMpFqJ6N/76rC5D9NP8WMOe hOey9rhYDLfwQDr4AG9GSJYOVYq7CPWlEU2JJ/8Fiq/SD+ctsXAA3qKTdGMk4ogmx1oR 1B4Vh5lwDS/kAMNyTiMBNHEbE37hhFYhIaLqLX+Ac3EfdEAQqn1r2yJwrVulGagsRq9g +o7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=W0vLS5kW; 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 k22si14817595pgl.29.2018.12.20.09.22.47; Thu, 20 Dec 2018 09:23:02 -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=W0vLS5kW; 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 S2387910AbeLTRU3 (ORCPT + 99 others); Thu, 20 Dec 2018 12:20:29 -0500 Received: from mail-ed1-f67.google.com ([209.85.208.67]:40080 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387888AbeLTRU0 (ORCPT ); Thu, 20 Dec 2018 12:20:26 -0500 Received: by mail-ed1-f67.google.com with SMTP id g22so2392519edr.7 for ; Thu, 20 Dec 2018 09:20:25 -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=JFNTWqFhpeKazwnOj39UERk6OY0Ka+1WIfdnXbFYyQU=; b=W0vLS5kWOBFQ91h93cUXYxuwVuBC8RMdx5Y0SAD9HxeadKiAj+e9Ac1iD0Cn7ui/Dg unMxCVYAv3pQU7Np5Y3XfpKzt8hQOJKK7l3PtFPv+X7XXE8I/5gBN1mrOkd/z6u8dzoq PFshIG+wffEIyXca0e2KISk+3ZKNMwKRb34lHOoDkCxKJhxyFK3o3Gck1FGiV01qJLdR lfLE1E5ppYAQ8jy2NAQUeC0zO/GO45PqIlRli4Oor5jBJyIVa3NH410klbH9LmEWBcmv 8hMjNSNt3QdFfWXoXzt+B8jRlbs+dzoLDqtWHMsmQ/CtvDNV165r+ABsPKCOilUv/DLW htAQ== 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=JFNTWqFhpeKazwnOj39UERk6OY0Ka+1WIfdnXbFYyQU=; b=lSX19/Pl7WQ7HrmfZiYGXsN9+NMvxgPBmPxkoPyhDl+sEG9Qf+1mVs7bcrb878xEtJ ibz/WiS541KBl7n4MJWqg+123B+wjyh9Hcjk03k1oLysFNMeXIrP9nYswDbHFYp53pu9 b630+KOMeP/ABP/QTX3Ph7pQ61gzh1zJhCpRGaD1iuWYPuE/WJrmaUa0nJx2a2b4Y6UA AJXJT7a7pxc9Mc/pQ9mYVkwHO5LwNugtpNu0FORZSxQpms2SfvSLbN3MG+kDScr+Xc1p DZA4Ni1ZdscEoYIbEwuRQGkJDUHza/i+w4AoLb9cFn0dyoKYtCBpr8dE37TIhKTiPS24 ZcWg== X-Gm-Message-State: AA+aEWa9t/IPaZ7F8cK6+rC0LiplPrNlkQGqe1jC1l5Hy0hwYY2E104r i3bfTtBJGvMzSBvKkWDcKUacv7YY X-Received: by 2002:a50:b205:: with SMTP id o5mr23698610edd.245.1545326424896; Thu, 20 Dec 2018 09:20:24 -0800 (PST) Received: from localhost (pD9E51040.dip0.t-ipconnect.de. [217.229.16.64]) by smtp.gmail.com with ESMTPSA id x47sm6289437eda.91.2018.12.20.09.20.24 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 20 Dec 2018 09:20:24 -0800 (PST) From: Thierry Reding To: Jassi Brar Cc: linux-kernel@vger.kernel.org, Houlong Wei , HS Liao , CK Hu Subject: [PATCH v3 13/19] mailbox: mtk-cmdq: Remove needless devm_kfree() calls Date: Thu, 20 Dec 2018 18:19:56 +0100 Message-Id: <20181220172002.9016-14-thierry.reding@gmail.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181220172002.9016-1-thierry.reding@gmail.com> References: <20181220172002.9016-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. Cc: Houlong Wei Cc: HS Liao Cc: CK Hu 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