mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Russell King <rmk+lkml@arm.linux.org.uk>
To: Andrew Morton <akpm@osdl.org>
Cc: David Woodhouse <dwmw2@infradead.org>,
	torvalds@osdl.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC][PATCH] Kernel thread signal handling.
Date: Mon, 13 Oct 2003 12:08:43 +0100	[thread overview]
Message-ID: <20031013120843.E19601@flint.arm.linux.org.uk> (raw)
In-Reply-To: <20031013040219.6ad71a57.akpm@osdl.org>; from akpm@osdl.org on Mon, Oct 13, 2003 at 04:02:19AM -0700

On Mon, Oct 13, 2003 at 04:02:19AM -0700, Andrew Morton wrote:
> Signals are for userspace and the signal developers shouldn't have to worry
> about weird in-kernel abuse and we have other simpler, more reliable
> mechanisms available in-kernel and even more such ranting you get the
> point.

Even so, how does the current signal code react to the case where
a userspace process installs (eg) a SIGINT handler immediately
before entering a region which it needs to clean up.  Meanwhile
a SIGINT is sent on some other CPU, discovers that there wasn't a
SIGINT handler when it looked, and queues a SIGKILL instead.
(this case was one which dwmw2 mentioned.)

I'm not certain if this can happen (the signal code is far to hairly
to work through the possibilities.)  However, we used to decide if
the signal was fatal to the process far later in the signal handling
(when delivering it to the user space process in the context of that
process) rather than in some other random context which may be on a
different CPU.

> Is there no way in which jffs2 can be weaned off this obnoxious habit?

jffs2 is using signal handlers as a method of communicating from user
space to kernel space.  Maybe it should create some sysfs files.
However, since there aren't any existing sysfs entities for jffs2 to
attach these files to, this wouldn't seem to be reasonable.

Maybe jffs2 needs /proc/fs/jffs2/<jffs2_instance>/foo but we all know
peoples feelings on procfs.

-- 
Russell King
 Linux kernel    2.6 ARM Linux   - http://www.arm.linux.org.uk/
 maintainer of:  2.6 PCMCIA      - http://pcmcia.arm.linux.org.uk/
                 2.6 Serial core

  reply	other threads:[~2003-10-13 11:08 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-10-13 10:31 David Woodhouse
2003-10-13 11:02 ` Andrew Morton
2003-10-13 11:08   ` Russell King [this message]
2003-10-13 11:29     ` David Woodhouse
2003-10-13 11:21   ` David Woodhouse
2003-10-13 11:40     ` Andrew Morton
2003-10-13 11:55       ` David Woodhouse
2003-10-13 12:11         ` Andrew Morton
2003-10-13 12:30           ` David Woodhouse
2003-10-13 16:36   ` Linus Torvalds

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=20031013120843.E19601@flint.arm.linux.org.uk \
    --to=rmk+lkml@arm.linux.org.uk \
    --cc=akpm@osdl.org \
    --cc=dwmw2@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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

all inboxes | Powered by JetHome®