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=-4.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no 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 EF09AC07E99 for ; Mon, 12 Jul 2021 11:38:34 +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 AFBBC610CD for ; Mon, 12 Jul 2021 11:38:34 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org AFBBC610CD Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@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=HVEjr5xNNt29ynObTTx4gADIllhK6ZKWUTVebBnh2Wk=; b=d1UhuAjIV9W3gZ 4vWKiG2+iVuJN9a1RkuNSOqZ4/s4WxcUaEWBRFtpdJpDXkRepPHPHfUk4MlpF7kJu6cYUVAKxJbPP dX5wqPgIeN76awVM1dAo+rOycZVbgjXRb7c5MwlKT+a+JJWqtaZLPokSnAXFbu0HH4WJxqbbu9xvo zgPabMsqOjoRh6zBzoib+oMTls+guAGzPeLH/3gsh2WkpNa35IHlWjIP7ymuGK6tNf/q4VyxvZ1Hl BpO0Cq0bLqSwr3sOwsTAiYvkCegyd+tuTob0vGBegaL5GIY/H7VI5nGuNleZYgGbzyb7kgyTm6v71 FRkXJPblCR/23O4H5LOA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1m2uF7-0079LA-Fw; Mon, 12 Jul 2021 11:36:57 +0000 Received: from mail-pg1-x52e.google.com ([2607:f8b0:4864:20::52e]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1m2uF2-0079KJ-Ml for linux-arm-kernel@lists.infradead.org; Mon, 12 Jul 2021 11:36:54 +0000 Received: by mail-pg1-x52e.google.com with SMTP id u14so17890055pga.11 for ; Mon, 12 Jul 2021 04:36:51 -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=Y+E7UM9kDcTj1OatIHLBQBBbGJOQUqV17bP46qe4xL0=; b=SOgVkqEOzNScO3XJav73raze/kczq+VDiSGwyDfgebmUaOm6ZdKreXShk9wcURT/p0 vJXj4NqzUhjhRV+DWB4Xuo7GC5koGx87eLY8aCkGmS1L+iOzYKHp9f/Q53FBBJeE6pVr 2ggHmLZIJvY/gMHBa07OXMZtjy5kscMeUIBqNpQxq4UU0PLGiGr+Ag3dfykiyoXpW2OD B5MzhnW12ZCLcwTjs7u/srn85cbRLhmvgK81svZkCmcMhJoefrAJJOLsku+pzmRaPq1t xqkAI6TIIUCI4EAWUFA7tw/w+leFdRlneX2NY4jqt9sr+8fuEZ/0TG0MxQMyIoFcfDKX qPNQ== 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=Y+E7UM9kDcTj1OatIHLBQBBbGJOQUqV17bP46qe4xL0=; b=tN0SfdIGJUOU+bnOzB1UB7seQIl4RMH9z0Hp0zhrLmKMr/wtWYaNwxYWA3DdLBsrdB xYigQsm5z7HQoMXwxUndYXdRIP42A5Ud3uwnmvRlBjmMR3A9Y4LH/9mH+QDVFpNVxdNF eI0eIVXZWqql68I6Y/0Q6W0oh79IYvFfuS1e1Y3tjTM0y3K8/D0LCBuKTJachaqpGg21 Zm4WuHFNdtwRd8RRLD+LPsPhDqzOaP6fZRZgltTLQq57Ddse9Nzh3cvU7pU/xQapoLJw Kxsb8g4qBBOgr9B2tiy/tRhUZGPzf5lhFKH9O9mO0PqW37KcFShFw1er10epDsepuh0L MUDA== X-Gm-Message-State: AOAM532wF2lkQtC1cbGb6CNA25wAbkH1IosoBqL10+0pYL6kdkbsvgGz MNPJhgXVVlvVsqitgjVe5zXT1wQbFWJQbarG X-Google-Smtp-Source: ABdhPJz9brakuugW40ZFycuwYcI9zTqD3ilnR8HuqvhDg1VELvrTYhpRXA/8aZ2tymrt+oD8BGeGig== X-Received: by 2002:a63:f901:: with SMTP id h1mr53579200pgi.69.1626089811384; Mon, 12 Jul 2021 04:36:51 -0700 (PDT) Received: from leoy-ThinkPad-X240s ([202.155.204.36]) by smtp.gmail.com with ESMTPSA id g4sm18423878pgn.45.2021.07.12.04.36.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Jul 2021 04:36:50 -0700 (PDT) Date: Mon, 12 Jul 2021 19:36:46 +0800 From: Leo Yan To: Suzuki K Poulose Cc: Mathieu Poirier , Mike Leach , Alexander Shishkin , coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] coresight: tmc-etr: Speed up for bounce buffer in flat mode Message-ID: <20210712113646.GD704210@leoy-ThinkPad-X240s> References: <20210710070115.462674-1-leo.yan@linaro.org> <20210712110916.GB704210@leoy-ThinkPad-X240s> <5f3148bf-3efa-5866-b426-8bab4eb40282@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <5f3148bf-3efa-5866-b426-8bab4eb40282@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210712_043652_822260_0A623D3B X-CRM114-Status: GOOD ( 20.22 ) 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, Jul 12, 2021 at 12:17:04PM +0100, Suzuki Kuruppassery Poulose wrote: [...] > > I am doubt why you conclude "always start tracing at the beginning of > > the buffer"? I read the driver but cannot find any code in the driver > > to reset rrp and rwp after fetching the trace data, or there have any > > implict operation to reset pointers? > > The ETR is always programmed with the base address of the "ETR" buffer, > which is *not the same* as the perf ring buffer, since we always do > double buffering. We do not program the RRP/RWP of the ETR (except > for the SoC-600, where it is mandatory and we set them to the base > address). Thus there is no context associated with the ETR buffer. > But at the end of the run, we do read the RRP/ RWP to figure out > where the ETR has reached. > > As for reseting the RRP / RWP, at the beginning of a session, is > done implicitly for the ETR (except for SoC-600 ETRs as explained > above) by the hardware to the base address. Yes, I finally matched your description with the code. Will respin patch for this. Thanks for confirmation! Leo _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel