public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: tony.luck@intel.com
Cc: Andrew Morton <akpm@osdl.org>,
	kaneshige.kenji@jp.fujitsu.com, ambx1@neo.rr.com, greg@kroah.org,
	linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org,
	Len Brown <len.brown@intel.com>
Subject: Re: [patch] properly stop devices before poweroff
Date: Wed, 27 Jul 2005 09:40:33 +0200	[thread overview]
Message-ID: <20050727074033.GC4115@elf.ucw.cz> (raw)
In-Reply-To: <200507270014.j6R0EYMv005786@agluck-lia64.sc.intel.com>

Hi!

> > > I started on my OLS homework from Andrew ... and began looking
> > > into what is going on here.
> > > 
> > 
> > Thanks ;) I guess we'll end up with a better kernel, even though you appear
> > to be an innocent victim here.
> 
> The "Badness in iosapic_unregister_intr at arch/ia64/kernel/iosapic.c:851"
> messages are caused by a missing call to free_irq() in the mpt/fusion driver.
> I think that it should go here ... but someone with a clue should verify:
> 
> diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/mptbase.c
> --- a/drivers/message/fusion/mptbase.c
> +++ b/drivers/message/fusion/mptbase.c
> @@ -1384,6 +1384,8 @@ mpt_suspend(struct pci_dev *pdev, pm_mes
>  	/* Clear any lingering interrupt */
>  	CHIPREG_WRITE32(&ioc->chip->IntStatus, 0);
>  
> +	free_irq(ioc->pci_irq, ioc);
> +
>  	pci_disable_device(pdev);
>  	pci_set_power_state(pdev, device_state);

Looks good, but check with Len Brown. He did relevant ACPI changes.

> But even this doesn't fix the hang during shutdown :-(
> 
> The remaining problem is cause by the order of the calls in sys_reboot:
> 
>                 device_suspend(PMSG_SUSPEND);
>                 device_shutdown();
> 
> The call to device_suspend() shuts down the mpt/fusion driver.  But then
> device_shutdown() calls sd_shutdown() which prints:
> 
>   Synchronizing SCSI cache for disk sdb

Okay, looks to me like sd_shutdown should be done from
device_suspend(), not device_shutdown [because it needs scsi subsystem
to be functional]. Also for reboot we probably want PMSG_FREEZE (not
PMSG_SUSPEND), to keep it slightly faster.

								Pavel
-- 
teflon -- maybe it is a trademark, but it should not be.

  parent reply	other threads:[~2005-07-27  7:41 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-26 19:02 [patch] properly stop devices before poweroff Luck, Tony
2005-07-26 19:10 ` Andrew Morton
2005-07-27  0:14   ` tony.luck
2005-07-27  0:23     ` Andrew Morton
2005-07-27  7:40     ` Pavel Machek [this message]
2005-07-28  1:37 ` Kenji Kaneshige
2005-07-28  1:41   ` Andrew Morton
     [not found] <200506260105.j5Q15eBj021334@hera.kernel.org>
2005-08-01 15:19 ` [PATCH] " Olaf Hering
  -- strict thread matches above, loose matches on Subject: below --
2005-07-27 21:14 [patch] " Luck, Tony
2005-04-21 15:02 tvrtko.ursulin
2005-04-21 11:30 tvrtko.ursulin
2005-04-21 11:38 ` Pavel Machek
2005-04-21 11:13 Pavel Machek
2005-04-29 13:18 ` Andrew Morton
2005-04-29 13:36   ` Zwane Mwaikambo
2005-04-30  9:47     ` Andrew Morton
2005-04-30 13:40       ` Pavel Machek
2005-05-01 19:09   ` Kenji Kaneshige
2005-05-01 19:57     ` Pavel Machek
2005-05-01 22:16     ` Adam Belay
2005-05-16  7:56       ` Andrew Morton
2005-05-19 12:43         ` Kenji Kaneshige
2005-05-01 22:24 ` Adam Belay
2005-05-01 23:16   ` Pavel Machek
2005-05-02  0:01     ` Adam Belay
2005-05-02  9:55       ` Pavel Machek

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=20050727074033.GC4115@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=akpm@osdl.org \
    --cc=ambx1@neo.rr.com \
    --cc=greg@kroah.org \
    --cc=kaneshige.kenji@jp.fujitsu.com \
    --cc=len.brown@intel.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tony.luck@intel.com \
    /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