From owner-freebsd-virtualization@FreeBSD.ORG Tue Apr 28 23:26:14 2015 Return-Path: Delivered-To: freebsd-virtualization@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8A42D2D2 for ; Tue, 28 Apr 2015 23:26:14 +0000 (UTC) Received: from mail-oi0-x22c.google.com (mail-oi0-x22c.google.com [IPv6:2607:f8b0:4003:c06::22c]) (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 5414715A0 for ; Tue, 28 Apr 2015 23:26:14 +0000 (UTC) Received: by oign205 with SMTP id n205so9047045oig.2 for ; Tue, 28 Apr 2015 16:26:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=3OaG6BhvcIp1AZ1J7KXIVQ1svbE5jWmjlOwewU6zsKk=; b=dIL/D57tiWxDIqjTXHFaayO7zLUkCezvtR4itr+GN+aYjIIfPObWn1aqq/E1LZfx8D sngn2cPkb0BCSunNTUcpgCq2qttMdLkSg2nubzjjIjEOmJgcyJ9sqG03fI7t1GTEshei W6OwP86PEaUNIeezdznUewx0OaRgdYpRdJ9VgLvgLqhlzQOnXyOdvmbPnUm+ka2iFlfb o7J158U8GkeErFbzMF6puceVS96jWeKvKWyRbAqP5Md1tLtVYDSHf5/Bv06dhC7ZQopV E9bQWE3l9DCHq10XZGkkfGJwTMZpTf3vmAzRNVKZNBGKKLMVz+/n2f/omOgzf4ToJvK7 QwAw== MIME-Version: 1.0 X-Received: by 10.60.137.201 with SMTP id qk9mr16593661oeb.15.1430263573594; Tue, 28 Apr 2015 16:26:13 -0700 (PDT) Received: by 10.60.82.168 with HTTP; Tue, 28 Apr 2015 16:26:13 -0700 (PDT) Date: Wed, 29 Apr 2015 02:26:13 +0300 Message-ID: Subject: How to tell if current running thread can be preempted? From: Stefan Andritoiu To: freebsd-virtualization@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Apr 2015 23:26:14 -0000 In Linux, in the scheduler function, it check if(!preempt_count() & PREEMPT_ACTIVE). How does the ULE scheduler tell if it can preempt the current thread? Is there an equivalent to the preempt_count() function and the PREEMPT_ACTIVE macro? Also, can this information, of a current thread running inside a FreeBSD virtual machine on bhyve, be accessed from the host? From owner-freebsd-virtualization@FreeBSD.ORG Wed Apr 29 10:13:02 2015 Return-Path: Delivered-To: freebsd-virtualization@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 74B47487 for ; Wed, 29 Apr 2015 10:13:02 +0000 (UTC) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 456EC19B3 for ; Wed, 29 Apr 2015 10:13:02 +0000 (UTC) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.14.9/8.14.9) with ESMTP id t3TAD2fL082824 for ; Wed, 29 Apr 2015 10:13:02 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-virtualization@FreeBSD.org Subject: [Bug 195238] [Hyper-v] Enhance VMBUS and improve storage performance Date: Wed, 29 Apr 2015 10:13:01 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.0-CURRENT X-Bugzilla-Keywords: feature, patch X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: commit-hook@freebsd.org X-Bugzilla-Status: New X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-emulation@FreeBSD.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Apr 2015 10:13:02 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=195238 --- Comment #5 from commit-hook@freebsd.org --- A commit references this bug: Author: whu Date: Wed Apr 29 10:12:36 UTC 2015 New revision: 282212 URL: https://svnweb.freebsd.org/changeset/base/282212 Log: Microsoft vmbus, storage and other related driver enhancements for HyperV. - Vmbus multi channel support. - Vector interrupt support. - Signal optimization. - Storvsc driver performance improvement. - Scatter and gather support for storvsc driver. - Minor bug fix for KVP driver. Thanks royger, jhb and delphij from FreeBSD community for the reviews and comments. Also thanks Hovy Xu from NetApp for the contributions to the storvsc driver. PR: 195238 Submitted by: whu Reviewed by: royger, jhb, delphij Approved by: royger MFC after: 2 weeks Relnotes: yes Sponsored by: Microsoft OSTC Changes: head/sys/amd64/amd64/apic_vector.S head/sys/amd64/conf/GENERIC head/sys/amd64/conf/NOTES head/sys/conf/options.amd64 head/sys/conf/options.i386 head/sys/dev/hyperv/include/hyperv.h head/sys/dev/hyperv/storvsc/hv_storvsc_drv_freebsd.c head/sys/dev/hyperv/storvsc/hv_vstorage.h head/sys/dev/hyperv/utilities/hv_kvp.c head/sys/dev/hyperv/utilities/hv_util.c head/sys/dev/hyperv/vmbus/hv_channel.c head/sys/dev/hyperv/vmbus/hv_channel_mgmt.c head/sys/dev/hyperv/vmbus/hv_connection.c head/sys/dev/hyperv/vmbus/hv_hv.c head/sys/dev/hyperv/vmbus/hv_ring_buffer.c head/sys/dev/hyperv/vmbus/hv_vmbus_drv_freebsd.c head/sys/dev/hyperv/vmbus/hv_vmbus_priv.h head/sys/i386/conf/GENERIC head/sys/i386/i386/apic_vector.s head/sys/x86/include/apicvar.h -- You are receiving this mail because: You are on the CC list for the bug. From owner-freebsd-virtualization@FreeBSD.ORG Thu Apr 30 09:01:37 2015 Return-Path: Delivered-To: freebsd-virtualization@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id D1AC99A6 for ; Thu, 30 Apr 2015 09:01:37 +0000 (UTC) Received: from mail-oi0-x229.google.com (mail-oi0-x229.google.com [IPv6:2607:f8b0:4003:c06::229]) (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 9DC2616DB for ; Thu, 30 Apr 2015 09:01:37 +0000 (UTC) Received: by oiko83 with SMTP id o83so42924558oik.1 for ; Thu, 30 Apr 2015 02:01:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=+qJwJUMYat8Hqis5Uy3R8hBBraHAjUrC8aMXoCG0m3o=; b=GM5e7qe6OrbcvIyoHw9MgOCgwtNCcJMEvVlQytIEFD4V5VAYO3XOVA4PiLIbbr4LCE DUVeoFLrOsykuhBiaC99ET3+gX5xylNxcCTPqtmiBAbFGe4FFdwk24M1dMIYSHh0CH7t j0vdMNV3kQxPwEbnhLn7C/umb7EplqURqI1nYkWEzQJ9cjY+EEY7xGJorzeyizeqRL03 oA2+gzlwmzTesC7m9fq1KoXXzG6vtLf/XAf9tYIpxxqYwIvt+QudxbjNxOapyRX6vZYi KIl1ej3Vd5Br3WL7kWsccDrbgl6KMb6ghiwHvMrJ38Q0IKgkyTicJ/3S4FgJ74zrg1sl qafA== MIME-Version: 1.0 X-Received: by 10.202.203.204 with SMTP id b195mr2524418oig.1.1430384496974; Thu, 30 Apr 2015 02:01:36 -0700 (PDT) Sender: kmacybsd@gmail.com Received: by 10.202.21.132 with HTTP; Thu, 30 Apr 2015 02:01:36 -0700 (PDT) Received: by 10.202.21.132 with HTTP; Thu, 30 Apr 2015 02:01:36 -0700 (PDT) In-Reply-To: References: Date: Thu, 30 Apr 2015 02:01:36 -0700 X-Google-Sender-Auth: ewI-W_sKjcdo9C_sEQ-759wYNTo Message-ID: Subject: Re: How to tell if current running thread can be preempted? From: "K. Macy" To: Stefan Andritoiu Cc: freebsd-virtualization@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Apr 2015 09:01:38 -0000 Any thread can be preempted unless it's in a critical section which is tracked by a counter in the current thread. There would be no OS agnostic way of doing what you ask in your second question. On Apr 28, 2015 4:26 PM, "Stefan Andritoiu" wrote: > In Linux, in the scheduler function, it check if(!preempt_count() & > PREEMPT_ACTIVE). > How does the ULE scheduler tell if it can preempt the current thread? > Is there an equivalent to the preempt_count() function and the > PREEMPT_ACTIVE macro? > > Also, can this information, of a current thread running inside a > FreeBSD virtual machine on bhyve, be accessed from the host? > _______________________________________________ > freebsd-virtualization@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization > To unsubscribe, send any mail to " > freebsd-virtualization-unsubscribe@freebsd.org" > From owner-freebsd-virtualization@FreeBSD.ORG Sat May 2 15:43:54 2015 Return-Path: Delivered-To: freebsd-virtualization@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 163127DF; Sat, 2 May 2015 15:43:54 +0000 (UTC) Received: from mail-lb0-x235.google.com (mail-lb0-x235.google.com [IPv6:2a00:1450:4010:c04::235]) (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 8F7E51626; Sat, 2 May 2015 15:43:53 +0000 (UTC) Received: by lbbzk7 with SMTP id zk7so80989837lbb.0; Sat, 02 May 2015 08:43:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:mime-version:content-type :content-disposition:user-agent; bh=Md6QAAGxAkztn94LhtpKQS7GHQWIEH82cLoeqEFSRVY=; b=KmLCyC3nhCJiOIFEhxOrfysJAlZXU4qhGcAKLBzN5qqn2xVIE9p7JMm1XjFbnyOHks 8uI9YIcgZe+6ZFM/dVUXYgzYRGIkGGG0N2cujAULWIZbJiXCuUL5NSIqYSejViiF5S1t llF/Ifo1C6Qmsme3SOek3Bkv6Tf1yuL3GY+Ne6SL7Qg3aKN3XeCB2dF3ofMdYH2m2Iyi Y/83pYVhlU1dnhS9ZlA9SyQlz1RbvuOMWqU1VnTkNuPBfXJwlYy+oMp8piUll0Wow3ep Z9ki6cw8nxcXSbf0jwjSbqQ0VzsuBskW3njknHKj/dixhOllmjgh7pPQB6igPRjGO48L eiXg== X-Received: by 10.112.16.167 with SMTP id h7mr12783227lbd.124.1430581430722; Sat, 02 May 2015 08:43:50 -0700 (PDT) Received: from kloomba ([31.29.236.16]) by mx.google.com with ESMTPSA id wh9sm2088033lbb.45.2015.05.02.08.43.49 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 02 May 2015 08:43:49 -0700 (PDT) Sender: Roman Bogorodskiy Date: Sat, 2 May 2015 18:43:44 +0300 From: Roman Bogorodskiy To: freebsd-virtualization@freebsd.org Cc: royger@freebsd.org, bapt@freebsd.org Subject: xen_kernel, console and X11 Message-ID: <20150502154340.GA8333@kloomba> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="vkogqOf2sHV7VnPd" Content-Disposition: inline User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 May 2015 15:43:54 -0000 --vkogqOf2sHV7VnPd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, I'm trying to get Xen running and following these instructions: https://wiki.freebsd.org/Xen and http://wiki.xen.org/wiki/FreeBSD_Dom0 I'm running two days old -CURRENT and ports. I've installed the emulators/xen port and followed instructions in pkg-message. I'm having some problems with console. I'm wondering if it's possible to have X running on the same box running xen kernel? My setup is as follows: =20 - Intel i5-4690 that supports IOMMU: $ sudo acpidump -t|grep DMAR DMAR: Length=3D128, Revision=3D1, Checksum=3D90, $ - vm.max_wired=3D-1 in /etc/sysctl.conf - xc0 "/usr/libexec/getty Pc" xterm on secure in /etc/ttys In loader.conf I have: xen_kernel=3D"/boot/xen" xen_cmdline=3D"dom0_mem=3D2048M dom0_max_vcpus=3D4 dom0pvh=3D1 com1=3D11520= 0,8n1 guest_loglvl=3Dall loglvl=3Dall console=3Dcom1" With this setup I get my system booted and at some point I can see a login screen. When I type 'startx' the system freezes. Have to hard reboot it to get working again. When I drop 'console=3Dcom1' from 'xen_cmdline', I cannot even see a login screen. All I can see is a black screen with a white cursor. It doesn't respond to any input though. On the other hand, the system doesn't seem to be frozen, at least power button triggers an ACPI event for power off. Am I hitting some bug or is that some configuration issue? Thanks, Roman Bogorodskiy --vkogqOf2sHV7VnPd Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJVRPCsAAoJEMltX/4IwiJqAi0IAKDI00ITkwZe3vTaluobBjnW Yb5cqv4Q/F9HULfMf4yjpcYVJddXZ8Nwq7s4DXou02D1t2lquRHl1NoyM97qtsbT z+quSZ0g5EJm5iSgAPg5ZuWWI6ShLAppWN1nMDS+PEPcS5Ye8LB63TC5JUCgYEIO Lde4/13jePcYSnBEP79Ubsx4y3q9nBGOnmfPe01V84W9Vtiaz5eFEgINgpsPeBzG A7maSVBLIF1lRS6RqOQ1s/oZPkUXojVnCT9JGKjqWSh93yk4vVORwrLm/JCD9L2u 2GbjVVJe2iNITn8GQVrHsBFA4ROhx1R/Q02Wnib9yEk+fAGbUs54ioh8pf0oAdY= =bcKA -----END PGP SIGNATURE----- --vkogqOf2sHV7VnPd--