Received: by 2002:a25:ca44:0:0:0:0:0 with SMTP id a65csp118209ybg; Mon, 27 Jul 2020 17:31:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwDuxSpLdNT6vLDj69LShAV+NnNxs7mRw8L1u1vvtgshaLygt6WlXYx0DZO5PN9CF3+kfh3 X-Received: by 2002:a17:906:819:: with SMTP id e25mr7662505ejd.95.1595896305011; Mon, 27 Jul 2020 17:31:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595896305; cv=none; d=google.com; s=arc-20160816; b=rZCDG682um+3InQAygchW4bu22fzwN1wJtECKJ5Ooh57JHfGk9CdX3bUjzs5XmMTTy OnwZZKIvPce+9wQGFRk7LWJuY0DIiC1SiW7f4aEhTFSRfkMZ3FvddsuzRS2lhbYmGDXe gVUQmsCbggYbvVfSUV1+9W+5UHovodclFcwnPrlDUod81YPSiTEWY43cCdTVkeFeSHja RC7NvkiSyMAp44/mjY2/k2JWPaPzrMFj1vSjap4j6u+4UpvY3+JXUPY/e+XckD1Kuhma gFMedLWBVF0X2ivdDTC0acvn8jtXsAy0jN5aWCCXvGVUXEWGm5rwiEOV0NGgDyFpRTOR 2xZA== 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:dmarc-filter:dkim-signature; bh=+om2piDGXGBlw4ipkgZQ7yTsnGbyw5aoar8ai8lEEUc=; b=s9ZjMWfmKlvQcLtQCRSLdap45QE8oOAFV764FGa/2fR+igeRqShli6/lrkz2Lvyhhe AtviltsBwr2+gXCWkzomgv6Iznog/Ku5PUrlF2VCQJla8vyc4oyYa/vLlDaiyJ0NOHSz jTx/aclPbhvQJWMRBqTrYpeRAM8E3G5skP6W+iBm8lpCG/rg4rRywzrdRV/0HoBLolva z7RFvp3bBVxwjn7btowPqgNBaNcR1H8dozfQkr49pKxvxWZOZiYn0WdL3cLX6DsyYQwg 3w/Am0DS5TsopoQe7l8aywRWqRFcWjjj6d0hrGNj4U0ZvKW/LeyeReo65lpWH+5hY8Ol MwaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=BuOwFYfx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a3si6420137eju.177.2020.07.27.17.31.12; Mon, 27 Jul 2020 17:31:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=BuOwFYfx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726283AbgG1A2j (ORCPT + 99 others); Mon, 27 Jul 2020 20:28:39 -0400 Received: from mail29.static.mailgun.info ([104.130.122.29]:32381 "EHLO mail29.static.mailgun.info" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726196AbgG1A2i (ORCPT ); Mon, 27 Jul 2020 20:28:38 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1595896118; h=In-Reply-To: Content-Type: MIME-Version: References: Message-ID: Subject: Cc: To: From: Date: Sender; bh=+om2piDGXGBlw4ipkgZQ7yTsnGbyw5aoar8ai8lEEUc=; b=BuOwFYfxbpPDBRUIxzHyfkyLPCL9T6buBCEr4EkaXt6yILpdiIboGD5HaAycIxKlfXE/eiwk aGCH6E6EBbc/RTnr6SSfsyu+iPEe5bbk0Lssu8+EJq3AJZvqJcMpoXcyx34o5hREhKIKMTPK QOhT7iOkOIizgC0eFh1Die4nN54= X-Mailgun-Sending-Ip: 104.130.122.29 X-Mailgun-Sid: WyI0MWYwYSIsICJsaW51eC1rZXJuZWxAdmdlci5rZXJuZWwub3JnIiwgImJlOWU0YSJd Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by smtp-out-n10.prod.us-east-1.postgun.com with SMTP id 5f1f71307186ea1ee15ac688 (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Tue, 28 Jul 2020 00:28:32 GMT Received: by smtp.codeaurora.org (Postfix, from userid 1001) id 3C360C43391; Tue, 28 Jul 2020 00:28:32 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=2.0 tests=ALL_TRUSTED,SPF_NONE, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from codeaurora.org (unknown [180.166.53.21]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: tingwei) by smtp.codeaurora.org (Postfix) with ESMTPSA id 1D2CEC433C9; Tue, 28 Jul 2020 00:28:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 1D2CEC433C9 Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=none smtp.mailfrom=tingweiz@codeaurora.org Date: Tue, 28 Jul 2020 08:28:23 +0800 From: Tingwei Zhang To: Steven Rostedt Cc: Tingwei Zhang , Ingo Molnar , tsoni@codeaurora.org, Sai Prakash Ranjan , Mao Jinlong , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 6/6] stm class: ftrace: use different channel accroding to CPU Message-ID: <20200728002823.GA10290@codeaurora.org> References: <20200726025931.30510-1-tingwei@codeaurora.org> <20200726025931.30510-7-tingwei@codeaurora.org> <20200727150812.3051fa7d@oasis.local.home> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200727150812.3051fa7d@oasis.local.home> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Steve, On Tue, Jul 28, 2020 at 03:08:12AM +0800, Steven Rostedt wrote: > On Sun, 26 Jul 2020 10:59:31 +0800 > Tingwei Zhang wrote: > > > --- a/drivers/hwtracing/stm/ftrace.c > > +++ b/drivers/hwtracing/stm/ftrace.c > > @@ -37,8 +37,9 @@ static void notrace > > stm_ftrace_write(struct trace_export *export, const void *buf, unsigned > int len) > > { > > struct stm_ftrace *stm = container_of(export, struct stm_ftrace, > ftrace); > > + unsigned int cpu = smp_processor_id(); > > Probably should add a comment to the above stating that this is called > from the tracing system with preemption disabled. > Good point. I'll add that comment in next revision. Thanks, Tingwei > Other than my two comments: > > Reviewed-by: Steven Rostedt (VMware) > > -- Steve > > > > > > - stm_source_write(&stm->data, STM_FTRACE_CHAN, buf, len); > > + stm_source_write(&stm->data, STM_FTRACE_CHAN + cpu, buf, len); > > } > > > > static int stm_ftrace_link(struct stm_source_data *data)