From owner-freebsd-xen@freebsd.org Mon Feb 22 15:47:32 2016 Return-Path: Delivered-To: freebsd-xen@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CADB7AB0E22 for ; Mon, 22 Feb 2016 15:47:32 +0000 (UTC) (envelope-from gustau.perez@gmail.com) Received: from mail-wm0-x231.google.com (mail-wm0-x231.google.com [IPv6:2a00:1450:400c:c09::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5E79C1CDA for ; Mon, 22 Feb 2016 15:47:32 +0000 (UTC) (envelope-from gustau.perez@gmail.com) Received: by mail-wm0-x231.google.com with SMTP id g62so162743325wme.0 for ; Mon, 22 Feb 2016 07:47:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:subject:to:references:message-id:date:user-agent:mime-version :in-reply-to:content-type:content-transfer-encoding; bh=PESgOGGtAU5rrF2P7CHoGWff5j1CleCRnBYhoCWOXUM=; b=YdpCy6GrRlZGTshYNYOrW8Ud5G5gprbDVIv1UOWK8intaON2cF3qyQfgCqYIi7Vhco dkg1r5gJ+L3V9KZofqR0najKltYlbbPfNGwL8P6utoCzwp8M8OQSr2tMXbQ0sg5vgJHo NR+jKIGLYnhmr9gvr9bZzgqpa8NG6QXQSdaeGP2FwWdywugZLcAcnSzNmvF227Nanp+m bENtnCawdnYy1s3JqdRCHNAVsv2Do+ZAjIzyglcoXC1djjkBjLG5YdTeIAF6wq+moGXs ZC5ajpA+VdlvHGbH4Kl1hLZYO17EgkeakQ3eMNeaMh7m6CdnPE7B8E+8kwpYkNilx1OL qgZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:subject:to:references:message-id:date :user-agent:mime-version:in-reply-to:content-type :content-transfer-encoding; bh=PESgOGGtAU5rrF2P7CHoGWff5j1CleCRnBYhoCWOXUM=; b=b3V1hf+6/yO7f0gsafImXsUq/DICgP9G+deO/gMaOxHbSkXO70dsvUQ6UIkscnNlOI orXlQ5PTAjxQ77Bx9bAHDHRJjISdWKg0BY+HIOaYS3EZt8+xdDHnNaDDI//lP6INm1kS OYmzDZv46HuTXJoyjG1qp0xycYGpaZrRMxZs9nbFeXR2H8rynOSMWTjhKWLIXc1ciyUi O1T0biXlnx+YU7Wus3L2Jv6vJZoeiLTuckRu7a0ph4RaEgEm9n35PAJAe4p6pj/VZYhE Xk4GrNq5MOJ3JVqwseRa3CwC25n0fs14LFlsp9UH9MGtY3LEIRZ7EKQk/Lb8ujQr7X8n ReIg== X-Gm-Message-State: AG10YOQl1jSrIHitmGRth2rZDAm7HWPY9FFFkjPqzRAu/w45CAO6k3AmcRPKIt11y8/B+g== X-Received: by 10.28.156.73 with SMTP id f70mr14291846wme.52.1456156050439; Mon, 22 Feb 2016 07:47:30 -0800 (PST) Received: from [192.168.1.110] (156.Red-83-60-212.dynamicIP.rima-tde.net. [83.60.212.156]) by smtp.googlemail.com with ESMTPSA id m63sm21727076wmc.3.2016.02.22.07.47.29 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 22 Feb 2016 07:47:29 -0800 (PST) From: =?UTF-8?Q?Gustau_P=c3=a9rez?= Subject: Re: Porting the block-iscsi hotplug script To: =?UTF-8?Q?Roger_Pau_Monn=c3=a9?= , FreeBSD XEN References: <553DEB97.5000300@entel.upc.edu> <5540A053.4080409@entel.upc.edu> <5540F3FC.80606@citrix.com> <5541FC8A.8080009@citrix.com> <5542365D.10403@entel.upc.edu> <55423ECD.6000404@citrix.com> <5556F21D.2050005@entel.upc.edu> <555EEFBA.5080902@citrix.com> <555EF542.3090002@citrix.com> <555F9B3F.1000600@entel.upc.edu> <55602512.1090702@citrix.com> <56C6FA2F.8040900@gmail.com> <56CAC8CB.8030107@gmail.com> <56CADEDA.4050007@citrix.com> <56CB0057.1060509@gmail.com> <56CB041E.1020009@citrix.com> Message-ID: <56CB2D90.5080809@gmail.com> Date: Mon, 22 Feb 2016 16:47:28 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <56CB041E.1020009@citrix.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-xen@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Discussion of the freebsd port to xen - implementation and usage List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Feb 2016 15:47:32 -0000 El 22/02/16 a les 13:50, Roger Pau Monné ha escrit: > > I was able to get a dump of the output via the serial console [1]. If > I force the detection of the iommu with [2] the system is able to boot > the domU kernel and then it panics [3], it would appear it panics when > I guess you mean Dom0 here instead of DomU, because the log you provided > shows that Dom0 is not even able to finish the boot process. Sure, my mistake. It was certaintly Dom0 domain (the one started by the xen kernel). >> detecting atapci0. Here I'm lost. > Right, the interesting bit is: > > Fatal trap 9: general protection fault while in kernel mode > cpuid = 0; apic id = 00 > instruction pointer = 0x20:0xffffffff804169a1 > stack pointer = 0x28:0xfffffe0120435a30 > frame pointer = 0x28:0xfffffe0120435a90 > code segment = base 0x0, limit 0xfffff, type 0x1b > = DPL 0, pres 1, long 1, def32 0, gran 1 > processor eflags = interrupt enabled, IOPL = 0 > current process = 12 (irq23: atapci0) > trap number = 9 > panic: general protection fault > cpuid = 0 > Uptime: 1s > > Is there any chance you can use a kernel with debug options enabled > (ddb)? This way we should be able to get a back trace of the call chain. Sorry I was unable to get that info earlier, I'm doing this remotely (I have another machine connected bia serial port). BTW, here is the bt [1] > Also, can you provide the output of running: > > # addr2line -e /path/to/kernel/debug/sym 0xffffffff804169a1 > > The kernel symbols are usually stored at > /usr/lib/debug/boot/kernel/kernel.debug in modern FreeBSD versions. The memory position seems to point to /usr/src/sys/dev/ata/ata-all.c:351. This is when locking the ata_channel->state_mtx mutex. If I'm not mistaken (I have no time right now), that would mean the reference to that mutex does not exist? Why would that happen, because of the xen kernel freeing it? Greets, Gustau [1] http://pastebin.com/Xmr8ArCD