linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paul Jackson <pj@sgi.com>
To: linux-hotplug@vger.kernel.org
Subject: How to notify app of changed cpu/mem/io node configuration?
Date: Tue, 29 Jun 2004 00:38:08 +0000	[thread overview]
Message-ID: <20040628173808.04718b83.pj@sgi.com> (raw)

How is it that applications will be notified of changes in a systems
configuration, such as cpu, memory or i/o nodes coming online and going
offline?

I have not followed the hotplug email lists (neither this one, nor the
memory or cpu or node hotplug lists) closely enough to know if this is
well understood, or not.  My apologies if I am covering old ground.

The cpuset work that Simon Derr (Bull) and I are doing, to support
constrained placement of sets of tasks on possibly exclusive sets of
CPUs and Memory Nodes, will eventually require some means to notify
tasks if the CPU/Memory nodes allowed to them by their cpuset have
changed, so that they can rebind to the appropriate new CPU or Memory
nodes.  I intend to post a patch of this cpuset work to lkml, within the
next day, for review and feedback. For now, no migration is supported,
and notification of CPU or Memory placement changes not useful.  But,
later on, I believe it will need to be added.  In other words, if there
was an agreed mechanism for notifying tasks of nodes going on and off
line, I would hope to use the same mechanism for notifying them that the
nodes _allowed_ to them in their current cpuset had changed.  In either
case, the task had best move.

I can imagine using for notification a new signal, that could be sent by
an administrator or system service (batch manager, perhaps) to tasks if
their allowed CPUs or Memory Nodes or other such had changed.

Then, for example, shared library code could catch the signal, and
optionally reissue sched_setaffinity(), mbind() or set_mempolicy() calls
with changed values, reflecting the new resources available to that
task.  If a task refused to take the hint and move, it could be
administratively shot.

However this is just my brainstorming, and may well not be a good way to
handle this.

By the way - on which of the Hotplug, Hotplug Memory, Hotplug CPU and/or
Hotplug Node email lists on SourceForge is it appropriate to ask this
questions?  I'm guessing the plain Hotplug list, figuring it covers
overall issues not specific to CPU, Memory or Nodes.

-- 
                          I won't rest till it's the best ...
                          Programmer, Linux Scalability
                          Paul Jackson <pj@sgi.com> 1.650.933.1373


-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
Linux-hotplug-devel mailing list  http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

             reply	other threads:[~2004-06-29  0:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-29  0:38 Paul Jackson [this message]
2004-06-29  6:24 ` How to notify app of changed cpu/mem/io node configuration? Greg KH
2004-06-29  8:37 ` Paul Jackson
2004-06-29 22:41 ` Dave Hansen
2004-06-29 23:15 ` Paul Jackson
2004-06-29 23:39 ` Dave Hansen
2004-06-29 23:53 ` Rusty Russell
2004-06-30  1:22 ` Paul Jackson
2004-06-30  1:38 ` Dave Hansen
2004-06-30  1:40 ` Paul Jackson
2004-06-30  2:16 ` Paul Jackson
2004-06-30 11:57 ` jlm_devel
2004-06-30 12:26 ` Paul Jackson
2004-06-30 13:08 ` Paul Jackson
2004-06-30 17:37 ` jlm_devel

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=20040628173808.04718b83.pj@sgi.com \
    --to=pj@sgi.com \
    --cc=linux-hotplug@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).