Received: by 2002:a05:7412:8d1c:b0:fa:4c10:6cad with SMTP id bj28csp691041rdb; Wed, 17 Jan 2024 14:37:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IHEY0wcW7vpjwdQ85raqba8ojSCwg0LBvUW65mo5qgQDrs46nzR+SYp6yVY7SL3OLH6Eehl X-Received: by 2002:a05:600c:1914:b0:40e:491d:ac80 with SMTP id j20-20020a05600c191400b0040e491dac80mr2753736wmq.15.1705531025965; Wed, 17 Jan 2024 14:37:05 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705531025; cv=pass; d=google.com; s=arc-20160816; b=i2zcqI3pMNlX662fAh7guGlTrtp4vEyKCE5IMRxpubzIBt58TG4m9fjqbwlaUVkav0 T+cAy70aoy3IvMm6hq0Ifm+XAKiDbnXCOKbHWi4YJ41V7aTpT7tDQH2KIplHwmV3wpC/ iLXXgxyzXIVCdoFeY5VXuHN5dwptdCechuVYjf09dtKUXJcLUggkJHvCYNT0u6uqufe6 N7/oVUxEl5tarB5jDkU27LbwS097WpAtlZxG2CyEb808jo7549tK8BXhcOisxKXY2inA EfXMDdTb978j3jWJ6pSAixIr4AnNQ6RjCxoKDDsEw7xTN7zZKozXrssDrzh/jjIofJ5T jWfQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=JD7nSd70H8VrCsbOxz33MNZjCfpuaR5tZywEFEiClNw=; fh=ExGhjNQEFJgRqHmYATVc5UXZbS7abAmaHDitrfHKOuE=; b=hy+bmgZDNMEYITaxer/0yL2KkdXQfR03fT8KgMmI/3nbb4aDH/I1pPRzrb7sLux/Ba aanHmYgQj+dliJk7AX3ZinWEnk6ZuGMJsn6AWRDC+IhxVoQO7sd4J1ketXDQkq9XuWrK PauwAvFvwmZL/z/AWn/uRi11/j3bS3bkNyr3sqPJyBkwWpSHrfYaKrxQq4UwEfA41VeZ hJEsAMT7Z/uqmYMWR3Fxpj4kNFKpoduG0Nz0qdgqT6joWqQDgxqkKcKSp4CWL6R9VsRX TtMwC89s8RUXmIa+HxqjmdR/p4dlM9s+UYzmnkSZH/QCGkwRT1XjzhwnV+xiSrIv+reh wAxw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=bkkyDs7P; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-bluetooth+bounces-1173-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-1173-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id g2-20020a056402428200b005569cab2645si6685238edc.5.2024.01.17.14.37.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Jan 2024 14:37:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-bluetooth+bounces-1173-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=bkkyDs7P; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-bluetooth+bounces-1173-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-1173-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 6FF9D1F235DC for ; Wed, 17 Jan 2024 22:36:36 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EE9C01E87E; Wed, 17 Jan 2024 22:36:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="bkkyDs7P" X-Original-To: linux-bluetooth@vger.kernel.org Received: from mail-lj1-f177.google.com (mail-lj1-f177.google.com [209.85.208.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C8F331E515 for ; Wed, 17 Jan 2024 22:36:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.177 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705530988; cv=none; b=JJL7fiYvt3q2oOFshsC9NrgjdbjUfZLTawoQGy9q1Pe1aUdoQGYrOjNvqPS2bIONXaYJWKUkdpnuP0kmk0YDyKTKYUlct3NVbzENZH8iU2RR09JRZOfD/9rt0Kxj5Ux6+IT4+zx1j8G7dgn9wsyKuziavJdIYxAe/vCdiSINeiw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705530988; c=relaxed/simple; bh=CH0y8MAAhRY687UfeoUG/V6ShK8dqvQ8T0G1nzAYAwM=; h=Received:DKIM-Signature:X-Google-DKIM-Signature: X-Gm-Message-State:X-Google-Smtp-Source:X-Received:MIME-Version: References:In-Reply-To:From:Date:Message-ID:Subject:To:Cc: Content-Type:Content-Transfer-Encoding; b=hYaA+kw4NiXUpMY813sw7sh5iX4k0fntCSDnJAMiEXZ6GnfjCbJj+IgM9+rL9MbCQUH6unXy/iWTDstcIfhZNll1z9z01A/6TPnxY4edq6Q7bLPc/D/vS/LBNpD7KLmPjboLRuUR9Fgt42YYJvwXxGvf9kePSbcSCUqV7OS0wVc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=bkkyDs7P; arc=none smtp.client-ip=209.85.208.177 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lj1-f177.google.com with SMTP id 38308e7fff4ca-2cdeb80fdfdso17929891fa.2 for ; Wed, 17 Jan 2024 14:36:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1705530984; x=1706135784; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=JD7nSd70H8VrCsbOxz33MNZjCfpuaR5tZywEFEiClNw=; b=bkkyDs7Pwk3zNJV2DlBovltPcYpM5/lgVr/G8g/12eVmu3RUnsiwX7mlRaj6wPXw2y V3ztBsNoS1cnPm+tAKL7qxqm6c7g/mnQAsCncCR7IGS3/Y6i7+MspJfkALMeo9wo9ytU hzxWwyY2cb+fe/sluyJmly1g6t8ZYK5mwB4r2jI9+OSkVD9afQLVlwJJydQtKqTohssK ViJcMJkZkSVTKQk+aiVi88cX28kZkeY8DIcRtFImn3+HYhtLFrwLM9SOGnDXdQGYz3Em 1R/QZvyPyOHiIvYpOSV46kVPyPDwWpy0EU6xxCsNmxFEWabMsjkOUVBNMzJmmoApNv8G XYVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705530984; x=1706135784; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=JD7nSd70H8VrCsbOxz33MNZjCfpuaR5tZywEFEiClNw=; b=eLuRrj8rH1XzBVRhavhZsfncgMGWCA+FNvffC6fyHpXvFz7NL7nySq60sfSLeyq7+C VoI/8YZjVInNIrBf7s90hitiWwEueiR43h1HOMU9HFnatpIZAakZO64XN43GCZMAWCu5 s/jcXcyj1QvDn6fU4lAN3crMvzRcdapSZYmavrDEEu4s1JNfA6qqhz/jFttbv5UyQfzR MjC+op8utAm7ew9hdcFPvB2joOf/PuHM8zEisKE4I3JUyQptalbwLxhLzOGO06Tb/o6s aiQxoNIDQXrM2Ht8aJVjO94yGNiX76tiLBLPb98TBrb2pdWvfUOkKgARwCNf4VkEFxBx X9UA== X-Gm-Message-State: AOJu0YxuWbujTpn3A9/M3qhWXD9HMXB2aahTtWnB7WXeI4ve3K2Mp28M yHjMXK3Jhl87xR8M4HzG9yHVzwTG9kmEw9MjRJyWOy2POvI= X-Received: by 2002:a2e:b166:0:b0:2cc:6666:168d with SMTP id a6-20020a2eb166000000b002cc6666168dmr2573312ljm.69.1705530983745; Wed, 17 Jan 2024 14:36:23 -0800 (PST) Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240117222317.1792594-1-luiz.dentz@gmail.com> <20240117222317.1792594-2-luiz.dentz@gmail.com> In-Reply-To: <20240117222317.1792594-2-luiz.dentz@gmail.com> From: Luiz Augusto von Dentz Date: Wed, 17 Jan 2024 17:36:10 -0500 Message-ID: Subject: Re: [PATCH BlueZ v1 2/2] transport: Print owner information when it exit or release To: linux-bluetooth@vger.kernel.org Cc: Pauli Virtanen Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Pauli, On Wed, Jan 17, 2024 at 5:23=E2=80=AFPM Luiz Augusto von Dentz wrote: > > From: Luiz Augusto von Dentz > > This prints the owner name when it exits/quits/crash or releases a > transport. > --- > - Looks like there is a bug/race on codec switch it appears the likes of > pipewire attempts to call Release in the process which stops the > acquire/resume: > > bluetoothd[1774429]: profiles/audio/transport.c:transport_set_state() S= tate > changed /org/bluez/hci0/dev_94_DB_56_F7_F2_88/sep1/fd8: TRANSPORT_G > bluetoothd[1774429]: profiles/audio/transport.c:media_request_create() > Request created: method=3DAcquire id=3D50 > bluetoothd[1774429]: profiles/audio/transport.c:media_owner_add() Owner > :1.133105 Request Acquire > bluetoothd[1774429]: profiles/audio/transport.c:media_transport_set_own= er() > Transport /org/bluez/hci0/dev_94_DB_56_F7_F2_88/sep1/fd8 Owner :1.5 > bluetoothd[1774429]: profiles/audio/transport.c:release() Owner :1.1331= 05 > bluetoothd[1774429]: profiles/audio/transport.c:media_owner_remove() Ow= ner > :1.133105 Request Acquire I wonder if we have a regression on BlueZ or PW for A2DP, since I recall this used to work just fine while switching codecs back and forth, but today it didn't work at all for me and I had to reconnect a couple of times to get it working: >pipewire --version pipewire Compiled with libpipewire 1.0.0 Linked with libpipewire 1.0.0 pw.node: (bluez_output.94_DB_56_F7_F2_88.1-70) running -> error (Received error event) > profiles/audio/transport.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/profiles/audio/transport.c b/profiles/audio/transport.c > index a4696154aba5..5395985b990f 100644 > --- a/profiles/audio/transport.c > +++ b/profiles/audio/transport.c > @@ -531,6 +531,8 @@ static void media_owner_exit(DBusConnection *connecti= on, void *user_data) > { > struct media_owner *owner =3D user_data; > > + DBG("Owner %s", owner->name); > + > owner->watch =3D 0; > > media_owner_remove(owner); > @@ -742,6 +744,8 @@ static DBusMessage *release(DBusConnection *conn, DBu= sMessage *msg, > if (owner =3D=3D NULL || g_strcmp0(owner->name, sender) !=3D 0) > return btd_error_not_authorized(msg); > > + DBG("Owner %s", owner->name); > + > if (owner->pending) { > const char *member; > > -- > 2.43.0 It seems you PW calls Release after Acquire, not sure if it didn't like our response to Acquire or something. --=20 Luiz Augusto von Dentz