Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp434182img; Wed, 20 Mar 2019 03:52:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqwiO4z3IX/+e14zBXfqYGFwuldp47nntkbB0xlV1cVoENTtVAiEGX0yCvsG3VHogRkubCFM X-Received: by 2002:a63:7341:: with SMTP id d1mr6869478pgn.405.1553079170756; Wed, 20 Mar 2019 03:52:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553079170; cv=none; d=google.com; s=arc-20160816; b=TM5vCjMWUrRCdIh97xs0DKXbWuiAIO/7JQJ0M0GLZjRca6AJjFUp9CU+rYz2G5wbUc 9KYTp0aJ59kMMUDNeaBuIJ9LOU9r/ng5IljhCbWSuS0IypJjTAtl016mj9Id5z+aYEaG HGBRGGBxZQUv1Z5myYolHEZ3tn0LPwZy6WWjkDRAkqXZDpkwJOX2WM2h4BmkY45Wp46d ZKoJj443OdYJQpaXB4aBCEgtX678JLcBDvPA+9hN72qHHbwIKt1X+LwKY34okPfUALWW jhc0owfo3X9vQX6Hf3B94pdHoxFE0Sh6/SX1CaPDDLhbb/HgvszubEOn14Jq62BOLUgb MqeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=byyOSm8fQnY1q7PlStaUHwXQMjLqMHEJhNuztoZtxR4=; b=xvfVNrjoReRUpd4oFQD0lxx/+vbuAXSJ74U37rUQVsbaE3uj2QLC48lmwO31wi0zb4 zuv0uAFQnkziOnWlQK31byb0xf09Fa5NE388gywCmOjsrT1PgIuA6BgHooLDDJROLf4z GcALUc8/kvxKVuk4tOLFJ1TbrylTY4bqwv3LF+QnLWWsUpFR/FJK5dg0rGbxiT8qtFHZ Tzq6/FDeBGGW3ZgDeM+fItBhWW/MtIJ31bnOiUizCOAuu4ZHWhZlnLxsUn9tQ3vjhGXY 5Thl6O5iQIx8BuQdlBurc9qq0xRdhZsshvfMRLgzbbSYEI1cWqqyObs5o+SVbbsq13fi fKmA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cVyXQYpr; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k74si1422840pfb.32.2019.03.20.03.52.35; Wed, 20 Mar 2019 03:52:50 -0700 (PDT) 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; dkim=pass header.i=@linaro.org header.s=google header.b=cVyXQYpr; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727554AbfCTKud (ORCPT + 99 others); Wed, 20 Mar 2019 06:50:33 -0400 Received: from mail-wr1-f66.google.com ([209.85.221.66]:42333 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727126AbfCTKud (ORCPT ); Wed, 20 Mar 2019 06:50:33 -0400 Received: by mail-wr1-f66.google.com with SMTP id n9so2164453wrr.9 for ; Wed, 20 Mar 2019 03:50:31 -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:user-agent; bh=byyOSm8fQnY1q7PlStaUHwXQMjLqMHEJhNuztoZtxR4=; b=cVyXQYprwj44RxS8HhhRms/us7vKBj2RclTh4tc836gzovrZQtA7mgIC8MjzFKT1iY Fw9/ONpAuz8cNUQmkaFdo+4ScduIB89BPef+DYLEJVYosYnKLl67Mcab05YFdjxoyfLF baEwMcbJao0K24XloYi5WOKAhp9qiESx4br+C4aUE/6oARb3Fcr0Omvm5Ls/gGpXzAA5 q8N9KpxR8SvGbkkUiU6R3fxmioN38QFzgC2rEsrn9xMn/JHh1GAT29stSXFl3IuLpedH nP7IeqHnkDTx9n9Fs2OyUfQoDOfzPve05nPbB6goIVomHF4ulV+Q1R60BrTgIfsm136E zeFg== 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:user-agent; bh=byyOSm8fQnY1q7PlStaUHwXQMjLqMHEJhNuztoZtxR4=; b=DrSaGf7+jbsEZsjoqkTbWArDjnCWvzUyU/1I6MMVr2r1/fN0SZQilxgtZn4eAur0aY FQ8boaZoSOeYajS77GoKYxXGbfls5yZSaJM+4D6K61D5V0vCMnc+YdOfUy0r5oXZiMqq eFBXDsa27teA3FzuWGRxS4sVPQ9BK+zWDZctwkJ29GlmeYauPj2kLwetlQhVMtVFot32 6KupDcG5oDcQobcmAqfOB9oGePVNt+Be9bA+DeS+dz5/jRW/GKQmm1mDwXtXccvcwHoV 3opJhBfaW/VCaq+UizlmbZrHiLEt/R719nAPCUaN/Z/nQyQNpljYOj9GQI/0QrO0Dy2U ZQ3g== X-Gm-Message-State: APjAAAXBqE9BqolSVjSpiWu1YCgcwl6YN0KHXWO717NSxVkS815MrTdu JGaYUshx5w1bp0Yt2yWfYfWn0A== X-Received: by 2002:adf:ea05:: with SMTP id q5mr5047976wrm.152.1553079031135; Wed, 20 Mar 2019 03:50:31 -0700 (PDT) Received: from holly.lan (cpc141214-aztw34-2-0-cust773.18-1.cable.virginm.net. [86.9.19.6]) by smtp.gmail.com with ESMTPSA id r12sm2629537wrr.71.2019.03.20.03.50.30 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 20 Mar 2019 03:50:30 -0700 (PDT) Date: Wed, 20 Mar 2019 10:50:28 +0000 From: Daniel Thompson To: Douglas Anderson Cc: Steven Rostedt , Ingo Molnar , Jason Wessel , kgdb-bugreport@lists.sourceforge.net, Brian Norris , linux-kernel@vger.kernel.org Subject: Re: [PATCH v6 3/3] tracing: kdb: Allow ftdump to skip all but the last few entries Message-ID: <20190320105028.6t6urpf344mljb2g@holly.lan> References: <20190319171206.97107-1-dianders@chromium.org> <20190319171206.97107-3-dianders@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190319171206.97107-3-dianders@chromium.org> User-Agent: NeoMutt/20180716 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 19, 2019 at 10:12:06AM -0700, Douglas Anderson wrote: > The 'ftdump' command in kdb is currently a bit of a last resort, at > least if you have lots of traces turned on. It's going to print a > whole boatload of data out your serial port which is probably running > at 115200. This could easily take many, many minutes. > > Usually you're most interested in what's at the _end_ of the ftrace > buffer, AKA what happened most recently. That means you've got to > wait the full time for the dump. The 'ftdump' command does attempt to > help you a little bit by allowing you to skip a fixed number of > entries. Unfortunately it provides no way for you to know how many > entries you should skip. > > Let's do similar to python and allow you to use a negative number to > indicate that you want to skip all entries except the last few. This > allows you to quickly see what you want. > > Note that we also change the printout in ftdump to print the > (positive) number of entries actually skipped since that could be > helpful to know when you've specified a negative skip count. > > Signed-off-by: Douglas Anderson > --- > > Changes in v6: > - Keep tracing disabled between counting and dumping. > - Remove Daniel Thompson Ack due to changes between v5 and v6. ... and I'm very happy to replace it: Acked-by: Daniel Thompson Daniel.