From owner-soc-status@freebsd.org Sat Jul 30 07:56:41 2016 Return-Path: Delivered-To: soc-status@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 0CDE0BA85B4 for ; Sat, 30 Jul 2016 07:56:41 +0000 (UTC) (envelope-from ionutalex.teaca@gmail.com) Received: from mail-oi0-x241.google.com (mail-oi0-x241.google.com [IPv6:2607:f8b0:4003:c06::241]) (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 BB0271E6B for ; Sat, 30 Jul 2016 07:56:40 +0000 (UTC) (envelope-from ionutalex.teaca@gmail.com) Received: by mail-oi0-x241.google.com with SMTP id w143so9626236oiw.2 for ; Sat, 30 Jul 2016 00:56:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=0MqQhU2kbHrC7xZe6zHbb4Atha6owwdD9QedptwkTlM=; b=YkC3++kWV3WEkK7VGD/V3G48gbv5vYs4TJrdBUK3nuYkzx6JX62UY0u1/ZiHeLxIRx 2oVj6fQa2YdAFm3D4MqlUcwsEY0qSg2i2EopvEDK9W2yrJ3UfagbBB6KpEY8YujMSw4K I2czhv+fJw7pL68KyGIi38ZYCFrZXzVE+wqSa3+kMremDSqW/haDdyS5D7XKFn+SYPSm b+Tm++ShM4nMhBc7gxapOnYk6BDEY/w+LRR9q6RHHLqbZdT2bnorFmvvMxpN3TBuUsSw mPFeIldhVuLEN0hMbgn3b4F+Ra+pJLpSGcy3kdQLCOvnq/f/xXRcqZO9wEhxY+ZQefna gCdw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=0MqQhU2kbHrC7xZe6zHbb4Atha6owwdD9QedptwkTlM=; b=DWs+Ow/vcVdb1hfifyuJ1B9LQNMdhdwegcY2rfJKTY145G3wGwbNQPKQFFkwu6Nk2P hXAOfRU9ddGL6di2lkgkUQ8w/NXZoH+B/uhx/onwgpPpA0QAM/a6tsrkEybdkbsa1DPj TehvvkgcM3bDfoe7lh2MV9iogqMDyqxybKWVzgQZobDq7tZF6GRKuunswY+O4EdYXBc3 DxhFCfeJHIfTPJqPqtJssFJaLX6mJOKt6YSSfl5syL8+ZAsZ/OL3/72NJUfMunm0dCJx Pca4n1iUphIG2Wc7b7FBEieD6e1VSsMJ6gFjMgTrvXVszh+tHqBJzcme3Y4OJxotcTgv dyGA== X-Gm-Message-State: AEkoouu+FjaDIXRpjl11L9OLaWfclbtvS9WmgRA+wPGv6/dLqmBtpyPUKtb4bCU9TKhXtxUwkbUsv20VqK6Urw== X-Received: by 10.202.75.215 with SMTP id y206mr24557145oia.195.1469865399395; Sat, 30 Jul 2016 00:56:39 -0700 (PDT) MIME-Version: 1.0 Received: by 10.182.18.130 with HTTP; Sat, 30 Jul 2016 00:56:38 -0700 (PDT) In-Reply-To: References: From: Alex Teaca Date: Sat, 30 Jul 2016 10:56:38 +0300 Message-ID: Subject: Re: [GSOC 2016] HD Audio Emulation For Bhyve Status To: soc-status@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: soc-status@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: Summer of Code Status Reports and Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Jul 2016 07:56:41 -0000 Hi, Meanwhile I have added some small functionalities in order to make it work with Linux and Windows virtual machines. The difficult part was rather to find the right setup to run Windows properly. Now, it works playing audio on FreeBSD, Linux (ubuntu 14.04 server) and Windows 2k8 server guests. One limitation I still have is the necessity to use hw.snd.latency=0 when play with Windows. I am working at the input features in order to capture audio. Thanks, Alex On Sun, Jun 26, 2016 at 8:49 PM, Alex Teaca wrote: > Hi, > > Short update. > > - implement the stream management operations (stream_start, stream_stop, > hda stream interrupts, hda_transfer) in the hda and hda codec > - create one thread per stream in the initialization of the codec which > runs as long as the stream is started and waits on a conditional variable > when the stream is stopped. > - implement the Audio Player used to play samples to the sound device > (/dev/dsp) (3 functions: audio_init, audio_set_params and audio_playback) > > Results: manage to play music in a bhyve virtual machine :) > > Thanks, > Alex > > > On Fri, Jun 17, 2016 at 9:52 PM, Alex Teaca > wrote: > >> Hi, >> >> I added a pin widget (Line-out) and now the Audio Output Widget is >> enabled. The codec is installed as pcm0: >> root@vm_hda:~ # cat /dev/sndstat >> Installed devices: >> pcm0: (play) default >> >> The next step is to implement the stream management operations such as >> start_stream and stop_stream. I have taken a look on the Stream management >> chapter from the HDA specification in order to get familiar with these >> operations and study the driver implementation (hdaa_audio_setup, >> hdac_stream_start, hdac_stream_stop) to see what registers are programmed >> and what commands are sent to the codec. >> >> Together with Peter and Alexander we chose the design of the interaction >> between the HDA controller, codecs and Audio player regarding the stream >> management. >> >> Thanks, >> Alex >> >> >> On Mon, Jun 6, 2016 at 10:01 PM, Alex Teaca >> wrote: >> >>> Hi, >>> >>> Here is the status with the features I have implemented so far. >>> >>> - set up the HDA controller as a PCI device in bhyve >>> - design the layout of registers and implement the read and write >>> access to the registers >>> - implement the CORB and RIRB mechanisms in order to get commands from >>> driver and respond back >>> - add the hdac_codec module and implement the interface of >>> communication between the hda controller and codec >>> - describe the hda codec parameters for each node (ROOT, FG and AUDIO >>> OUTPUT) >>> - handle the GET_PARAMETER verb >>> >>> At the moment there is only one widget: the Autio Output Widget and the >>> hda driver has disabled it because it does not find any Pin widget. >>> >>> The plan is to add the Pin output widget and to continue with the >>> streams data in order to play some samples. >>> >>> Thanks, >>> Alex >>> >>> >> >