From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751242AbdANEuH (ORCPT ); Fri, 13 Jan 2017 23:50:07 -0500 Received: from smtprelay0007.hostedemail.com ([216.40.44.7]:53400 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751086AbdANEuG (ORCPT ); Fri, 13 Jan 2017 23:50:06 -0500 X-Session-Marker: 726F737465647440676F6F646D69732E6F7267 X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,rostedt@goodmis.org,:::::,RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1539:1593:1594:1711:1730:1747:1777:1792:2393:2553:2559:2562:3138:3139:3140:3141:3142:3352:3622:3865:3867:3870:3871:3872:3873:3874:5007:6261:7875:8603:10004:10400:10848:10967:11026:11232:11658:11914:12663:12740:12760:12895:13069:13161:13229:13311:13357:13439:14096:14097:14181:14659:14721:21080:30012:30054:30070:30090:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:2,LUA_SUMMARY:none X-HE-Tag: edge69_3ab2754a68c34 X-Filterd-Recvd-Size: 1723 Date: Fri, 13 Jan 2017 23:50:01 -0500 From: Steven Rostedt To: Namhyung Kim Cc: LKML , Ingo Molnar Subject: Re: [RFC/PATCH] ftrace: Allow to change size of function graph filters Message-ID: <20170113235001.6f92fb28@vmware.local.home> In-Reply-To: <20170114042000.GA1735@danjae.aot.lge.com> References: <20170113042243.15259-1-namhyung@kernel.org> <20170113111618.53709bf8@gandalf.local.home> <20170114042000.GA1735@danjae.aot.lge.com> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 14 Jan 2017 13:20:00 +0900 Namhyung Kim wrote: > But I'm not sure how to synchronize hash table manipulations. It > seems synchronize_sched() is not good enough for function graph > tracer, right? So I limited changing filter size only when no tracer > is used, but is it ok to have the limitation when adding or removing > an entry to/from the table? If not, what can I do? There's already a hash that function tracing uses. Look at the code in ftrace_hash_move(). If you make it where the hash is always looked at with preemption disabled, you can use synchronize_sched() to modify the hash. The trampolines are a bit trickier, because there's no way to disable preemption or do any other synchronization when they are called. -- Steve