Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932299AbbFQSji (ORCPT ); Wed, 17 Jun 2015 14:39:38 -0400 Received: from mail-pd0-f177.google.com ([209.85.192.177]:36551 "EHLO mail-pd0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753403AbbFQSjc (ORCPT ); Wed, 17 Jun 2015 14:39:32 -0400 Message-ID: <5581BEE1.5060302@plumgrid.com> Date: Wed, 17 Jun 2015 11:39:29 -0700 From: Alexei Starovoitov User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Daniel Wagner , paulmck@linux.vnet.ibm.com CC: LKML , rostedt@goodmis.org Subject: Re: call_rcu from trace_preempt References: <557F509D.2000509@plumgrid.com> <20150615230702.GB3913@linux.vnet.ibm.com> <557F7764.5060707@plumgrid.com> <20150616021458.GE3913@linux.vnet.ibm.com> <557FB7E1.6080004@plumgrid.com> <20150616122733.GG3913@linux.vnet.ibm.com> <558018DD.1080701@monom.org> <55805AC5.8020507@plumgrid.com> <55812BC1.4010604@bmw-carit.de> <5581385D.9060608@bmw-carit.de> In-Reply-To: <5581385D.9060608@bmw-carit.de> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1673 Lines: 33 On 6/17/15 2:05 AM, Daniel Wagner wrote: >> >Steven's suggestion deferring the work via irq_work results in the same >> >stack trace. (Now I get cold feets, without the nice heat from the CPU >> >busy looping...) > That one still not working. It also makes the system really really slow. > I guess I still do something completely wrong. tried your irq_work patch. It indeed makes the whole system unresponsive. Ctrl-C of hwlathist no longer works and it runs out of memory in 20 sec or so of running hwlathist on idle system (without parallel hackbench). It looks that free_pending flag is racy, so I removed it, but it didn't help. Also I've tried all sort of other things in rcu including add rcu_bpf similar to rcu_sched to make sure that recursive call into call_rcu will not be messing rcu_preempt or rcu_sched states and instead will be operating on rcu_bpf per-cpu states. In theory that should have worked flawlessly and it sort-of did. But multiple hackbench runs still managed to crash it. So far I think the temp workaround is to stick with array maps for probing such low level things like trace_preempt. Note that pre-allocation of all elements in hash map also won't help, since the problem here is some collision of call_rcu and rcu_process_callbacks. I'm pretty sure that kfree_rcu with rcu_is_watching patch is ready for this type of abuse. The rcu_process_callbacks() path - no yet. I'm still analyzing it. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/