Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S263633AbTFPJJY (ORCPT ); Mon, 16 Jun 2003 05:09:24 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S263637AbTFPJJX (ORCPT ); Mon, 16 Jun 2003 05:09:23 -0400 Received: from dp.samba.org ([66.70.73.150]:42659 "EHLO lists.samba.org") by vger.kernel.org with ESMTP id S263633AbTFPJJX (ORCPT ); Mon, 16 Jun 2003 05:09:23 -0400 From: Rusty Russell To: Martin Diehl Cc: NeilBrown , Linus Torvalds , linux-kernel@vger.kernel.org, akpm@zip.com.au Subject: Re: [PATCH] Add module_kernel_thread for threads that live in modules. In-reply-to: Your message of "Mon, 16 Jun 2003 10:57:36 +0200." Date: Mon, 16 Jun 2003 19:22:43 +1000 Message-Id: <20030616092316.3E31B2C013@lists.samba.org> Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1247 Lines: 30 In message you write: > On Mon, 16 Jun 2003, Rusty Russell wrote: > > It would be syncronous: > > You mean your cleanup_thread would block for completion of the keventd > stuff? Ok, this would work. But then, when calling cleanup_thread, f.e. we > must not hold any semaphore which might be acquired by _any_ other work > scheduled for keventd or we might end in deadlock (like the rtnl+hotplug > issue we had seen recently). I think we're talking across each other: take a look at the existing kernel/kmod.c __call_usermodehelper to see how we wait at the moment. > > Also, this replaces complete_and_exit: the thread can just exit. This > > simplifies things for the users, too... > > Personally I do like the complete_and_exit thing as a simple and clear > finalisation point. Not as clean as "wait until the thread has exited", surely! Cheers, Rusty. -- Anyone who quotes me in their sig is an idiot. -- Rusty Russell. - 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/