From owner-freebsd-hackers Thu Aug 15 11:17: 5 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E200737B400 for ; Thu, 15 Aug 2002 11:17:01 -0700 (PDT) Received: from beppo.feral.com (beppo.feral.com [192.67.166.79]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3FBE143E3B for ; Thu, 15 Aug 2002 11:17:01 -0700 (PDT) (envelope-from mjacob@feral.com) Received: from mailhost.feral.com (mjacob@mailhost.feral.com [192.67.166.1]) by beppo.feral.com (8.11.3/8.11.3) with ESMTP id g7FIH0Y28940 for ; Thu, 15 Aug 2002 11:17:00 -0700 (PDT) (envelope-from mjacob@feral.com) Date: Thu, 15 Aug 2002 11:17:00 -0700 (PDT) From: Matthew Jacob X-Sender: mjacob@beppo Reply-To: mjacob@feral.com To: hackers@freebsd.org Subject: question about Giant && Rebooting Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I'm getting: syncing disks... 6 done Uptime: 1d1h5m30s lock order reversal 1st 0xc0edd008 shutdown_post_sync (shutdown_post_sync) @ /usr/src/sys/kern/kern_shutdown.c:341 2nd 0xc04759e0 Giant (Giant) @ /usr/src/sys/dev/isp/isp_freebsd.c:2067 but the code in question is: CAMLOCK_2_ISPLOCK(isp); error = isp_start((XS_T *) ccb); switch (error) { case CMD_QUEUED: ccb->ccb_h.status |= CAM_SIM_QUEUED; if (ccb->ccb_h.timeout != CAM_TIME_INFINITY) { u_int64_t ticks = (u_int64_t) hz; if (ccb->ccb_h.timeout == CAM_TIME_DEFAULT) ticks = 60 * 1000 * ticks; else ticks = ccb->ccb_h.timeout * hz; ticks = ((ticks + 999) / 1000) + hz + hz; if (ticks >= 0x80000000) { isp_prt(isp, ISP_LOGERR, "timeout overflow"); ticks = 0x7fffffff; } ccb->ccb_h.timeout_ch = timeout(isp_watchdog, (caddr_t)ccb, (int)ticks); } else { callout_handle_init(&ccb->ccb_h.timeout_ch); } ISPLOCK_2_CAMLOCK(isp); <<<<<<<<<<<<<<<<<<<<<<<<<<<<<---- Where CAMLOCK_2_ISPLOCK supposedly drops Giant so it can pick up the ISP mutex and ISPLOCK_2_CAMLOCK drops the isp lock so it can reacquire Giant- this is because CAM is covered by Giant. So- why the whine? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message