Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Tue, 23 Apr 2002 14:09:29 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Tue, 23 Apr 2002 14:09:28 -0400 Received: from leibniz.math.psu.edu ([146.186.130.2]:26505 "EHLO math.psu.edu") by vger.kernel.org with ESMTP id ; Tue, 23 Apr 2002 14:09:28 -0400 Date: Tue, 23 Apr 2002 14:09:21 -0400 (EDT) From: Alexander Viro To: Keith Owens cc: Linus Torvalds , linux-kernel@vger.kernel.org Subject: Re: [RFC] race in request_module() In-Reply-To: <10796.1019533533@kao2.melbourne.sgi.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 23 Apr 2002, Keith Owens wrote: > open /dev/foo > request_module(foo) > load foo, mark !MOD_USED_ONCE. Another process: open /dev/foo MOD_INC_USE_COUNT mark MOD_USED_ONCE close /dev/foo MOD_DEC_USE_COUNT rmmod -a kills module > continue with open, MOD_INC_USE_COUNT(foo), mark MOD_USED_ONCE. module not loaded - 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/