Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp12853390rwd; Fri, 23 Jun 2023 11:35:26 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7fni8xlHy0+CYJp0XsLMKSmF4rKrZV2lAttWpa2vbT84V+V2DqOqWWZjHbIGtFz2ktrruP X-Received: by 2002:a17:902:da85:b0:1b2:5ade:9ebb with SMTP id j5-20020a170902da8500b001b25ade9ebbmr6211plx.2.1687545325739; Fri, 23 Jun 2023 11:35:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687545325; cv=none; d=google.com; s=arc-20160816; b=Hg8BaIzeFuGEYIEpd6YovKL9zi8YT90QREDLT93AcR84ObBILVrsj/QBLAImj8XI9a 0b5VAx7xEKfouXDS9+YAigbaRXM/kbW9KXal3arYh6+CImvA4gQxjdfno8p+RZa+IvnT rr/vgcxEs/YT/4WUjcmP3zA1vX3V+by264LDsrXcRIzOJ8Nk6JRdkPaNeLmJ49K8l1T1 x/bct/Ac4FZeYxO6QNgiDSy5i3IlWpwxIVhbxUxoTESwLnZT3ZLuAA8eu/2iA3c+esun iqDzNARJPcI0u4Cs/2PGfo8Ncpt1xe26mTJ0Gun/3FJuQPuEVGBZwiZ/sXUBD6pnvhY8 MvuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version; bh=x8ARDN+MxvFHLW8pb75RJ3CU3uwjgVQ80Th65ZHz4bo=; b=q/pp6ifazYX9kshaQ/RI1mQAnhyyS3O/APAKSTJJdwihVan1PhN/dmfBC4OmfPNqOY OChrBHtwgJc2jl1BGzAvevoGmRteGghs8E8uSsVIzhhl1GgL1F+DOB9Yizrrj0OoOkHX sFDCZhZM1PfIXpdJJmGpIRRcFH1Kf2iqi87tmHmpC3hChfSxoygacI94JP/Gjw0+YnEj 9PC21WUcdcXHRo5j4kn/mXsdFSmRrJ60d9/NUOZ/Z9V9aMPoRkt6sq5NvVySP6PXWAsy xQQFsH86jfnOisga7JJS9xn+YSg5VSMWuJnF/nt3PcgYm3nz2nbuEkuKZuYanOelznv7 aiuw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c9-20020a170902b68900b001b22f31cce9si8790533pls.179.2023.06.23.11.35.13; Fri, 23 Jun 2023 11:35:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231866AbjFWSEn convert rfc822-to-8bit (ORCPT + 99 others); Fri, 23 Jun 2023 14:04:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37936 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230501AbjFWSEm (ORCPT ); Fri, 23 Jun 2023 14:04:42 -0400 Received: from mail-yb1-f182.google.com (mail-yb1-f182.google.com [209.85.219.182]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9DCC2E41; Fri, 23 Jun 2023 11:04:41 -0700 (PDT) Received: by mail-yb1-f182.google.com with SMTP id 3f1490d57ef6-bd6446528dcso748536276.2; Fri, 23 Jun 2023 11:04:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687543481; x=1690135481; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ar+uO6yezPNwOzdQCCX6gm90eaUsHJCjNZcc1B0Jesk=; b=ATE45xm3TGRH1l1RQ9LiBgbSmlPmilPEr//pY720/Ebh6RmfS5grXgGeD8FpKyTM9R vgeTAQt88dHxd46ajKdlGsfFuL8Hk2gFwb+EgjpQ6fJg7aWjF+0U/2rF76PLAlkkSvc2 /6fqFcqZ9VHMETknHCjlOHHo6oCCGvOven37nedD3ujoAl3UblPcg7OFydOgbBrK2gBI j7D2mzseRTEYcMprf3QX1G/QgqxyhhF4nhpMSazTlGb231hOAlC2fAGYJ4eHJKrL+SS0 fbkwLuhmeFWOK1eauApLAUg1CDbxR019JKmpQPFA8eTWAczVSH4PXbKgERt8Hx2mLxyu 3Qyw== X-Gm-Message-State: AC+VfDx4aepZ0W4Zt264R3w0qhL/WZJSL40OOpoGIY4D0WJqOjuk4EJI c1CZu8hRjTvlaR+jn/emDf2FFs1eCkrkOfTJG7w= X-Received: by 2002:a25:b1a3:0:b0:bca:531d:dcde with SMTP id h35-20020a25b1a3000000b00bca531ddcdemr17325380ybj.30.1687543480780; Fri, 23 Jun 2023 11:04:40 -0700 (PDT) MIME-Version: 1.0 References: <20230623043843.4080180-1-irogers@google.com> In-Reply-To: <20230623043843.4080180-1-irogers@google.com> From: Namhyung Kim Date: Fri, 23 Jun 2023 11:04:29 -0700 Message-ID: Subject: Re: [PATCH v2 1/2] perf pmus: Add notion of default PMU for JSON events To: Ian Rogers Cc: Thomas Richter , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Adrian Hunter , Kan Liang , James Clark , Ravi Bangoria , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 22, 2023 at 9:38 PM Ian Rogers wrote: > > JSON events created in pmu-events.c by jevents.py may not specify a > PMU they are associated with, in which case it is implied that it is > the first core PMU. Care is needed to select this for regular 'cpu', > s390 'cpum_cf' and ARMs many names as at the point the name is first > needed the core PMUs list hasn't been initialized. Add a helper in > perf_pmus to create this value, in the worst case by scanning sysfs. > > Signed-off-by: Ian Rogers > Tested-by: Thomas Richter > > v2. Add missing close if fdopendir fails. Applied both to perf-tools-next after moving this v2 line, thanks!