Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 3 May 2005 11:47:32 -0400
From:      Andrew Heybey <ath@niksun.com>
To:        freebsd-stable@freebsd.org
Cc:        sos@freebsd.org
Subject:   ATA mkIII suspend problem
Message-ID:  <20050503114732.65bce180@stiegl.mj.niksun.com>

next in thread | raw e-mail | index | archive | help
I just tried RELENG_5 as of last week and the latest (April 13) ATA
mkIII patches from http://people.freebsd.org/~sos/ATA/ on my laptop. 
Unfortunately, it breaks suspend-to-RAM (S3).

History:

I first tried RELENG_5 on the laptop (a Toshiba Tecra M2V) in January
and suspend did not work (the laptop hung after reinitializing the ATA
controller). Then I tried the first release of ATA mkIII. That first
version of the new ATA code made suspend work, and I was happy.

Last week, I tried upgrading to the latest RELENG_5 and the newest ATA
mkIII code, and now after suspending the kernel panics when reiniting
the ATA device(s) in ata-all.c:ata_reinit(), about line 217:

    /* reinit the children and delete any that fails */
    if (!device_get_children(dev, &children, &nchildren)) {
	mtx_lock(&Giant);       /* newbus suckage it needs Giant */
	for (i = 0; i < nchildren; i++) {
	    if (children[i] && device_is_attached(children[i]))
		if (ATA_REINIT(children[i])) {
		    if (ch->running->dev == children[i]) {
			^^^^^^^^^^^^^^^^
			device_printf(ch->running->dev,
				      "FAILURE - device detached\n");
			ch->running->dev = NULL;
			ch->running = NULL;
		    }
		    device_delete_child(dev, children[i]);
		}
	}
	free(children, M_TEMP);
	mtx_unlock(&Giant);     /* newbus suckage dealt with, release Giant */
    }

The problem is that ch->running is NULL at this point.

Any suggestions on how to further debug or fix?

thanks,
andrew



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050503114732.65bce180>