From patchwork Wed Jan 17 16:11:51 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnaldo Carvalho de Melo X-Patchwork-Id: 124824 Delivered-To: patch@linaro.org Received: by 10.46.62.1 with SMTP id l1csp97526lja; Wed, 17 Jan 2018 08:12:51 -0800 (PST) X-Google-Smtp-Source: ACJfBotbuxdpHzXjsU6QR9iChhURy4Ybda0KhDsQ6T5WmyuDKB+Xq/eoPfVJmqE3+aleE2Nw7/7L X-Received: by 10.84.233.136 with SMTP id l8mr14504760plk.394.1516205571017; Wed, 17 Jan 2018 08:12:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516205571; cv=none; d=google.com; s=arc-20160816; b=tsW8s5BkS4MzOYUaZjZWnPDAeRHGoSIUhHhNEM6U3LqoRIDZv2spaeq8Pvg6JFVf0F fUlCxlf3O5CsLZyOccsXb3P3bKE6189fJmobm7/eHqpepKLifS8Ku76V4fqRmd5WskZa Pt3tBCNaKm/mCWSZ0hZBCdi4uQEGOKd0+y+iK3QUv8/TxEbBgE5Z5uLnCm2dIQYMe5us ba+KzuMl8wR8/X4uBztnofE6Q0Xg1Nd78Z7PBJtK/uyzQzfH/mu7Eo5glwvoYlDj+iZK FagkFHOL1XWs7kC1HbRZUomfQ6vQHd5vRicwAGxxgjNYcmINCXUvh2MK43AO5Uhwt0rg tGVQ== 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:dmarc-filter:arc-authentication-results; bh=T92NVgA++Yc1mEnh1BRyVyl17W/FJ8LvxGdBd5rSzhI=; b=pL5S0H5gFks3jKZi7BqoqPo90tbn+jpDATIcHpetimnqVNIPV/VZkEuE6kdoYHOUrR WjnujTZSTbuCtihNhP8hUjIeMPNPUd1KGsmylsWbAI3UAjJOAdOEGwYagMrO6aSE0Ysi oIkXVAcLTYITHwUm74EgaSWxxijxtWIiH1VkNeipfXhGI+N57Dhtu2Mf4xgd/U0PvfH4 xugafRrWskjW0hNGhs8cJrN7DYoDOnbE6RhevCkxaD9X6CmLGIMgstuG6td0dXoSpS8i gV7sicu1qbgCQR1uGzLAF6qy33vSlwENUUi1kEJ5CrrH47weUX/NLaRjoHGGpkxqlTtD 6HtA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f81si4719912pff.45.2018.01.17.08.12.50; Wed, 17 Jan 2018 08:12:51 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753867AbeAQQMt (ORCPT + 28 others); Wed, 17 Jan 2018 11:12:49 -0500 Received: from mail.kernel.org ([198.145.29.99]:55466 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753739AbeAQQMq (ORCPT ); Wed, 17 Jan 2018 11:12:46 -0500 Received: from jouet.infradead.org (unknown [179.97.41.186]) (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 147DA2175C; Wed, 17 Jan 2018 16:12:43 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 147DA2175C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=acme@kernel.org From: Arnaldo Carvalho de Melo To: Ingo Molnar Cc: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, Mathieu Poirier , Alexander Shishkin , Andi Kleen , Namhyung Kim , Peter Zijlstra , Arnaldo Carvalho de Melo Subject: [PATCH 01/32] perf evsel: Fix incorrect handling of type _TERM_DRV_CFG Date: Wed, 17 Jan 2018 13:11:51 -0300 Message-Id: <20180117161222.15611-2-acme@kernel.org> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180117161222.15611-1-acme@kernel.org> References: <20180117161222.15611-1-acme@kernel.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mathieu Poirier Commit ("d0565132605f perf evsel: Enable type checking for perf_evsel_config_term types") assumes PERF_EVSEL__CONFIG_TERM_DRV_CFG isn't used and as such adds a BUG_ON(). Since the enumeration type is used in macro ADD_CONFIG_TERM() the change break CoreSight trace acquisition. This patch restores the original code. Signed-off-by: Mathieu Poirier Acked-by: Jiri Olsa Cc: Alexander Shishkin Cc: Andi Kleen Cc: Namhyung Kim Cc: Peter Zijlstra Fixes: d0565132605f ("perf evsel: Enable type checking for perf_evsel_config_term types") Link: http://lkml.kernel.org/r/1515617211-32024-1-git-send-email-mathieu.poirier@linaro.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/evsel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.14.3 diff --git a/tools/perf/util/evsel.c b/tools/perf/util/evsel.c index d934f04e3110..4eea3b404507 100644 --- a/tools/perf/util/evsel.c +++ b/tools/perf/util/evsel.c @@ -781,7 +781,7 @@ static void apply_config_terms(struct perf_evsel *evsel, attr->write_backward = term->val.overwrite ? 1 : 0; break; case PERF_EVSEL__CONFIG_TERM_DRV_CFG: - BUG_ON(1); + break; default: break; }