Message ID | 1518467557-18505-2-git-send-email-mathieu.poirier@linaro.org |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp3565759ljc; Mon, 12 Feb 2018 12:32:49 -0800 (PST) X-Google-Smtp-Source: AH8x224BHCvdup/LOoZUt/4uixH/ZkhuDjThH9BiCYwuSox/uJMKLmnqj8uM5ZtlacCtANFAk69a X-Received: by 2002:a17:902:32a2:: with SMTP id z31-v6mr11907084plb.345.1518467568863; Mon, 12 Feb 2018 12:32:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518467568; cv=none; d=google.com; s=arc-20160816; b=ETx1UjrDVo2J+/ZeX3O06dkxnRGrlRUGvoCyDSGB/dyLS23uWCzg8V0yhsOsRE6gNr dGv5ctRNTKnjkO6bLMNc9oepi5fezOobmGoMK+ryNjlIwRYZtzjdIvdVxmID4bSJB/CH ShcqUk1MBtDb0KBmHCPXVIEQlwdhDuy5zdq/0uguuZPsHayplMkJNmXTqXJPiD865Dlm ujfM+ZUeo7y1BVaJJa/IlqWYNzuSH1GJsMN6jAfx2438ZIDjkrMuGTsOldSwvpZWxrkw 3i/J6/7Zr7Lm4iZsCi3U6tiX9ruuo1U8iW7KHUWb4WTaxzPgKWst7c6V7W06o6dMFT2C kiXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=a5/HP10kcS8rrlT8+jHyREHI2Z0DyTHsKu6Dx+CnsX0=; b=flQ14mRVxBenjlpLiXFd4/rULyes1DqK7f7stON4mKg7BUmJls9jObzs/o6cnaoaYf I0wPSV7tUi4dAMC9Ap6rC8ftuIIp5KuQHA5X4zoPpSU1mjipM9yMZEJb+eT4Og7iapUr INQDTeHd4Cn869plo70eNSfQidduohdIBVOJvdNhpjzesnAQ0ve8uTlpu6MlTePoYkrs t2ZDe8KvgU5yz0R8tmteel7pq5nLlnF+i7O69ZAvdePRrU16nmHuRLMQ3MaKPi/wP0hH 9PeFNf0xrbAYQJO0CFjga9Di518HvPR7W5pdOZeM438yXdWN7/rHeFCbwc8OGJxXA6gd BLxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IbSaS4dR; 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=NONE dis=NONE) header.from=linaro.org Return-Path: <linux-kernel-owner@vger.kernel.org> Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z6-v6si164693plo.200.2018.02.12.12.32.48; Mon, 12 Feb 2018 12:32:48 -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=@linaro.org header.s=google header.b=IbSaS4dR; 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=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753931AbeBLUcn (ORCPT <rfc822;semen.protsenko@linaro.org> + 26 others); Mon, 12 Feb 2018 15:32:43 -0500 Received: from mail-pg0-f67.google.com ([74.125.83.67]:35709 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753193AbeBLUcl (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 12 Feb 2018 15:32:41 -0500 Received: by mail-pg0-f67.google.com with SMTP id l131so2732703pga.2 for <linux-kernel@vger.kernel.org>; Mon, 12 Feb 2018 12:32:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=a5/HP10kcS8rrlT8+jHyREHI2Z0DyTHsKu6Dx+CnsX0=; b=IbSaS4dRXpU+hHaOJ3zAAwQio14jw5ZMbuWOTdEJGooFjhIgNreA1RFR73ZyCDQa/r POxJizDu1rWw7fapsoqB91MleKM/sABj6r0C1gw0zJUTy8HDupb9IW5LPzSYHazQmZ8W gFzIm5fWdC3hp+H9OmbsULzdixATOXNxV1XgU= 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; bh=a5/HP10kcS8rrlT8+jHyREHI2Z0DyTHsKu6Dx+CnsX0=; b=VSPQuTFXxGQG3dU1CaX1Lf8vGx+/AIw0EqSpzNAyOHpqkkJJIsFGcnjdOHqqo0qk7S DRuLFsoIHi11g9ITdfwWs7ALtgukMpQwbcx0/N+QMuKE/hSNPKGtXVeXW0oBZZCStmrm 7cQGfOqSSrnBmHujforKRWFwupwrXnS3/bkJd7tnsWSY148EkpBoFJgCo7EYP6k8iHl+ Ig7yJ7QhD5gpQ47PauNgD/74dMMuuCB1xX9pOwj2Zw7lCADsw3O+EUAxMfvU+raMnnMo /6Ay4YqduLM7CZ45TSRhW18+N/34UxjzSb9XUo6kH+3BGZDm5EDTxSn9bLbu2ZVXG56p U0hw== X-Gm-Message-State: APf1xPBw4vK3coNrAEhls47n21naBAw1q8rKwmozzvZl9uTrScl385a5 AYcTPiH6mAKMZXnZttsNkQBbsDO3hNk= X-Received: by 10.98.144.213 with SMTP id q82mr12782612pfk.37.1518467560792; Mon, 12 Feb 2018 12:32:40 -0800 (PST) Received: from xps15.cg.shawcable.net (S0106002369de4dac.cg.shawcable.net. [68.147.8.254]) by smtp.gmail.com with ESMTPSA id c8sm12856594pgn.72.2018.02.12.12.32.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 12 Feb 2018 12:32:40 -0800 (PST) From: Mathieu Poirier <mathieu.poirier@linaro.org> To: acme@kernel.org Cc: peterz@infradead.org, mingo@redhat.com, alexander.shishkin@linux.intel.com, namhyung@kernel.org, yao.jin@linux.intel.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/3] perf tools: Freeing allocated memory Date: Mon, 12 Feb 2018 13:32:35 -0700 Message-Id: <1518467557-18505-2-git-send-email-mathieu.poirier@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1518467557-18505-1-git-send-email-mathieu.poirier@linaro.org> References: <1518467557-18505-1-git-send-email-mathieu.poirier@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org |
Series |
perf tools: Miscellaneous fix from the previous cycle
|
expand
|
diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c index b9f0a53dfa65..f2c98774e665 100644 --- a/tools/perf/util/cs-etm.c +++ b/tools/perf/util/cs-etm.c @@ -174,6 +174,12 @@ static void cs_etm__free_queue(void *priv) { struct cs_etm_queue *etmq = priv; + if (!etmq) + return; + + thread__zput(etmq->thread); + cs_etm_decoder__free(etmq->decoder); + zfree(&etmq->event_buf); free(etmq); }
This patch frees all the memory allocated in function cs_etm__alloc_queue(). Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> --- tools/perf/util/cs-etm.c | 6 ++++++ 1 file changed, 6 insertions(+) -- 2.7.4