From: Russell King <rmk+lkml@arm.linux.org.uk>
To: Matthew Wilcox <willy@parisc-linux.org>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org, matthew@wil.cx
Subject: Re: [PATCH] Releasing resources with children
Date: Mon, 14 Mar 2005 18:11:08 +0000 [thread overview]
Message-ID: <20050314181108.A4705@flint.arm.linux.org.uk> (raw)
In-Reply-To: <20050314174916.B49754957B9@palinux.hppa>; from willy@parisc-linux.org on Mon, Mar 14, 2005 at 10:49:16AM -0700
On Mon, Mar 14, 2005 at 10:49:16AM -0700, Matthew Wilcox wrote:
> What does it mean to release a resource with children? Should the
> children become children of the released resource's parent? Should they
> be released too? Should we fail the release?
I've been running kernels with:
+ if (old->child) {
+ printk("Resource %p still has children: %s\n", old, old->name);
+ return -EINVAL;
+ }
+
here and it hasn't triggered once. I suspect the reason it hasn't is
because no one does release a resource with children, but I suspect
that's just by mere luck than design.
The only thing I'd question is whether we really need to BUG_ON() here.
ISTR Linus' policy for BUG()/BUG_ON() was only if the condition lead
directly to a filesystem-corrupting bug.
--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: 2.6 Serial core
next prev parent reply other threads:[~2005-03-14 18:12 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-14 17:49 Matthew Wilcox
2005-03-14 18:11 ` Russell King [this message]
2005-03-14 21:49 ` Ingo Oeser
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050314181108.A4705@flint.arm.linux.org.uk \
--to=rmk+lkml@arm.linux.org.uk \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matthew@wil.cx \
--cc=willy@parisc-linux.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome