From nobody Fri Nov 7 04:03:41 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=gmail.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1545601078761965.8707377423696; Sun, 23 Dec 2018 13:37:58 -0800 (PST) Received: from localhost ([127.0.0.1]:60086 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gbBRd-0002Nd-Er for importer@patchew.org; Sun, 23 Dec 2018 16:37:57 -0500 Received: from eggs.gnu.org ([208.118.235.92]:52368) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gbAk1-0007v7-As for qemu-devel@nongnu.org; Sun, 23 Dec 2018 15:52:54 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gbAk0-0002e9-C4 for qemu-devel@nongnu.org; Sun, 23 Dec 2018 15:52:53 -0500 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:55631) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gbAk0-0002b5-4I for qemu-devel@nongnu.org; Sun, 23 Dec 2018 15:52:52 -0500 Received: by mail-wm1-x341.google.com with SMTP id y139so9809490wmc.5 for ; Sun, 23 Dec 2018 12:52:52 -0800 (PST) Received: from nullptr.home.dirty-ice.org (2a01-036c-0113-24a3-0000-0000-0000-0005.pool6.digikabel.hu. [2a01:36c:113:24a3::5]) by smtp.gmail.com with ESMTPSA id g198sm25456920wmd.23.2018.12.23.12.52.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 23 Dec 2018 12:52:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=DhsP1IZYKezBoWf9kL+ulOkH8CQ0XIepreTWbDHpa6k=; b=JYz907P8/OBdq4p0Eu2l9yKC8yYazS+zxLMFBLbW/33cu5U3QnvtdJAqRrGYu2VM/6 1bWwQVBba/HpWI6gQ97WdSMKHarj80/yIk47c9QZWM2TiCYqTgtp3WpU9FR3y9qw2s0Y NvMlpZVQJwVXBLnVhzcBdR4ULcaN3F05DOVY2NhhvjNowid2SLtTYV63sK7ix4GNRBRm QxrGTL7wWiXhf48uCTFvtiwq21EIY4Zaq5mYgLq4vqMEDtK62Lqb31kJOjPnWFmdCZ8v WVhf4LhG+ctjzdrXL5AwjHuGmX7ueAON+jLGw2diEPJuqf1TA/hv+p8EVhji5fmoeR8l 9TQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=DhsP1IZYKezBoWf9kL+ulOkH8CQ0XIepreTWbDHpa6k=; b=kAvdyBO5uRKyZaMyKmQsJiHC+1jqHrwpqeh4JHZvz6UjaNoVxUHfoln/nnXumzUpwm e82XJIcHgjLTa9yVJiXt8e7fxe/3bVDDbsquTF4om14IoM78aVXkhTpLfrvaDJmS4cS3 dm9XGGMNa5kU+Fse+tF2ie/NmvUtFCbDXT84k5gku7+nN2YDXcs6PO7xxYsddacxImxm HVa89OCfHyogQoIipp0JolKEmUDg7lm4F/046ww4y2lfMgzfHC5SvTCh8H598cdu9SwA Fo52dKysoKitxhvk4i8aXIHp1TLtFbkBcIp+zxi9xbK2EvjrJ1eSjs3AFpI+WjEOWuka poAA== X-Gm-Message-State: AA+aEWaA30E/kScQTGOuTJk9x4dibzFjaYMXoHdH/J87LIa3YCeCUrN5 OSrLflAANnBa4sznuB45DcpAC+atOUQ= X-Google-Smtp-Source: ALg8bN5XVabu9Nix+tE/Kmv6OykYErE+3qnEY0TQXsmhteh62mcqZNMXxV/KfexjLV2Wt166KZ7+lw== X-Received: by 2002:a1c:3d44:: with SMTP id k65mr9831278wma.76.1545598370968; Sun, 23 Dec 2018 12:52:50 -0800 (PST) From: "=?UTF-8?q?K=C5=91v=C3=A1g=C3=B3=2C=20Zolt=C3=A1n?=" X-Google-Original-From: =?UTF-8?q?K=C5=91v=C3=A1g=C3=B3=2C=20Zolt=C3=A1n?= To: qemu-devel@nongnu.org Date: Sun, 23 Dec 2018 21:52:01 +0100 Message-Id: <69db519bda51135da1fe3e379586c98756be3a1c.1545598229.git.DirtY.iCE.hu@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::341 Subject: [Qemu-devel] [PATCH v2 25/52] paaudio: fix playback glitches X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gerd Hoffmann Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Pulseaudio normally assumes that when the server wants it, the client can generate the audio samples and send it right away. Unfortunately this is not the case with QEMU -- it's up to the emulated system when does it generate the samples. Buffering the samples and sending them from a background thread is just a workaround, that doesn't work too well. Instead enable pa's compatibility support and let pa worry about the details. Signed-off-by: K=C5=91v=C3=A1g=C3=B3, Zolt=C3=A1n --- audio/paaudio.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/audio/paaudio.c b/audio/paaudio.c index 6ed12851c0..9331e630d1 100644 --- a/audio/paaudio.c +++ b/audio/paaudio.c @@ -511,10 +511,8 @@ static pa_stream *qpa_simple_new ( =20 flags =3D PA_STREAM_INTERPOLATE_TIMING -#ifdef PA_STREAM_ADJUST_LATENCY - |PA_STREAM_ADJUST_LATENCY -#endif - |PA_STREAM_AUTO_TIMING_UPDATE; + |PA_STREAM_AUTO_TIMING_UPDATE + |PA_STREAM_EARLY_REQUESTS; =20 if (dev) { /* don't move the stream if the user specified a sink/source */ --=20 2.20.1