From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Fri, 17 Oct 2008 13:17:17 +0100 (BST) From: Hugh Dickins Subject: Re: no way to swapoff a deleted swap file? In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-linux-mm@kvack.org Return-Path: To: Bodo Eggert <7eggert@gmx.de> Cc: David Newall , Peter Zijlstra , Peter Cordes , linux-kernel@vger.kernel.org, Christoph Hellwig , linux-mm List-ID: On Fri, 17 Oct 2008, Bodo Eggert wrote: > > Somebody might want their swapfiles to have zero links, > _and_ the possibility of doing swapoff. You're right, they might, and it's not an unreasonable wish. But we've not supported it in the past, and I still don't think it's worth adding special kernel support for it now. > If you can do it by keeping some fds open to let > /proc/pid/fd point to the files, I think it's OK. I've a very strong aversion to adding strange code to abuse the /proc//fd space of some random kernel thread - a "kswapd" because its name contains the substring "swap"? Hugh -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org