From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19310 invoked by alias); 27 Sep 2011 22:03:30 -0000 Received: (qmail 19297 invoked by uid 22791); 27 Sep 2011 22:03:29 -0000 X-SWARE-Spam-Status: No, hits=-6.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 27 Sep 2011 22:03:11 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p8RM3BG5011367 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 27 Sep 2011 18:03:11 -0400 Received: from [10.3.113.76] (ovpn-113-76.phx2.redhat.com [10.3.113.76]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p8RM3Bit027660; Tue, 27 Sep 2011 18:03:11 -0400 Message-ID: <4E82481E.8060502@redhat.com> Date: Tue, 27 Sep 2011 22:03:00 -0000 From: Josh Stone User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:6.0.2) Gecko/20110906 Thunderbird/6.0.2 MIME-Version: 1.0 To: Mark Wielaard CC: systemtap@sourceware.org, dsmith@redhat.com Subject: Re: Fixed PR13146 by not allowing memory allocations to sleep (Was: [SCM] systemtap: system-wide probe/trace tool branch, master, updated. release-1.6-151-g8e794e9) References: <20110901143940.13672.qmail@sourceware.org> <1317135124.3361.22.camel@springer.wildebeest.org> In-Reply-To: <1317135124.3361.22.camel@springer.wildebeest.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org X-SW-Source: 2011-q3/txt/msg00406.txt.bz2 On 09/27/2011 07:52 AM, Mark Wielaard wrote: > Hi David, > > On Thu, 2011-09-01 at 14:39 +0000, dsmith@sourceware.org wrote: >> commit 8e794e9dfeea5a48b84442b92dea6c17b9ef75d1 >> Author: David Smith >> Date: Thu Sep 1 09:39:15 2011 -0500 >> >> Fixed PR13146 by not allowing memory allocations to sleep. >> >> * runtime/alloc.c: Turn off __GFP_WAIT when allocating memory. >> * runtime/transport/ring_buffer.c (__stp_alloc_ring_buffer): Ditto. >> * runtime/counter.c (_stp_counter_init): Handles memory allocation failure >> better. >> * runtime/task_finder.c (__stp_call_mmap_callbacks_with_addr): Better >> cleanup if memory allocation fails. > > Sorry for the late reply. But I am suspecting this commit of causing > accasional (though not very frequent) test failures that say: > ERROR: context (size 8352) allocation failed > > I suspect that is caused because the context is one of the larger > allocations at systemtap_module_init time. And because we are no longer > allowed to GFP_WAIT it is more likely to fail now. Would it be > possible/make sense to allow GFP_WAIT for allocations made from context > like systemtap_module_init() that may sleep because they are made from > user context? I agree, those contexts which can sleep, should. Not only does this make it more likely we'll get the memory we want, but also makes us better citizens with the rest of the kernel. Josh