From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760399AbZFZMwV (ORCPT ); Fri, 26 Jun 2009 08:52:21 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1758071AbZFZMwQ (ORCPT ); Fri, 26 Jun 2009 08:52:16 -0400 Received: from mx2.redhat.com ([66.187.237.31]:36997 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756429AbZFZMwP (ORCPT ); Fri, 26 Jun 2009 08:52:15 -0400 Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20090625014520.449.98923.stgit@dev.haskins.net> References: <20090625014520.449.98923.stgit@dev.haskins.net> To: Gregory Haskins Cc: dhowells@redhat.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3] slow-work: add (module*)work->owner to fix races with module clients Date: Fri, 26 Jun 2009 13:52:16 +0100 Message-ID: <17232.1246020736@redhat.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Gregory Haskins wrote: > The slow_work facility was designed to use reference counting instead of > barriers for synchronization. The reference counting mechanism is > implemented as a vtable op (->get_ref, ->put_ref) callback. This is > problematic for module use of the slow_work facility because it is > impossible to synchronize against the .text installed in the callbacks: > There is no way to ensure that the slow-work threads have completely > exited the .text in question and rmmod may yank it out from under the > slow_work thread. This seems reasonable. I'll get round to testing it if I can find the OOM bug that's nobbling by test machine. David