Received: by 10.192.165.148 with SMTP id m20csp532071imm; Wed, 25 Apr 2018 03:48:05 -0700 (PDT) X-Google-Smtp-Source: AIpwx4//ybdvyKY/q3uepJTlPeUGCtccqOQVGWb/3rw50J1JrjULAyzMzTn28gSsDEFiNPsouk9s X-Received: by 10.101.70.200 with SMTP id n8mr21914655pgr.62.1524653285841; Wed, 25 Apr 2018 03:48:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524653285; cv=none; d=google.com; s=arc-20160816; b=pVLisgikNInIht7EEOcgBNyFyiMELvx930R0f09EMpWKv5v1JMUFfePHMagYzwI+ZO ixjd3P0ThtuUdU3uhoR+uPAOdSIx1pmZpqsvgxkFrNnhZADIdKRlNmsf2UtuuEqtS8cP 4/AkKRCJE2RyhxSQTUpnoz9Bn9qsOxfkwTAsT6QCGaKOEIw+nMYM2++HNN8/fAx2x/EZ FlxLtAPB6tvYshdDYMwukAZ3XGY5xIJ28dN8PnX37zui0fEJExbU6ZHRNEyjaWD/M5b+ s1xKeABjL9wi1ZOBshOpnHfo+wyo2bvMyfvUJ7pNXng4moXiJKDplRltNNI/zZ9LkLpL r+eA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=fLPs8nRfa/hzjEYEPLYPr/IhUlZBKyncAb+P5J/EtxU=; b=Vxbhrx7+Ogq1EF1RfGW1wQ0FoyEmPr9V1k/YszHHROyDgE47jlYVBEQciMraWsVzES 3eVqdNNWlBEp2ZAHxm4qPK0v1fWzD9Tpw3gNG01VpkDC8g8+UdsovfFlpN6QQMl0RPbS /aScakOboucpmbFdPvPLUKq473vv50FfaK5RuIQiQVz5XW/Cac+b+o8MBEWoSJ2vOpND HBTSkMQNki/S3+xZ+C2yC6ksn1xVBmPzax9HUeKZXz3H67WkY/BocBjp4bFlQiqHfEQ9 7+zCZxdVLSyWxud+jH3BannTlm/V+Gm8qZw78FJolwZ4w57JsM2qt/oCt1sX04/B9CSW rUsA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y101-v6si15993661plh.188.2018.04.25.03.47.51; Wed, 25 Apr 2018 03:48:05 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754539AbeDYKp0 (ORCPT + 99 others); Wed, 25 Apr 2018 06:45:26 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:53528 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754488AbeDYKpM (ORCPT ); Wed, 25 Apr 2018 06:45:12 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id D64F2266; Wed, 25 Apr 2018 10:45:11 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Shuah Khan , Masami Hiramatsu , "Steven Rostedt (VMware)" , Sasha Levin Subject: [PATCH 4.14 152/183] selftests/ftrace: Add some missing glob checks Date: Wed, 25 Apr 2018 12:36:12 +0200 Message-Id: <20180425103248.644594158@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180425103242.532713678@linuxfoundation.org> References: <20180425103242.532713678@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: "Steven Rostedt (VMware)" [ Upstream commit 97fe22adf33f06519bfdf7dad33bcd562e366c8f ] Al Viro discovered a bug in the glob ftrace filtering code where "*a*b" is treated the same as "a*b", and functions that would be selected by "*a*b" but not "a*b" are not selected with "*a*b". Add tests for patterns "*a*b" and "a*b*" to the glob selftest. Link: http://lkml.kernel.org/r/20180127170748.GF13338@ZenIV.linux.org.uk Cc: Shuah Khan Acked-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc | 6 ++++++ 1 file changed, 6 insertions(+) --- a/tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc +++ b/tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc @@ -29,6 +29,12 @@ ftrace_filter_check '*schedule*' '^.*sch # filter by *, end match ftrace_filter_check 'schedule*' '^schedule.*$' +# filter by *mid*end +ftrace_filter_check '*aw*lock' '.*aw.*lock$' + +# filter by start*mid* +ftrace_filter_check 'mutex*try*' '^mutex.*try.*' + # Advanced full-glob matching feature is recently supported. # Skip the tests if we are sure the kernel does not support it. if grep -q 'accepts: .* glob-matching-pattern' README ; then