From owner-p4-projects@FreeBSD.ORG Thu Jul 6 05:33:41 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2E87C16A4E1; Thu, 6 Jul 2006 05:33:41 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0896F16A4DA for ; Thu, 6 Jul 2006 05:33:41 +0000 (UTC) (envelope-from kmacy@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C5F3743D46 for ; Thu, 6 Jul 2006 05:33:40 +0000 (GMT) (envelope-from kmacy@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k665Xex0028723 for ; Thu, 6 Jul 2006 05:33:40 GMT (envelope-from kmacy@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k665Xejs028716 for perforce@freebsd.org; Thu, 6 Jul 2006 05:33:40 GMT (envelope-from kmacy@freebsd.org) Date: Thu, 6 Jul 2006 05:33:40 GMT Message-Id: <200607060533.k665Xejs028716@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to kmacy@freebsd.org using -f From: Kip Macy To: Perforce Change Reviews Cc: Subject: PERFORCE change 100691 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jul 2006 05:33:41 -0000 http://perforce.freebsd.org/chv.cgi?CH=100691 Change 100691 by kmacy@kmacy_storage:sun4v_work_stable on 2006/07/06 05:32:43 fix config add some debug info to pmap_ipi Affected files ... .. //depot/projects/kmacy_sun4v_stable/src/sys/sun4v/conf/GENERIC#5 edit .. //depot/projects/kmacy_sun4v_stable/src/sys/sun4v/sun4v/pmap.c#8 edit Differences ... ==== //depot/projects/kmacy_sun4v_stable/src/sys/sun4v/conf/GENERIC#5 (text+ko) ==== @@ -211,4 +211,4 @@ device ccd options SPIN_PROFILING -options HZ=100+options HZ=100 ==== //depot/projects/kmacy_sun4v_stable/src/sys/sun4v/sun4v/pmap.c#8 (text+ko) ==== @@ -1218,12 +1218,13 @@ pmap_ipi(pmap_t pmap, char *func, uint64_t arg1, uint64_t arg2) { - int i, cpu_count; + int i, cpu_count, retried; u_int cpus; cpumask_t cpumask, active, curactive; cpumask_t active_total, ackmask; uint16_t *cpulist; + retried = 0; if (!smp_started) return (0); @@ -1273,9 +1274,23 @@ while (ackmask != curactive) { membar(Sync); i++; - if (i > 10000000) - panic(" ackmask=0x%x active=0x%x\n", ackmask, curactive); + if (i > 10000000) { + uint64_t cpu_state; + printf("cpu with cpumask=0x%x appears to not be responding to ipis\n", + curactive & ~ackmask); + + hv_cpu_state((uint64_t)ffs64(curactive & ~ackmask), &cpu_state); + printf("cpu_state of %ld is %ld\n", ffs64(curactive & ~ackmask), cpu_state); + if (!retried) { + printf("I'm going to send off another ipi just to confirm that it isn't a memory barrier bug\n" + "and then I'm going to panic\n"); + + retried = 1; + goto retry; + } + panic(" ackmask=0x%x active=0x%x\n", ackmask, curactive); + } } active_total |= curactive;