From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E5702C4338F for ; Mon, 2 Aug 2021 17:03:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C3C0360F6E for ; Mon, 2 Aug 2021 17:03:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229979AbhHBRDV (ORCPT ); Mon, 2 Aug 2021 13:03:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59852 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229622AbhHBRDU (ORCPT ); Mon, 2 Aug 2021 13:03:20 -0400 Received: from mail-pj1-x102d.google.com (mail-pj1-x102d.google.com [IPv6:2607:f8b0:4864:20::102d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 31BC6C061760 for ; Mon, 2 Aug 2021 10:03:11 -0700 (PDT) Received: by mail-pj1-x102d.google.com with SMTP id mz5-20020a17090b3785b0290176ecf64922so32606239pjb.3 for ; Mon, 02 Aug 2021 10:03:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=7ZboOedxV5HocqOHed9R2rRbrksyFeYlZ+bzi9mMGLY=; b=LxqcaZ5ls/BOk7qlIHclYJaTgBc2zgv0mf+NcRmW6VNMuOkd3+mRfSMmBy3x3DmtJ/ hEPoMS+w5jwfrazMQS9fnffRSiC0ySFHteH86CjbojEfmv66jO5Er9mCohSihq/6J5de YzOwaTt1q40A2OKERsE7PGWVOBkk1qYHboQDXcFotsSfi+QBnm4QWsF2gCwI5SV5t4xQ qRkPRiISU58yhasSB3FT/dUvBzp27Fm/4bhX9nG06REZGvWsZdjtnG/iUXmqSS2/jw1l ClKrnmyp4qtHbS5AjfsFX60e/N/CmcR3S0LUce+QxyP1frI0B2Qb+EhkooN/y/uytWph iw1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=7ZboOedxV5HocqOHed9R2rRbrksyFeYlZ+bzi9mMGLY=; b=ltuxtgcHEIUYPpFUIrAJ/8LCG+rDtdlnAbc+aCQ0tZNxKjS1eWM3jjpD2qc7Fg04Tc oXb/uOSTDbaoZpg7qQZqyq+9KYmgF39jA4IgG7bkt3t/SJd2S87K0khihvCtGh92IfvD Eg1adLuGcCdfjHunN/y+KI/xu3bjnchwbSt18wsGyXnpkfJIU5cpgx1SkHpkzmA0GLlE u3w38uEGvStxSyei964KiumBbkIHaJI4XtRaNQB79CXy2T+VP3+ywJdPi7eELxABkJoU FaPLYB/PmuMsRgySQQeSmKlSissbMg/MZ/Yxe4+aawAUY4rJUO+hmmxcse4e8CS43Niy iLzQ== X-Gm-Message-State: AOAM5307NhEtFSzL/6DQrZXBLgdibDd4o7tWeEClEDN1qBOyrba7UYLI UrGbQVo2jQbMsrSJJLgicmzCEelSHnakzw== X-Google-Smtp-Source: ABdhPJzuVMYUebwEDSBI4cgcoZX8B3pB36R84r8+jtf5HlnloTUgZf6D9ns/m8VfbywUtVzecbWQog== X-Received: by 2002:a17:902:6904:b029:fb:42b6:e952 with SMTP id j4-20020a1709026904b02900fb42b6e952mr14857532plk.16.1627923790701; Mon, 02 Aug 2021 10:03:10 -0700 (PDT) Received: from p14s (S0106889e681aac74.cg.shawcable.net. [68.147.0.187]) by smtp.gmail.com with ESMTPSA id t12sm544131pgo.56.2021.08.02.10.03.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Aug 2021 10:03:09 -0700 (PDT) Date: Mon, 2 Aug 2021 11:03:07 -0600 From: Mathieu Poirier To: Arnaldo Carvalho de Melo Cc: James Clark , coresight@lists.linaro.org, linux-perf-users@vger.kernel.org, leo.yan@linaro.org, suzuki.poulose@arm.com, mike.leach@linaro.org, Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , John Garry , Will Deacon , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [RFC PATCH 6/6] perf cs-etm: Add warnings for missing DSOs Message-ID: <20210802170307.GA3050918@p14s> References: <20210729155805.2830-1-james.clark@arm.com> <20210729155805.2830-7-james.clark@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Aug 02, 2021 at 11:51:58AM -0300, Arnaldo Carvalho de Melo wrote: > Em Thu, Jul 29, 2021 at 04:58:05PM +0100, James Clark escreveu: > > Currently decode will silently fail if no binary data is available for > > the decode. This is made worse if only partial data is available because > > the decode will appear to work, but any trace from that missing DSO will > > silently not be generated. > > > > Add a UI popup once if there is any data missing, and then warn in the > > bottom left for each individual DSO that's missing. > > Looks ok to me (the last 3 patches in this series, the rest I applied > already), can I get some Acked-by/Reviewed-by from the CoreSight people? > I have a substantial backlog of patches to go through and I will be away for the next two weeks. As such it will be some time before I get to review this set. Regards, Mathieu > Thanks, > > - Arnaldo > > > Signed-off-by: James Clark > > --- > > tools/perf/util/cs-etm.c | 10 +++++++++- > > 1 file changed, 9 insertions(+), 1 deletion(-) > > > > diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c > > index 32ad92d3e454..e6851260d059 100644 > > --- a/tools/perf/util/cs-etm.c > > +++ b/tools/perf/util/cs-etm.c > > @@ -746,8 +746,16 @@ static u32 cs_etm__mem_access(struct cs_etm_queue *etmq, u8 trace_chan_id, > > > > len = dso__data_read_offset(al.map->dso, machine, offset, buffer, size); > > > > - if (len <= 0) > > + if (len <= 0) { > > + ui__warning_once("CS ETM Trace: Missing DSO. Use 'perf archive' to export data from the traced system.\n"); > > + if (!al.map->dso->auxtrace_warned) { > > + pr_err("CS ETM Trace: Debug data not found for address %#"PRIx64" in %s\n", > > + address, > > + al.map->dso->long_name ? al.map->dso->long_name : "Unknown"); > > + al.map->dso->auxtrace_warned = true; > > + } > > return 0; > > + } > > > > return len; > > } > > -- > > 2.28.0 > > > > -- > > - Arnaldo From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-14.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 85234C4338F for ; Mon, 2 Aug 2021 17:05:29 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4472160F6E for ; Mon, 2 Aug 2021 17:05:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 4472160F6E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=YXC+huRNi9Z1vhFWHPteZIcBYiC9uVwDPpbkXP8Mlvk=; b=jYjECSxNTf01Ee 2w7I2OYeUGoGtc8drYGzvrLmiPkYJvpQXljDrnv1vjzW3Twe0fo+iQ+Zape7lqeDLLjY141WX8Ebi GhbAgZkG6Sku7pBsoYLf+NQpuA/rdhv0L8RfIme6xLju/wixiTvd/v6f0yyrhxzQydS71ikKRavtk XnFBag4pP/uttk/hiRIbKuZadO+0oYP0slfidmcQ8MrK8V1K+JQHZ3ttO2WFcl0GajLra8JFDGwoS 1jLLM2E8nAJu5atTtDGS4VPWddxNMKBkHkFaQR7ZbVh8ORvvB035J6SSUhoUpwfexvIy7CIvCFd73 gyUbmusdoFPAcOxSWt3w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mAbLP-00HHrP-UI; Mon, 02 Aug 2021 17:03:16 +0000 Received: from mail-pl1-x62f.google.com ([2607:f8b0:4864:20::62f]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mAbLM-00HHqv-MF for linux-arm-kernel@lists.infradead.org; Mon, 02 Aug 2021 17:03:14 +0000 Received: by mail-pl1-x62f.google.com with SMTP id q2so20344125plr.11 for ; Mon, 02 Aug 2021 10:03:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=7ZboOedxV5HocqOHed9R2rRbrksyFeYlZ+bzi9mMGLY=; b=LxqcaZ5ls/BOk7qlIHclYJaTgBc2zgv0mf+NcRmW6VNMuOkd3+mRfSMmBy3x3DmtJ/ hEPoMS+w5jwfrazMQS9fnffRSiC0ySFHteH86CjbojEfmv66jO5Er9mCohSihq/6J5de YzOwaTt1q40A2OKERsE7PGWVOBkk1qYHboQDXcFotsSfi+QBnm4QWsF2gCwI5SV5t4xQ qRkPRiISU58yhasSB3FT/dUvBzp27Fm/4bhX9nG06REZGvWsZdjtnG/iUXmqSS2/jw1l ClKrnmyp4qtHbS5AjfsFX60e/N/CmcR3S0LUce+QxyP1frI0B2Qb+EhkooN/y/uytWph iw1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=7ZboOedxV5HocqOHed9R2rRbrksyFeYlZ+bzi9mMGLY=; b=VHL9A0SW0iEDlYTcm3TjQsTbpUS91yToh+xYy5tbbjHKSrS11Nz0SkAoc+WBtgqug3 8xwkfPNIAtlRZYtuD8uj6rLFg9TegnR+8EarKPhFvulnIjiqTPhbyc3LDI4adZd2+Xka NbmF8uV7z8e1cY/5YE59W/MmqKA8NS59f78u7NzDcySHDtW5I/pDCb5pymZmD8sTC6kM Fevkj7cLWFlavwgNWltSaxFhwcB4O3nwZ4PUBWEe51shWbQFRNJtrtmTnNu78wphXDCi 75Qy4kpShBncNPUlns8MNwbQS3/Z0L+PMKpqceDXvU/EzjfDX75ZDZUoMZp4B/aKy6JX h/oA== X-Gm-Message-State: AOAM532DP+HJ2w80ArH0Zm6+7VlrQ3mEV8cC38XAvcFhUh4LkcS7bRw7 YzRqWAAC5Cp7mxtH2J03GjxdYA== X-Google-Smtp-Source: ABdhPJzuVMYUebwEDSBI4cgcoZX8B3pB36R84r8+jtf5HlnloTUgZf6D9ns/m8VfbywUtVzecbWQog== X-Received: by 2002:a17:902:6904:b029:fb:42b6:e952 with SMTP id j4-20020a1709026904b02900fb42b6e952mr14857532plk.16.1627923790701; Mon, 02 Aug 2021 10:03:10 -0700 (PDT) Received: from p14s (S0106889e681aac74.cg.shawcable.net. [68.147.0.187]) by smtp.gmail.com with ESMTPSA id t12sm544131pgo.56.2021.08.02.10.03.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Aug 2021 10:03:09 -0700 (PDT) Date: Mon, 2 Aug 2021 11:03:07 -0600 From: Mathieu Poirier To: Arnaldo Carvalho de Melo Cc: James Clark , coresight@lists.linaro.org, linux-perf-users@vger.kernel.org, leo.yan@linaro.org, suzuki.poulose@arm.com, mike.leach@linaro.org, Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , John Garry , Will Deacon , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [RFC PATCH 6/6] perf cs-etm: Add warnings for missing DSOs Message-ID: <20210802170307.GA3050918@p14s> References: <20210729155805.2830-1-james.clark@arm.com> <20210729155805.2830-7-james.clark@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210802_100312_802344_CFDACE4A X-CRM114-Status: GOOD ( 28.63 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Aug 02, 2021 at 11:51:58AM -0300, Arnaldo Carvalho de Melo wrote: > Em Thu, Jul 29, 2021 at 04:58:05PM +0100, James Clark escreveu: > > Currently decode will silently fail if no binary data is available for > > the decode. This is made worse if only partial data is available because > > the decode will appear to work, but any trace from that missing DSO will > > silently not be generated. > > > > Add a UI popup once if there is any data missing, and then warn in the > > bottom left for each individual DSO that's missing. > > Looks ok to me (the last 3 patches in this series, the rest I applied > already), can I get some Acked-by/Reviewed-by from the CoreSight people? > I have a substantial backlog of patches to go through and I will be away for the next two weeks. As such it will be some time before I get to review this set. Regards, Mathieu > Thanks, > > - Arnaldo > > > Signed-off-by: James Clark > > --- > > tools/perf/util/cs-etm.c | 10 +++++++++- > > 1 file changed, 9 insertions(+), 1 deletion(-) > > > > diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c > > index 32ad92d3e454..e6851260d059 100644 > > --- a/tools/perf/util/cs-etm.c > > +++ b/tools/perf/util/cs-etm.c > > @@ -746,8 +746,16 @@ static u32 cs_etm__mem_access(struct cs_etm_queue *etmq, u8 trace_chan_id, > > > > len = dso__data_read_offset(al.map->dso, machine, offset, buffer, size); > > > > - if (len <= 0) > > + if (len <= 0) { > > + ui__warning_once("CS ETM Trace: Missing DSO. Use 'perf archive' to export data from the traced system.\n"); > > + if (!al.map->dso->auxtrace_warned) { > > + pr_err("CS ETM Trace: Debug data not found for address %#"PRIx64" in %s\n", > > + address, > > + al.map->dso->long_name ? al.map->dso->long_name : "Unknown"); > > + al.map->dso->auxtrace_warned = true; > > + } > > return 0; > > + } > > > > return len; > > } > > -- > > 2.28.0 > > > > -- > > - Arnaldo _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel