From owner-freebsd-xen@FreeBSD.ORG Wed Jan 12 20:34:13 2011 Return-Path: Delivered-To: freebsd-xen@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2EF9D1065670 for ; Wed, 12 Jan 2011 20:34:13 +0000 (UTC) (envelope-from got.andras@deployis.eu) Received: from mail.deployis.eu (mail.deployis.eu [217.20.135.253]) by mx1.freebsd.org (Postfix) with ESMTP id BF3768FC20 for ; Wed, 12 Jan 2011 20:34:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=deployis.eu; s=default; h=Subject:To:From:Date; bh=gnlgSAmSF9kxwjF2wfvfiASu9CI4fN5fQyo2yPwx2ZY=; b=cz88Iv1Tfe62vX1pXeZmwPMVafN3Oy6cTEZDMoHGwxKPpasdd1zgHZAhykq9+wcjbGGvsck1Wv1CEGtmo3MRKgSgXWwGx6VXeWUeWkmhf7CGDyTqRYZl6vuuS02X4HCh; Received: from 54033545.catv.pool.telekom.hu ([84.3.53.69]:47086 helo=[192.168.0.102]) by mail.deployis.eu with esmtpsa (Exim 4.71 #1 (Debian)) id 1Pd7OV-0004Z5-3E from ; Wed, 12 Jan 2011 21:34:11 +0100 Message-ID: <4D2E1042.5090302@deployis.eu> Date: Wed, 12 Jan 2011 21:34:10 +0100 From: =?ISO-8859-1?Q?G=F3t_Andr=E1s?= User-Agent: Thunderbird 2.0.0.24 (X11/20101027) MIME-Version: 1.0 To: Tobiasz Tworek References: <201101121601.58282.snasonov@bcc.ru> <4D2DADC7.8080404@deployis.eu> <4D2DE6E6.2090202@freebsd.org> <4D2E0FAB.4010900@gmail.com> In-Reply-To: <4D2E0FAB.4010900@gmail.com> Content-Type: multipart/mixed; boundary="------------040606080308060105070506" X-DKIM-Status: None (from 84.3.53.69) X-Mail-Status-postahivatal: trustedmail (from 84.3.53.69) Cc: freebsd-xen@freebsd.org Subject: Re: does anyone have Xen running on an AMD system? X-BeenThere: freebsd-xen@freebsd.org X-Mailman-Version: 2.1.5 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: Wed, 12 Jan 2011 20:34:13 -0000 This is a multi-part message in MIME format. --------------040606080308060105070506 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit I've attached Colin's patch. It may work on current also. Tobiasz Tworek wrote: > I had tested latest curent version on my AMD Athlon II X4 Xen Server 6.5 > and i have got panic. My output: > > WARNING: loader(8) metadata is missing! > GDB: no debug ports present > KDB: debugger backends: ddb > KDB: current backend: ddb > Copyright (c) 1992-2010 The FreeBSD Project. > Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 > The Regents of the University of California. All rights reserved. > FreeBSD is a registered trademark of The FreeBSD Foundation. > FreeBSD 9.0-CURRENT #0: Wed Jan 12 20:14:15 CET 2011 > root@freebsdcurent:/usr/src/sys/i386/compile/XEN i386 > WARNING: WITNESS option enabled, expect reduced performance. > Xen reported: 3013.708 MHz processor. > Timecounter "ixen" frequency 1000000000 Hz quality 0 > CPU: AMD Athlon(tm) II X4 640 Processor (3013.71-MHz 686-class CPU) > Origin = "AuthenticAMD" Id = 0x100f53 Family = 10 Model = 5 > Stepping = 3 > > Features=0x1783fbff > > Features2=0x802009 > AMD > Features=0xee500800 > AMD > Features2=0x37ff > > TSC: P-state invariant > Data TLB: 48 entries, fully associative > Instruction TLB: 32 entries, fully associative > L1 data cache: 64 kbytes, 64 bytes/line, 1 lines/tag, 2-way associative > L1 instruction cache: 64 kbytes, 64 bytes/line, 1 lines/tag, 2-way > associative > L2 internal cache: 512 kbytes, 64 bytes/line, 1 lines/tag, 8-way > associative > real memory = 536870912 (512 MB) > Physical memory chunk(s): > 0x000000000077d000 - 0x000000001f638fff, 518766592 bytes (126652 pages) > avail memory = 515821568 (491 MB) > APIC: Using the MPTable enumerator. > SMP: Added CPU 0 (BSP) > ULE: setup cpu 0 > [XEN] IPI cpu=0 irq=128 vector=RESCHEDULE_VECTOR (0) > [XEN] IPI cpu=0 irq=129 vector=CALL_FUNCTION_VECTOR (1) > Event-channel device installed. > nfslock: pseudo-device > mem: > Pentium Pro MTRR support enabled > io: > null: > random: > [XEN] xen_rtc_probe: probing Hypervisor RTC clock > rtc0: on motherboard > [XEN] xen_rtc_attach: attaching Hypervisor RTC clock > rtc0: registered as a time-of-day clock (resolution 1000000us, > adjustment 0.500000000s) > Grant table initialized > xenbus0: on motherboard > xc0: on motherboard > Device configuration finished. > procfs registered > Timecounters tick every 10.000 msec > kernel trap 9 with interrupts disabled > > > Fatal trap 9: general protection fault while in kernel mode > cpuid = 0; apic id = 00 > instruction pointer= 0x21:0xc032b311 > stack pointer = 0x29:0xlo0: bpf attached > c21fec8c > frame pointer = 0x29:0xc21fec94 > code segment= base 0x0, limit 0xfffff, type [XEN] hypervisor wallclock > nudged; nudging TOD. > 0x1b > = DPL 1, pres 1, def32 1, gran 1 > processor eflags= resume, IOPL = 0 > current process= 11 (idle: cpu0) > [ thread pid 11 tid 100003 ] > Stopped at spinlock_exit+0xa1: hlt > > > > Regards, > Tobiasz Tworek > > >> On 01/12/11 05:33, Gót András wrote: >>> kernel trap 9 with interrupts disabled >>> >>> Fatal trap 9: general protection fault while in kernel mode >>> cpuid = 0; apic id = 00 >>> instruction pointer = 0x21:0xc0321241 >>> stack pointer = 0x29:0xc21ffc8c >>> frame pointer = 0x29:0xc21ffc94 >>> code segment = base 0x0, limit 0xfffff, type 0x1b >>> = DPL 1, pres 1, def32 1, gran 1 >>> processor eflags = resume, IOPL = 0 >>> current process = 11 (idle: cpu0) >>> [thread pid 11 tid 100003 ] >>> Stopped at spinlock_exit+0xe1: hlt >> Yep, this is what I was looking for. Can you try the attached patch >> (under >> the same conditions to avoid the pmap_init panic) and let me know if this >> problem goes away? >> >> >> >> _______________________________________________ >> freebsd-xen@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-xen >> To unsubscribe, send any mail to "freebsd-xen-unsubscribe@freebsd.org" --------------040606080308060105070506 Content-Type: text/x-patch; name="amdc1e_privileged.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="amdc1e_privileged.patch" Index: i386/i386/machdep.c =================================================================== --- i386/i386/machdep.c (revision 217272) +++ i386/i386/machdep.c (working copy) @@ -1228,6 +1228,7 @@ static int cpu_ident_amdc1e = 0; +#if !defined(XEN) || defined(XEN_PRIVILEGED) static int cpu_probe_amdc1e(void) { @@ -1254,6 +1255,7 @@ #endif return (0); } +#endif /* * C1E renders the local APIC timer dead, so we disable it by @@ -2690,8 +2692,10 @@ thread0.td_pcb->pcb_fsd = PCPU_GET(fsgs_gdt)[0]; thread0.td_pcb->pcb_gsd = PCPU_GET(fsgs_gdt)[1]; +#if defined(XEN_PRIVILEGED) if (cpu_probe_amdc1e()) cpu_idle_fn = cpu_idle_amdc1e; +#endif } #else --------------040606080308060105070506--