Date: Tue, 6 Jul 1999 11:24:32 -0600 (MDT) From: "Justin T. Gibbs" <gibbs@narnia.plutotech.com> To: Nick Hibma <hibma@skylink.it> Cc: scsi@FreeBSD.org Subject: Re: CAM panic in camq_fini Message-ID: <199907061724.LAA68469@narnia.plutotech.com> In-Reply-To: <Pine.BSF.3.96.990706004946.13864A-100000@heidi.plazza.it>
next in thread | previous in thread | raw e-mail | index | archive | help
Redirected to the SCSI list
> When, after attaching to the CAM later with
>
> cam_simq_alloc(1)
> cam_sim_alloc(action, poll, "umass", sc, unit, 1, 0, devq)
> xpt_bus_register(sc->sim, 0)
> xpt_create_path(&sc->path, NULL, cam_sim_path(sc->sim),
> CAM_TARGET_WILDCARD, CAM_LUN_WILDCARD)
>
> doing an immediate detach from it again, like so:
>
> xpt_async(AC_LOST_DEVICE, sc->path, NULL)
> xpt_free_path(sc->path)
> xpt_bus_deregister(cam_sim_path(sc->sim))
> cam_sim_free(sc->sim, /*free_devq*/TRUE)
Here's a fix for one of the detach bugs. There really is no
guarantee that the detach of SIMs will work right now and since
the new-bus stuff for detach hasn't settled, I don't know how
much effort towards this is worth while right now...
--
Justin
==== //depot/FreeBSD-current/src/sys/cam/cam_queue.c#5 - /usr/src/sys/cam/cam_queue.c ====
*** /tmp/tmp.415.0 Tue Jul 6 11:32:44 1999
--- /usr/src/sys/cam/cam_queue.c Tue Jul 6 11:32:30 1999
***************
*** 242,249 ****
void
cam_devq_free(struct cam_devq *devq)
{
! camq_free(&devq->alloc_queue);
! camq_free(&devq->send_queue);
free(devq, M_DEVBUF);
}
--- 242,249 ----
void
cam_devq_free(struct cam_devq *devq)
{
! camq_fini(&devq->alloc_queue);
! camq_fini(&devq->send_queue);
free(devq, M_DEVBUF);
}
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-scsi" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199907061724.LAA68469>
