From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754356AbbETX63 (ORCPT ); Wed, 20 May 2015 19:58:29 -0400 Received: from mga03.intel.com ([134.134.136.65]:58167 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751962AbbETX61 (ORCPT ); Wed, 20 May 2015 19:58:27 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,466,1427785200"; d="scan'208";a="496312061" Date: Wed, 20 May 2015 16:58:26 -0700 From: Andi Kleen To: Sukadev Bhattiprolu Cc: mingo@redhat.com, Michael Ellerman , Jiri Olsa , Arnaldo Carvalho de Melo , Paul Mackerras , namhyung@kernel.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 3/4] perf: Use pmu_events_map table to create event aliases Message-ID: <20150520235826.GB7484@tassilo.jf.intel.com> References: <1432080130-6678-1-git-send-email-sukadev@linux.vnet.ibm.com> <1432080130-6678-4-git-send-email-sukadev@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1432080130-6678-4-git-send-email-sukadev@linux.vnet.ibm.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > +/* > + * Return TRUE if the CPU identified by @vfm, @version, and @type > + * matches the current CPU. vfm refers to [Vendor, Family, Model], > + * > + * Return FALSE otherwise. > + * > + * For Powerpc, we only compare @version to the processor PVR. > + */ > +bool arch_pmu_events_match_cpu(const char *vfm __maybe_unused, > + const char *version, > + const char *type __maybe_unused) > +{ > + char *cpustr; > + bool rc; > + > + cpustr = get_cpu_str(); > + rc = !strcmp(version, cpustr); Surely against vfm not version I think your mapfile is wrong if that works? That's the Intel format: .vfm = "GenuineIntel-6-3E", .version = "V16", .type = "core", .table = pme_IvyTown_core -Andi