Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp1227943pxu; Fri, 16 Oct 2020 07:07:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxxbSdZjRs1knHKo4h9UaR9K2eenqF6S24Huh8tRGbBnDv/QXXkv3Z8dTOrzw0J2FSG+nDB X-Received: by 2002:ac2:5c45:: with SMTP id s5mr1381182lfp.302.1602857237552; Fri, 16 Oct 2020 07:07:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602857237; cv=none; d=google.com; s=arc-20160816; b=NSQuz7UaXdpoQRs6r2Ke1ovgHy8CNR6TykJAmH7ubfMbwP+s7C9xkrxppywuxg9fCH fjx8J+I2CTl7ra89ZKFFMFLkjC1sKb6YGDSJHSUE+pC7j3n0x/fwrBVu3t3oQS49nRzm YCziLLDqLD83xdWEUKJrYkMtkW5qwnh4Hd5f61R40miuhZlFjfYudAqCYrTxImnVD5zW zsgMy/DbqVp3D8BcNt3wL3bzJXTvfRwp4oH4wQprhWCI4o5SusDTeF5pyAnLrgRiEvBy 0mUioSfiClCOvRoNlbJhBmS+1nYR74K9UUWYsz9+LERV84DsJzr8j9P4oXx+0zjT4nOB /fmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=aQwgiNX6uDL6TEbel4n1VQdEcnG11zAfx3jr9ldRG28=; b=tA16+jePjMyJ9+MXFHdVS7EZfBnE7TYsxo44GPoMgQL7EKr8QA4dhUdbufPZd0556f nivmzCoYjUHTBbwKH88i76m3HIGCvSjQHMUOElP8Ysg6dZMZh9EjMiKCoSOacZ2Ng3/9 m4nuQdIt4XzjIfTO+z4kPCS8VZ22k/y9xE9BD/8vg2XjErshUE0rv1rzaK6DBNlHNVVy N0r9y1HB5N+y2Aw9Fz9AC0lgpZsdVYPj1kDtDFJKzXBmrimUTDsahIIZP1nq/mAWKgzt dlmKcXu7rzfpR699i7ODACyrvBuxOUD9mcoE/KI5TIopo2DIQFu4Ucnui6zZK1TJDLSb +Nvg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=h1HtOArX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f5si1611751ejd.623.2020.10.16.07.06.41; Fri, 16 Oct 2020 07:07:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=h1HtOArX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405628AbgJPJOh (ORCPT + 99 others); Fri, 16 Oct 2020 05:14:37 -0400 Received: from mail.kernel.org ([198.145.29.99]:38890 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405227AbgJPJJ5 (ORCPT ); Fri, 16 Oct 2020 05:09:57 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D3CAE20848; Fri, 16 Oct 2020 09:09:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1602839396; bh=iKOWJVoDIZXni3KU+ogQlI6gzZv2/OUlWaXlqGHnH6U=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=h1HtOArXTLvGf+NNhl0f+adXTKn81X8t+WJImZfYV+07lBAhcBze7Ssa6n93D7K/b 4Ol4nrClPMYTgHei+qKNQLQexe1TekfZ2f7QDIXub9PrPQJFb29r84S0AKSFMl2BN6 +mvdRHdHITiVwOSnPmhdiT/Yr5gGC1TLeF4vfrhI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Thomas Backlund , Leo Yan , Mathieu Poirier , Mike Leach , Alexander Shishkin , Jiri Olsa , Mark Rutland , Namhyung Kim , Peter Zijlstra , Suzuki Poulouse , Tor Jeremiassen , linux-arm-kernel@lists.infradead.org, Arnaldo Carvalho de Melo , Paul Barker Subject: [PATCH 5.4 01/22] perf cs-etm: Move definition of traceid_list global variable from header file Date: Fri, 16 Oct 2020 11:07:29 +0200 Message-Id: <20201016090437.378628931@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201016090437.308349327@linuxfoundation.org> References: <20201016090437.308349327@linuxfoundation.org> User-Agent: quilt/0.66 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Leo Yan commit 168200b6d6ea0cb5765943ec5da5b8149701f36a upstream. The variable 'traceid_list' is defined in the header file cs-etm.h, if multiple C files include cs-etm.h the compiler might complaint for multiple definition of 'traceid_list'. To fix multiple definition error, move the definition of 'traceid_list' into cs-etm.c. Fixes: cd8bfd8c973e ("perf tools: Add processing of coresight metadata") Reported-by: Thomas Backlund Signed-off-by: Leo Yan Reviewed-by: Mathieu Poirier Reviewed-by: Mike Leach Tested-by: Mike Leach Tested-by: Thomas Backlund Cc: Alexander Shishkin Cc: Jiri Olsa Cc: Mark Rutland Cc: Namhyung Kim Cc: Peter Zijlstra Cc: Suzuki Poulouse Cc: Tor Jeremiassen Cc: linux-arm-kernel@lists.infradead.org Link: http://lore.kernel.org/lkml/20200505133642.4756-1-leo.yan@linaro.org Signed-off-by: Arnaldo Carvalho de Melo Cc: Paul Barker Signed-off-by: Greg Kroah-Hartman --- tools/perf/util/cs-etm.c | 3 +++ tools/perf/util/cs-etm.h | 3 --- 2 files changed, 3 insertions(+), 3 deletions(-) --- a/tools/perf/util/cs-etm.c +++ b/tools/perf/util/cs-etm.c @@ -94,6 +94,9 @@ struct cs_etm_queue { struct cs_etm_traceid_queue **traceid_queues; }; +/* RB tree for quick conversion between traceID and metadata pointers */ +static struct intlist *traceid_list; + static int cs_etm__update_queues(struct cs_etm_auxtrace *etm); static int cs_etm__process_queues(struct cs_etm_auxtrace *etm); static int cs_etm__process_timeless_queues(struct cs_etm_auxtrace *etm, --- a/tools/perf/util/cs-etm.h +++ b/tools/perf/util/cs-etm.h @@ -114,9 +114,6 @@ enum cs_etm_isa { CS_ETM_ISA_T32, }; -/* RB tree for quick conversion between traceID and metadata pointers */ -struct intlist *traceid_list; - struct cs_etm_queue; struct cs_etm_packet {