Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755340AbdIRLYj (ORCPT ); Mon, 18 Sep 2017 07:24:39 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52128 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751016AbdIRLYi (ORCPT ); Mon, 18 Sep 2017 07:24:38 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 56E2F3680C Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=jolsa@redhat.com Date: Mon, 18 Sep 2017 13:24:35 +0200 From: Jiri Olsa To: kan.liang@intel.com Cc: acme@kernel.org, peterz@infradead.org, mingo@redhat.com, linux-kernel@vger.kernel.org, jolsa@kernel.org, namhyung@kernel.org, adrian.hunter@intel.com, lukasz.odzioba@intel.com, ak@linux.intel.com Subject: Re: [PATCH RFC V2 08/10] perf top: implement multithreading for perf_event__synthesize_threads Message-ID: <20170918112435.GA7013@krava> References: <1505096603-215017-1-git-send-email-kan.liang@intel.com> <1505096603-215017-9-git-send-email-kan.liang@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1505096603-215017-9-git-send-email-kan.liang@intel.com> User-Agent: Mutt/1.9.0 (2017-09-02) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Mon, 18 Sep 2017 11:24:38 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 709 Lines: 26 On Sun, Sep 10, 2017 at 07:23:21PM -0700, kan.liang@intel.com wrote: SNIP > diff --git a/tools/perf/util/event.h b/tools/perf/util/event.h > index ee7bcc8..7b987c8 100644 > --- a/tools/perf/util/event.h > +++ b/tools/perf/util/event.h > @@ -664,6 +664,17 @@ typedef int (*perf_event__handler_t)(struct perf_tool *tool, > struct perf_sample *sample, > struct machine *machine); > > +struct synthesize_threads_arg { > + struct perf_tool *tool; > + perf_event__handler_t process; > + struct machine *machine; > + bool mmap_data; > + unsigned int proc_map_timeout; > + struct dirent **dirent; > + int num; > + int start; > +}; does not need to be global, can be defined in event.c jirka