From: Helge Deller <deller@gmx.de>
To: Grant Grundler <grundler@puffin.external.hp.com>
Cc: parisc-linux@lists.parisc-linux.org
Subject: [parisc-linux] Re: two minor c3k bugs
Date: Sun, 2 Dec 2001 23:46:27 +0100 [thread overview]
Message-ID: <20011202224752.D4B7C482C@dsl2.external.hp.com> (raw)
In-Reply-To: <200112010611.XAA11815@puffin.external.hp.com>
Hi Grant,
On Saturday 01 December 2001 07:11, Grant Grundler wrote:
> > Currently I use "kill_proc(1, SIGINT, 0);" to kill the init-process -
> > which is normally a reboot-command and gives the above messages.
>
> Ok. that makes sense.
>
> > That's AFAICS not the right solution, but nfortunately I don't know
> > how to do it correct right now.
>
> ./kernel/sys.c: printk(KERN_EMERG "Power down.\n");
>
> That chunk of code seems to do the right thing:
> case LINUX_REBOOT_CMD_POWER_OFF:
> notifier_call_chain(&reboot_notifier_list, SYS_POWER_OFF,
> NULL); printk(KERN_EMERG "Power down.\n");
> machine_power_off();
> do_exit(0);
> break;
>
> I know that msg since I regularly "powerdown" my c3k.
> Perhaps replicate that code?
Yes, that's the right code-path, but sadly calling this function
would immediately power off the computer without doing a nice
system shutdown.
I'll need to investigate how to first find the PID of the init process and
then how to tell it to shut down the system cleanly.
Helge
> cheers,
> grant
next prev parent reply other threads:[~2001-12-02 22:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200111300843.BAA03660@puffin.external.hp.com>
2001-12-01 6:11 ` [parisc-linux] Re: two minor c3k bugs Grant Grundler
2001-12-02 22:46 ` Helge Deller [this message]
[not found] <200111300743.AAA03588@puffin.external.hp.com>
2001-11-30 8:46 ` Helge Deller
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=20011202224752.D4B7C482C@dsl2.external.hp.com \
--to=deller@gmx.de \
--cc=grundler@puffin.external.hp.com \
--cc=parisc-linux@lists.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