Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp844936ybz; Fri, 1 May 2020 09:32:41 -0700 (PDT) X-Google-Smtp-Source: APiQypL6r0GrkVbQUAe1yOGM6sPBbW/oQdZy1wXCwJNYtxvPH85OSaujpfv6IuheysKi7c3k/gjB X-Received: by 2002:a17:906:3b8b:: with SMTP id u11mr4084343ejf.352.1588350761515; Fri, 01 May 2020 09:32:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588350761; cv=none; d=google.com; s=arc-20160816; b=V5O1V6lHE91eYgnqywxgSQl8rnB0TGrvYM3ExAFH6xxlyGZ4jU72cCUBkxwE0bu0pn r4wbhiTJfwEEux/F608+8d7YPdYIh2yeqgs4NtmZiybRE/5qIuCBVckRP2b6o9YbJdb2 juXQZD8OIeVfiK36FuUshTWrT7KXq9TAQNJvzYKAisBWdNFZXoOpstmcsdH6LbUKbz2o BNju1O3wgxpLMulSTe5u2ngpZfBUV7MKWjYRSURsJtCWs9vYvPuPOoIeUYDWqmPSUvg/ cnSYg2UPj0to1qiNE+BnicIwzPWQQNJ5dTbrmXtzxHuMkXHl2/u3tLEeCuAx2AvwiV/8 RBkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=LZFbo13vf2wV07Z9Rw/Rb5UPHeQ2gxDTLd7RnWBUNYY=; b=PBN7a32D9EHifmW6gMmfJdSs4ddDgZ0muU5q5w31gvzveNIzcD7NHEOXKDu3I9aZwV Qv2dhi/yT9k8fwcDMZuInIwBetAWPawuY8xZDmP+bCqJPN7Kf8Rx/+xsLm3HYrPP61u3 eGRa+2KAzjnYqC1kONQ4TwasnoPgYgf0s9uhu8eq9AN6l3MXppmCyquu0qMhko3g292n OIaTwcdY+1L8C4g5EwzAGHkV6uFcS6udk56QhSeBnrh8OG2xdLSwneB/MBurHtg+LPVQ 2lqdoYM/WSr4ZAZ2qdJTAOvTt4cx8CXYxXDZ+igE2IiyT30pz1RYEKyylD+6xw5iPSKs TggA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=google header.b=iJ1jj+9u; 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 mj2si2004620ejb.279.2020.05.01.09.32.18; Fri, 01 May 2020 09:32:41 -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=pass header.i=@linuxfoundation.org header.s=google header.b=iJ1jj+9u; 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 S1729634AbgEAQaf (ORCPT + 99 others); Fri, 1 May 2020 12:30:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50864 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728991AbgEAQae (ORCPT ); Fri, 1 May 2020 12:30:34 -0400 Received: from mail-io1-xd42.google.com (mail-io1-xd42.google.com [IPv6:2607:f8b0:4864:20::d42]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 88613C061A0E for ; Fri, 1 May 2020 09:30:34 -0700 (PDT) Received: by mail-io1-xd42.google.com with SMTP id y26so5400783ioj.2 for ; Fri, 01 May 2020 09:30:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=LZFbo13vf2wV07Z9Rw/Rb5UPHeQ2gxDTLd7RnWBUNYY=; b=iJ1jj+9uj29mf+kASJ6SUBvTuuTjHrib0DC3j8oRbbzAbNcPJee6k1g5j2V+5gLEey unvXOu5nkU7cZ03JmDWz+XDhzEpCjA+HYZxy9m9kzq7dL0oB34jCs5i3Dt1RSkUh0v56 j1A+Mt6uyDIT1Yg9e50BhxUxPffIpRmkBjr0M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=LZFbo13vf2wV07Z9Rw/Rb5UPHeQ2gxDTLd7RnWBUNYY=; b=IKsssgBOz+JQqK5bbheZi5qftXWQy9DEk7hE8L9VDsbaYYLoJ4ZM6Cu8BK/8DSmEG8 HoO8n7RsDK+jL84pU3Np3wYa+4xTt1FtFwmviSv3bPMDbkKDpQsgMpvoacJ4ww2T5Vl7 71quv8SKGUKCx9G5+pl1M0O63wAWUKsBLm5YsInP3Ozv/2Z/AFjspzlKeL0T6PXZ0ztR mQIZZTK8n5R6ObIhT22pd8kSlEb+IMOssplmfr9hHAttrV3k5zhgxSPobQ61Xw63MVJG oHw5c3PXmubsQ1U+GkicF0oJ9UmTZK/5jcN0U5ylzWjCPw5+d31pPz0f+HGH2+46qKqu LxwQ== X-Gm-Message-State: AGi0PubDyKLLSYzHCUv+kvAm8pM0NRLB20uZJOCTYjcDiFy/60pbJoof tlY0g+ygBv2m0sa22jdjWb6oVw== X-Received: by 2002:a02:6a4e:: with SMTP id m14mr4044212jaf.17.1588350632708; Fri, 01 May 2020 09:30:32 -0700 (PDT) Received: from [192.168.1.112] (c-24-9-64-241.hsd1.co.comcast.net. [24.9.64.241]) by smtp.gmail.com with ESMTPSA id n8sm1451816ili.18.2020.05.01.09.30.31 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 01 May 2020 09:30:32 -0700 (PDT) Subject: Re: [PATCH 2/3] selftests/ftrace: Pick only the first kprobe event to test To: Steven Rostedt , shuah Cc: Masami Hiramatsu , linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, Tom Zanussi , Li Philip , Liu Yiding , skhan@linuxfoundation.org References: <158834025077.28357.15141584656220094821.stgit@devnote2> <158834027133.28357.11196486193798517250.stgit@devnote2> <20200501101718.5a15e557@gandalf.local.home> <7751734b-83f1-bf14-9d8e-9092b0b7be3e@kernel.org> <20200501122049.46a93bb5@gandalf.local.home> From: Shuah Khan Message-ID: <1bb4a6f8-eafe-7c2d-c6a2-1caae7cc91b9@linuxfoundation.org> Date: Fri, 1 May 2020 10:30:31 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: <20200501122049.46a93bb5@gandalf.local.home> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/1/20 10:20 AM, Steven Rostedt wrote: > On Fri, 1 May 2020 09:38:59 -0600 > shuah wrote: > >> On 5/1/20 8:17 AM, Steven Rostedt wrote: >>> On Fri, 1 May 2020 22:37:51 +0900 >>> Masami Hiramatsu wrote: >>> >>>> Since the kprobe/kprobe_args_type.tc reads out all event logs >>>> from the trace buffer, the test can fail if there is another >>>> fork event happens. >>>> Use head command to pick only the first kprobe event from >>>> the trace buffer to test the argument types. >>>> >>>> Signed-off-by: Masami Hiramatsu >>>> --- >>>> .../ftrace/test.d/kprobe/kprobe_args_type.tc | 2 +- >>>> 1 file changed, 1 insertion(+), 1 deletion(-) >>>> >>>> diff --git a/tools/testing/selftests/ftrace/test.d/kprobe/kprobe_args_type.tc b/tools/testing/selftests/ftrace/test.d/kprobe/kprobe_args_type.tc >>>> index 1bcb67dcae26..81490ecaaa92 100644 >>>> --- a/tools/testing/selftests/ftrace/test.d/kprobe/kprobe_args_type.tc >>>> +++ b/tools/testing/selftests/ftrace/test.d/kprobe/kprobe_args_type.tc >>>> @@ -38,7 +38,7 @@ for width in 64 32 16 8; do >>>> echo 0 > events/kprobes/testprobe/enable >>>> >>>> : "Confirm the arguments is recorded in given types correctly" >>>> - ARGS=`grep "testprobe" trace | sed -e 's/.* arg1=\(.*\) arg2=\(.*\) arg3=\(.*\) arg4=\(.*\)/\1 \2 \3 \4/'` >>>> + ARGS=`grep "testprobe" trace | head -n 1 | sed -e 's/.* arg1=\(.*\) arg2=\(.*\) arg3=\(.*\) arg4=\(.*\)/\1 \2 \3 \4/'` >>>> check_types $ARGS $width >>>> >>>> : "Clear event for next loop" >>> >>> I think I've manually added this exact change to my tests to keep it from >>> failing. >>> >>> Reviewed-by: Steven Rostedt (VMware) >>> >> >> Does this conflict with: >> >> Author: Xiao Yang >> Date: Tue Apr 7 14:34:19 2020 +0800 >> >> selftests/ftrace: Check the first record for kprobe_args_type.tc >> >> https://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest.git/commit/?h=next&id=f0c0d0cf590f71b2213b29a7ded2cde3d0a1a0ba >> >> I went into mainline yesterday in my rc4 pull request. >> >> Exact change it appears. > > Ah, then I guess we don't need this patch ;-) > I took the first one. Will wait for patch 3 to finalize. thanks, -- Shuah