From patchwork Fri Feb 2 14:10:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iulia Tanasescu X-Patchwork-Id: 13542927 Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04on2071.outbound.protection.outlook.com [40.107.7.71]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 204F713E214 for ; Fri, 2 Feb 2024 14:10:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.7.71 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706883052; cv=fail; b=biNestCe1MXLdvJgg9MVwws4nZaDv02faUSMbua+YyH2iCHOS2Pz0PN6rt8J8HlbwglJcFZvg82/VQV6GkR/7HNE3t5yPhHa0lNj2hSyYbmltE/dzpCgkw6w22h0pPJk/8ezyRdZeOu4xWorVWEN0Q/KHBbBrDelOuwZeDU31bg= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706883052; c=relaxed/simple; bh=A5x9o9ot6HvMA1ylNKWgwvQYCZcf6lG3imIuT1o+SH4=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=e153k5IoZwbW4DT+RQeSamDaeiCR7RzDzJLbcu3Dv7s4MOyWDe5Z0tGtsgPew0/H/Mu28DSxYF3nEsOl8ok9U6KtVIlQ9kDnkF6Ii21CIDpmk+SY0lA5yh1qvF+/un15N2FZmNEcGxzhXsC+QWB7jEc6/SS/jmWXk/3HdZteLEA= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=OZaFqI96; arc=fail smtp.client-ip=40.107.7.71 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="OZaFqI96" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=U2TYLerIlbsTBM3KW3evjxsu+Pp23AftBez/9y8dy9zmn3IkaMjmCNtTiZqZyZ/sMlVLH3TEmYzOVcVO8+u6qUYg9EwMA72nDLMwNrG+Mvej0emW0qZY0kDRKwajntTcQpaEvAUCcHdj6HVy/cPBSpXRwniFKb7cdHiGk5N6DsjyGyh6THTXthCtpajyV8wwRIU8pTi4mdJL1ZmbrOtmI2nEEhG3eGZ/+15tf39xOMi7iAAnbWKH6fQpLHn0XrHEzeOporNBTCpOZ3+ARd1ZZ+BvoIyr37sX7cAFqxNW3NlLG3f9dtf+axyrZfx52trRK/kmOpmrGOto84hacQki+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=xXqrS2DOAbosEZO+DWDZnjhl9idB8ICy0/R0ISH48bQ=; b=nvPHDVTsMsZRjGQlyxHzAdGx0hxIKhXxavVDk7WbJmahNWr/pTZWvNEHwo1ij94qQyIDEauyIfnjyIBeg8Kez6jTsm+vHi2wgOF7eaevegzLlhyvY75oCM+0ZXRf9fF6pK3ZwEeEs4cVdNi8LaCg2Ww+1ZAcH0MGU6xvcTOhS0AGhTmZu00l5SjfG7tLLSYDCGcjotGHHlUVJQKg9LjDW2qw7MnCbWhw5sKAelv9cnm1eS0Obj5aoATiJ9Fm1i89Ov3/ZBOUmeCZajmO5RLrofPxsH6qtKcd3nh71aONeDNu1cr0QcVyeh0IPMZZ0UsOqSl7wGPiLqiPbpXrE/JfDw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xXqrS2DOAbosEZO+DWDZnjhl9idB8ICy0/R0ISH48bQ=; b=OZaFqI968AwJRVe72uS2BmDgvwoY8Mp2e0ZEI9tVsxNTYqm/v6X3kIVLyQfsYZNNwdpfiWH75vVxkannRcRM0q4I9+NcGzcSECiqPUXBYdWu5Tp4ZT9jSobljwnutlGmRdugPxdV9LoPUFiq8mNgEgacpF/ehdVT+Emm1p2EREs= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AS8PR04MB8898.eurprd04.prod.outlook.com (2603:10a6:20b:42d::15) by PA4PR04MB7999.eurprd04.prod.outlook.com (2603:10a6:102:c0::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7249.30; Fri, 2 Feb 2024 14:10:46 +0000 Received: from AS8PR04MB8898.eurprd04.prod.outlook.com ([fe80::40f:c80d:7049:8213]) by AS8PR04MB8898.eurprd04.prod.outlook.com ([fe80::40f:c80d:7049:8213%5]) with mapi id 15.20.7249.027; Fri, 2 Feb 2024 14:10:46 +0000 From: Iulia Tanasescu To: linux-bluetooth@vger.kernel.org Cc: claudia.rosu@nxp.com, mihai-octavian.urzica@nxp.com, silviu.barbulescu@nxp.com, vlad.pruteanu@nxp.com, andrei.istodorescu@nxp.com, luiz.dentz@gmail.com, Iulia Tanasescu Subject: [PATCH BlueZ 1/3] shared/bap: Properly cleanup bap remote endpoints Date: Fri, 2 Feb 2024 16:10:34 +0200 Message-Id: <20240202141036.9797-2-iulia.tanasescu@nxp.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240202141036.9797-1-iulia.tanasescu@nxp.com> References: <20240202141036.9797-1-iulia.tanasescu@nxp.com> X-ClientProxiedBy: VI1PR10CA0106.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:803:28::35) To AS8PR04MB8898.eurprd04.prod.outlook.com (2603:10a6:20b:42d::15) Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS8PR04MB8898:EE_|PA4PR04MB7999:EE_ X-MS-Office365-Filtering-Correlation-Id: 61d5af30-be27-40ca-51e3-08dc23f8bffc X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: YKyvn5I8dQbcTAfpDQyWS7OszJnf6gJc6S5FH7yFZZHGGxLdcDfZJvmED+aP5Ja71ojvReyUN4mdNNk3IK1CGUO7iAd/I5W+A7WyY5vqR+56bSQsflucOuAkch0Bp8+E/SVp+yZUgcpbJ69gDwBhvtW9aWVN6Zr80FgNZnxz4UwOsiMEr10CtmjsZlXXhxoZ6V6cek4XOkZhQQcxsu6rRrycFR9qJjvmv7rJ98idrvwFs/xJS8U/Vj4ni3ic31XW7piBSavVGVGp81uuqjfYPA1pQK54cmdln1h3VBdSi/VojsK/Hx18bmOjOV14VywW8dMnopJuPCrvygCbH+q0cs6gtIEumbn6N3OODhzNDejCJd6FxOGYNvGyTXbZwrOKC/SmqtGDUA3zzMLAIYTKkztcYSO8hmOOgYF1BXk60AHOUx/bQGxWzOWUVgodjJ4dbwfbSfmKbnLvo8Mg9qnLjusbHEiPx8FnJ40ybLrujRnjjkq9OHsZ3aVK+ufkvHfbznmbBafWtlUE8nt58e5yETT5Z/o+YKj+iPFdXKevJlvDxEyunulyblfFllmog4h1 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AS8PR04MB8898.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(136003)(346002)(376002)(396003)(39860400002)(366004)(230922051799003)(451199024)(186009)(64100799003)(1800799012)(83380400001)(1076003)(2616005)(6512007)(26005)(38100700002)(44832011)(5660300002)(4326008)(8936002)(8676002)(66556008)(2906002)(478600001)(6506007)(6486002)(6666004)(66476007)(6916009)(316002)(66946007)(86362001)(36756003)(41300700001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: kP2yk8BRzm7C/bWEOIYBN15nVO+TaqS5Skfq//qS7LW4Mcfjw1EA8oeryo+bPWKYeCIYuSrOnkaAUIZ7mlIRe16rDTTbRKXYR3w7K/IxasXV8mUYEU/s/msE5kG4i4q2G5t7KPym/sffhVgS7ZtVmaXp7kZt4yZg0LM1rw9M6uOBubHHq2oSMD0oFRhiicWFUDME/1IekoqWTVPlyGgUIdd8c822IEq+WQ4dg+dHepEJAMZEHZlPpCJZbSodGqKgdUHiHDTc1BeFOupDEs4R/y1KJn/VKs8/3NvJU2zaVLh2+QR+E4wlI5n66kU7lYkWjpRKFVlHa11oQ76/Ut+J5CPprzoPdw9QsSEle4yfZaSxdSiqoMk/YfCS73qRZCVvhEwFugsGUL93R3Kxw6oamEmaH3fbgPnR+YXlpxaFlXi8Mxup8d60Gga2YjQ5N7oYm1fyE7G1AqE59MDQaULmej0pgA8z+7NsbdsdIzMo6kodOW55o8WeDhNjrKht+pgxuDExZiXHRChl363RJi/He2m3ll0B87LUNC79YKjsBQXZsm6iAsH1GP8UMh9Le31YGomAt7dKS6vfligIYQSWxlb2wydwA8d68JgOtch6xx2MX1GwT5ZP/ALTfM6snhQ1+gnHtUQWWs6WY50jTQdW8gYuE+Kib59KPfnDIVZ3Z27YNWXU8P32zC8eOnP1EWm3FjDfInSvceZez0Lz7shO7o4rWCIIZyqGb9zkmPYda85yftRrL5QgkSeBEkOLb9I3UfQVljkSnTKqmZh+ZeaPsShKa2uV3F84f5tH7QYcfNXmy15jzqHI6R2SNgIE+WMt+TMjdEZmnvtbkdlXgM6mmi4UjyZ9AddfROvRtdoIHAd4LkYWrw9MgtQ/UzELvzTf8rhS2MXEvxCc9HelQ4BxakGEB/ws6OVlmSJVcJrVPtjF3Z+rtvx3Ymtal9pDuByKKgYSK0G+DLnR8GrWn9IFZEq2CJK847xyzcXY42g+ByI/aoer5jTW9Z+CdbVWS6/PaUDw24+xkBpL+WDz1myFoeU5JVwdk3uEtiPb/MxBx53E8Dkl1qJ6KZgLSnApCqbrIYi0Lvl8fLDJ0GLHLKBP0R2dF/CWjlOjnu6ACVvBV6V/hpSbYooQ5RTVv/QOgYlII/MuI2XZY7j3s7XCTYNFs39zl+7Bjq0ROxxoRX75PkGCg1ucq4tp0XwkaDnf4eQXbeS4cyhLQ8g+5g5Ms91nTU471LURu7N6GcDYj3dKiGsLsZi/BBcLhtVncJiLwi48PMQBd3BVcWPTP9ktD1lcOtR9dhDF6LswgcYf7VC3YQRinekQsSWaWBuPwsAtypd44FxXKraXRkvpXg5PnQrQ018a9qcqtJNr6AMqs+c0cULsJM7Rkm7u7KXG6/Q99d+g10xJcz9wR7tzWL/wB54yJZrN4myUSnAX5GXLkH1aKYwnQXRMtTr4IDVAjaM/+kxNnPk3ilJDvT4LU+c2/q1ZSP2ulR70ajWRE6w5/kq3V3gF0S8+JcxY++RnNy4i9OZAmfod7qbPR63EowqeZBt0L4kiQFaG6Qf+gWTVd+U4xmgJ9LWrWhuoQ+H2ZF/wg5GM28+dxLhLDtglKUyc/wFmDQ== X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 61d5af30-be27-40ca-51e3-08dc23f8bffc X-MS-Exchange-CrossTenant-AuthSource: AS8PR04MB8898.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Feb 2024 14:10:46.0724 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 1Ql+xvC4c4epyeCHlVf1mjmla/aVMiRlF+54C3aXbXKmwxNjNmiov3lICAWVhq/UQ1vVLuGK3iE04ai9YGnvFw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA4PR04MB7999 When freeing a remote bap endpoint, the endpoint reference inside the stream should be set to NULL, to avoid later use after free errors. --- src/shared/bap.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/shared/bap.c b/src/shared/bap.c index 851d6a5fa..60fb826c3 100644 --- a/src/shared/bap.c +++ b/src/shared/bap.c @@ -2979,6 +2979,16 @@ static void bap_state_free(void *data) free(state); } +static void bap_ep_free(void *data) +{ + struct bt_bap_endpoint *ep = data; + + if (ep && ep->stream) + ep->stream->ep = NULL; + + free(ep); +} + static void bap_detached(void *data, void *user_data) { struct bt_bap_cb *cb = data; @@ -3001,7 +3011,7 @@ static void bap_free(void *data) queue_destroy(bap->ready_cbs, bap_ready_free); queue_destroy(bap->state_cbs, bap_state_free); queue_destroy(bap->local_eps, free); - queue_destroy(bap->remote_eps, free); + queue_destroy(bap->remote_eps, bap_ep_free); queue_destroy(bap->reqs, bap_req_free); queue_destroy(bap->notify, NULL); From patchwork Fri Feb 2 14:10:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iulia Tanasescu X-Patchwork-Id: 13542928 Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04on2071.outbound.protection.outlook.com [40.107.7.71]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4F7C213EFED for ; Fri, 2 Feb 2024 14:10:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.7.71 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706883054; cv=fail; b=EJvsMPc5qnaDbXovlYRFK0mRgh9PBTBDUOIGorez3n7774cTGVM/eLzuAUedOyHTjIiL2d2bhNugVpWp0LVvD+XT71KlJg2uUpTmCBH3Lx8KU8GFR6+MtgSDP6gsNFTg3xqjwY7Pg3a/xqAseiZUmcfMCmt+EeS1VJiTab+QbJg= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706883054; c=relaxed/simple; bh=+RZlqB6i5/HVJmLZ4hdvi/Aq6pZdaVhy8I34kTH0Xwk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=L+AhuPcz2R1w8GuileE+CbpkQMUYsOV3xy2ZVH8ypvaLkNb3ptQ/ifg4OF45CIWC3cRdPYT9WSCiTosmcN38jO0fLw4IQu5lzkdb0Kz2hwOF7rllpBrPuW7+DaJIKy1GnPiJD7zooobLQiED1dp0F1HzsvHIQibNwiSqS92tl14= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=bmrJrYxE; arc=fail smtp.client-ip=40.107.7.71 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="bmrJrYxE" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YTPxRJ8Yep2rzgxQFc4alesGu5H1HKIhAgFYJhYgupwpl0tg0GYq0lyWA+RxfPk1zzBdQLxKbsPIcZiHceHr+Q/X7yc8HKSaVDQpojahPsDZCk4X9SUdSVXIQhAMdsFxP8CijlO86aZnDVFn+dCY3GdSJ015tC1lD7OaKlZtfp+7dHW2qubWGx4zVph2S4uow3TmD8jOmfPzTuRSRC0WpGet1CGFCcMvAp0lfVNKunhAv0boxN2LlpQQTkxJo3VOIEewuvaWHbfR+EydGokEYt9YjHGtBu161kbw4pHAPQTsMMYKOSf/z/qZY/u3x1F9P515ip7N/3j+o3FBrASRmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=vlNihasu5zZcuSm6JGbLwq+Hs+xJ6zkpy70O5Zblmiw=; b=aphHXhFiMSYpjgRqTIDy+izFXCdiQ83VQXqyLW1Rvu59TmxAbfnlNSavLVHwphXmK7duP6KTRuWT/jyG/FIGcUCD3WYSTiC+khF7LbxYladIAHunvAZRziDZoWPTG/hMlmkU7nOuTre9gNw58xLyaFpceGtnkPu+KdoYcKImXwP0eTMNpwIdygvioIs4oMIPRH+E/AvYajG4HV53otFsu5ZA44NCVDZkvyJjj9s86Ny1LLZ6Fs9PNAeCnyXAuyCK3o6/kkV23LGfaA4WnVmQqfxGgTgit6U1OI2moO92pPW7kofAJ+m29HSmoZxxKPhADwiIf0ynJrHMv4PXHrJzrQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vlNihasu5zZcuSm6JGbLwq+Hs+xJ6zkpy70O5Zblmiw=; b=bmrJrYxEuut6SkdyDSgPFY9ax3YBMSu4wgFMHQZkMlWqIrkn65FypzxtoXqCBFnIhYx9tlN4SV1i/+qHbC4MESK+nUmoDRVFXS7TCgbjmRIACwGfETZb7SCI+s9l9hIlubl3Ijx4qSWs7wcrz9PrfawiMZ9QDoHnMaeQxww2DdE= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AS8PR04MB8898.eurprd04.prod.outlook.com (2603:10a6:20b:42d::15) by PA4PR04MB7999.eurprd04.prod.outlook.com (2603:10a6:102:c0::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7249.30; Fri, 2 Feb 2024 14:10:49 +0000 Received: from AS8PR04MB8898.eurprd04.prod.outlook.com ([fe80::40f:c80d:7049:8213]) by AS8PR04MB8898.eurprd04.prod.outlook.com ([fe80::40f:c80d:7049:8213%5]) with mapi id 15.20.7249.027; Fri, 2 Feb 2024 14:10:49 +0000 From: Iulia Tanasescu To: linux-bluetooth@vger.kernel.org Cc: claudia.rosu@nxp.com, mihai-octavian.urzica@nxp.com, silviu.barbulescu@nxp.com, vlad.pruteanu@nxp.com, andrei.istodorescu@nxp.com, luiz.dentz@gmail.com, Iulia Tanasescu Subject: [PATCH BlueZ 2/3] bap: Fix incorrect parsing of caps and meta in parse_base Date: Fri, 2 Feb 2024 16:10:35 +0200 Message-Id: <20240202141036.9797-3-iulia.tanasescu@nxp.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240202141036.9797-1-iulia.tanasescu@nxp.com> References: <20240202141036.9797-1-iulia.tanasescu@nxp.com> X-ClientProxiedBy: VI1P190CA0044.EURP190.PROD.OUTLOOK.COM (2603:10a6:800:1bb::16) To AS8PR04MB8898.eurprd04.prod.outlook.com (2603:10a6:20b:42d::15) Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS8PR04MB8898:EE_|PA4PR04MB7999:EE_ X-MS-Office365-Filtering-Correlation-Id: 4793feb4-704c-499c-900e-08dc23f8c21a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xBCkHQvi69TiJKYftLLu0JBX4hermIFDYfO1GpM3fb7lS6gHJZ1qDlWVRSM3oDsXDvjfSDtmzLdvqpRfd4R8Gwv6JYh6cUrW841/t2QmzqsDKwvCp+rCsGeuPsDnQJ7/HZfbw7icAUm0lcSuGJH0UW6Wer60+HgyYkLywrzJxrCxKVqkNJpA5ng/bH1vwtb4AbnpVSrNTXkDF5MPvjKhgBadH+Z5dyGJ6WVCHjM3g481d2WZSuUwqVweB0qE3Fj5H1LtaYCvFwTARq4HT4VLYgAfrBcF23XJFuTznjWeC1YHehR21aXP3rIwO+TzIAoG8jcGcntjD0r1eP5jpkBhAuoOa5Q67Ao0fHMGeSOwoeqlB81QMzNcZ/S9En4IT9wSkegLIXKmKtzA+/Y9K+lP8aq4T0ALy6NANPHb7/b2MLItLEsHsuHnmLsrsM+Yop88GVOi4W2+0ijkaqwBfgTsNPCXhAPd31uSOLv8xoGYzxJ220NLcyFMo57iXMWuLZko7uBEPl7KfchMuzGn4/wOouGD4nR8w6ZHeAL5dp/E4Vx8QwAIw7gNxQg2YzTiX/wD X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AS8PR04MB8898.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(136003)(346002)(376002)(396003)(39860400002)(366004)(230922051799003)(451199024)(186009)(64100799003)(1800799012)(83380400001)(1076003)(2616005)(6512007)(26005)(38100700002)(44832011)(5660300002)(4326008)(8936002)(8676002)(66556008)(2906002)(478600001)(6506007)(6486002)(6666004)(66476007)(6916009)(316002)(66946007)(86362001)(36756003)(41300700001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Lf3p1YjZpVUHAR5d8kkLgH+ZxxqBLFF6oNsofNadx8P2SF0FxnTvwm6JJCeSboEHH8aXzwuEsveETFYAQWjignd2Epzxd33Lli3wirkObnFYCX2tyOWw1iEbAEEznTeme6OxWRhk9O9ZL2Dq0lnJ8P07Cy9ZabsVs3RMyNP/hp/IqU1LLU085SzkQEhPy7RwMCv8wP86YUiUfrb9H5NOb4EUp21Uin4v66uAECNqcIxTsTkxi8XhMMi3jXQynPK6Vv0uc1h2l2MlkwH/sXHChGDmzSaC+UCV8u0VvzqigELmCIHhDK2T2v0uJAOEDc1U2JAV7nRmrLh4OmJWoI34xBynhKUc72B05P+PPa//AeTrAHr3Jr8Ax57u3t5mrrdywfKtd5Meaweg1JTs++/HkJnzSG1jCwSuQs7ZmKKAPEcIGR/8dLxY7ANupBVh3uSbA6SwjefNo7ZJ8YKjsj0sPrnFWoR23Qm8kFQQYSEiAkyFT8QFj2z8EGCush159DRwLZxF0zAfT+EUDVjxV3mXlsd13ENxdg76n0ffdBT82bDQY061wWtfeehv7vGBViaf1+xSuQKm2vz9D8IgY9NGZ0X3FRiusAd+Bu/OE5miTkNqRir4VN2vgIEnJZt1bLV8em/QMzGwEBNlOQLz9dnw9bI656+HAftce37J9el0+PSfncH7P0U1UaaiOAPhXaToaVyGbGeN/FmORpUs3ULtLoGwtoDjw9vtH5UDhfBiInqNbqKVI+ezAP1d2HBg2ZJM+gEHaXI4h3xlV+sSc5YlD8QvOSQFAMw88Qt/KyAxX4EOfJXxff7T4iGip3EIr1I0/U+BDJcluj7jyuRKbiH5KZpH535RzxKDaIKZ66VsYf+owbvfQs+gJlGA7at9Zi8H8K1dawSxHTEpaNCImzC3VY662rwc0uWkziihaRPGd2PFmf7kafBTtxW72gSy3uTXC8IvTXlqrfLDJ406RsvtOc2ziwsj77DDhqu/I+/Qs4DFQBXt7D5I/RWGAavKGmE4jX+lBNmnfZExyPF9cMqrv22k4KeU7vdH69xA1/CvjBmowa9kt9/D80K3etDmXCy9RW7aFKueiuI5n2Io2UD1u94AGnJ00NL4fQEjhokzbi86tvMaamCXTYIjLPTDI1EvlUouoXy+gzvCDj8SN/0jZ2UfdL18D55KFFQum+9enCwArzfIt9r2J0M/Kn/Qr/nRUjXPS83naz6yJQX+hjRubRgdehQubhJ3CGA20RMhbnvLvtVUjCMtW9op29yAsThdGd+EJh2eWopor8ygJJB2qnX3tpOMuviWvIIp+QV/s6XnEcsvW/oFeW2eaMEVQgXVSdYeoHkkHBuXSPPoGuPCLWBSlMiXCrO7CAGil9o5TVATV76t6LWtmEsmt/xagVVxmBECAF1v+SlkSiSZspEZn9bB3g5ZryE3NQgrxpVt2RRd6SnSTJpT5Hvk3ucuzXxOPKWaihasD62ltcZVqcb8f1Wu+QI90WjEUuoR5/Rz7bkmKktAL/2DRcoKtNBAqYMVMlDQ70E0A1RcT1G6/V6nVdmHSg+/rrcg4EZPJYtBQoRz6iBtU7sH4QZ6XsZ1bt6fFZyJGEWmWyVGXV5HztiLlg== X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4793feb4-704c-499c-900e-08dc23f8c21a X-MS-Exchange-CrossTenant-AuthSource: AS8PR04MB8898.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Feb 2024 14:10:49.6576 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 6ZvptsVsPnY7S2WJZJIBOxX7MauE9EkHyX5Aj1qSnbbzuH3vCGwdqk3LBZw4NiWftIl0ApuThQ2sNjaspkDUtg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA4PR04MB7999 This adds a fix to properly parse the stream capabilities and metadata in parse base. --- profiles/audio/bap.c | 40 +++++++++++++++++++++++++--------------- 1 file changed, 25 insertions(+), 15 deletions(-) diff --git a/profiles/audio/bap.c b/profiles/audio/bap.c index 7faa6be7f..909d57121 100644 --- a/profiles/audio/bap.c +++ b/profiles/audio/bap.c @@ -433,7 +433,8 @@ static bool parse_base(void *data, size_t len, util_debug_func_t func, }; uint8_t capsLen, metaLen; - uint8_t *hexstream; + struct iovec cc; + struct iovec metadata; if (presDelay) { if (!util_iov_pull_le24(&iov, presDelay)) @@ -467,15 +468,21 @@ static bool parse_base(void *data, size_t len, util_debug_func_t func, if (!capsLen) return false; + + cc.iov_len = capsLen; + cc.iov_base = util_iov_pull_mem(&iov, capsLen); + if (!cc.iov_base) + return false; + if (caps) { - if (!(*caps)) - *caps = new0(struct iovec, 1); - (*caps)->iov_len = capsLen; - (*caps)->iov_base = iov.iov_base; + if (*caps) + util_iov_free(*caps, 1); + + *caps = util_iov_dup(&cc, 1); } for (int i = 0; capsLen > 1; i++) { - struct bt_ltv *ltv = util_iov_pull_mem(&iov, sizeof(*ltv)); + struct bt_ltv *ltv = util_iov_pull_mem(&cc, sizeof(*ltv)); uint8_t *caps; if (!ltv) { @@ -487,7 +494,7 @@ static bool parse_base(void *data, size_t len, util_debug_func_t func, util_debug(func, NULL, "%s #%u: len %u type %u", "CC", i, ltv->len, ltv->type); - caps = util_iov_pull_mem(&iov, ltv->len - 1); + caps = util_iov_pull_mem(&cc, ltv->len - 1); if (!caps) { util_debug(func, NULL, "Unable to parse %s", "CC"); @@ -504,17 +511,20 @@ static bool parse_base(void *data, size_t len, util_debug_func_t func, if (!metaLen) return false; + + metadata.iov_len = metaLen; + metadata.iov_base = util_iov_pull_mem(&iov, metaLen); + if (!metadata.iov_base) + return false; + if (meta) { - if (!(*meta)) - *meta = new0(struct iovec, 1); - (*meta)->iov_len = metaLen; - (*meta)->iov_base = iov.iov_base; + if (*meta) + util_iov_free(*meta, 1); + + *meta = util_iov_dup(&metadata, 1); } - hexstream = util_iov_pull_mem(&iov, metaLen); - if (!hexstream) - return false; - util_hexdump(' ', hexstream, metaLen, func, NULL); + util_hexdump(' ', metadata.iov_base, metaLen, func, NULL); return true; } From patchwork Fri Feb 2 14:10:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iulia Tanasescu X-Patchwork-Id: 13542929 Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on2059.outbound.protection.outlook.com [40.107.15.59]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 788A913DBBC for ; Fri, 2 Feb 2024 14:11:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.15.59 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706883062; cv=fail; b=l7uUUXc06vWBmAuQ9+RNOELVDzvSa2yuf2bBnO3TLgTTU/kUpW67W1KIMm7rN8mnIdwJNk8G/DJ01+9PUBfgqfZBSmfoazF8KlVrksfDpghXJGzPdgzId3i92iQ/584WL7iuzXN+o5m05MN9npOzMhCaV1+bIMfB5IvxpyXt29A= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706883062; c=relaxed/simple; bh=VY6q9tTnmpK3Xk2Jp1LLqHaOIl9jMA/PrhKiaUkf2dY=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=VeyykA5A4FkXmvIioLh5QN7Agb/9QGPB24cbC7SAy1IW5GunYLS7sf284tx6ohW7VDYQXIjcWeWM/5zp+ViwqgHmWF3+Y22dwl9Ponbmy1Jv+keMbSBoD+nJZy4bdJ37cgtyVTtrmPsVCUom0i7cD2Zm9hvdLzgDaO7+A4ak7to= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b=lKG7HjWn; arc=fail smtp.client-ip=40.107.15.59 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=nxp.com header.i=@nxp.com header.b="lKG7HjWn" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NZSp7abM+tWNDtytJC5MPaa0BHzv1h0isYEKD5xscVYBHHA6nr7JrpRCc6Yiq2DOn/+1637ysmqKUqlqqVr25dis6mnRYX6Cm9rmacUCLQEA84XK+YQp/ghOv++JkmC1IVRiLLgA56sg62zSmULqEpy1uJWYayErZ8pLSFrx0O6nyrOcTLO+1NjwxloGUFOti3MmdCT7FzKMydnt90yNOgNJx05VZvgEfN9D7NpBvrL7ggGx9U3lrt6nE+SyRm5tfMCW4EDXy126z+EVDz2ry/vuhtiiUWi7avv4W6bW7JrjZ1h/gPXsJH/YjTr176LWAJecF75AM7B/I5YhL3ffqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=GjpYAqn5x2KCa0IJUTyQe3dhAmPVvUFtmp9yGBlW8nc=; b=K54oZQszcD/LgsR5CyK+IDkii/boVcau66LO1Qg9A3QqeJml67FSaN4N6CgeeWumBvxQc1iRhB1LE/EnHDe6HcFJgAIaLo1cNtCFLprEY3QvH7K3klBh5gg/EO2i0nSHEgxMbz9S/DsrQret5NspD95a9TwjGo+2Gz3vIRS8mBYmS/y/RtnqY7wOvsvfk7dI7XoNtno2YeUpB5vDAw94yZg0pq9Fo07K6P3chF073wF34iYlxKNx2ZqLAkg7JajxVNOe6Wb9bu+kvEE8v0XY32MfJmy5vRyBUOWtGTTBuTTpyNIc43AACSp4+IFOGCF9ccLICz9L7jQIe0VaifBTZA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=GjpYAqn5x2KCa0IJUTyQe3dhAmPVvUFtmp9yGBlW8nc=; b=lKG7HjWn9yIEAHhl9oIM05tD4/yP5tzB4TVFoaxbfDmnFra8Shl5JWGTV5CTrKGiagUWggn8v91FSKaSAJA7gwaEFMDGoA5cUVOhHQRaVrH39EWuQe581342zJbk6VoLOnLbyhW4AXkHlCx4NsYqEXw0VE79lxi/EcqY/Mvf7M4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AS8PR04MB8898.eurprd04.prod.outlook.com (2603:10a6:20b:42d::15) by PA4PR04MB7999.eurprd04.prod.outlook.com (2603:10a6:102:c0::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7249.30; Fri, 2 Feb 2024 14:10:58 +0000 Received: from AS8PR04MB8898.eurprd04.prod.outlook.com ([fe80::40f:c80d:7049:8213]) by AS8PR04MB8898.eurprd04.prod.outlook.com ([fe80::40f:c80d:7049:8213%5]) with mapi id 15.20.7249.027; Fri, 2 Feb 2024 14:10:58 +0000 From: Iulia Tanasescu To: linux-bluetooth@vger.kernel.org Cc: claudia.rosu@nxp.com, mihai-octavian.urzica@nxp.com, silviu.barbulescu@nxp.com, vlad.pruteanu@nxp.com, andrei.istodorescu@nxp.com, luiz.dentz@gmail.com, Iulia Tanasescu Subject: [PATCH BlueZ 3/3] bap: Remove incorrect assignment of listen io Date: Fri, 2 Feb 2024 16:10:36 +0200 Message-Id: <20240202141036.9797-4-iulia.tanasescu@nxp.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240202141036.9797-1-iulia.tanasescu@nxp.com> References: <20240202141036.9797-1-iulia.tanasescu@nxp.com> X-ClientProxiedBy: VE1PR08CA0015.eurprd08.prod.outlook.com (2603:10a6:803:104::28) To AS8PR04MB8898.eurprd04.prod.outlook.com (2603:10a6:20b:42d::15) Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS8PR04MB8898:EE_|PA4PR04MB7999:EE_ X-MS-Office365-Filtering-Correlation-Id: 960fe505-2d7d-40b4-5547-08dc23f8c70a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ni7cg4spcONK07XM3ByVincJ8Ovf6FkCU3rwFNq8k543dLj5LEyOHhHuOchcOTt7C6th7viyaH52indxBnIZnZCkT1qh4WN31Qu9YCn0u/FEz7mr4tpYldCP31bVn1UimB5b/V2zoqjh2Vg5FpdgvdHccnb0L9V3M0DZM8866rMpBuRlrkGICDhjn3+E7wbb0kOSXD5OOmo/J/FiRPGYRTi3KB67qgOSDHjYcY9BYEbrO800guy/SWoCch//cNK2vQcKmdL4OZ4y7QG0JG4QWnZbp4Y5pxU2jqKH2c6BCdvfiLbWxXewSiszu/oylXlaLsDFr4ySRNtLL8E0J9o/qbl/9WUFYOYyarsbvtDAp+f2Tisro7oSPpfgp6adtLSNGRvjUx9E6krCtTJemzjXVFU9VpCJQLeJ6nuYa5pZ2uZVsoFmRTnAtGeigfq8JglLZsNZX68+lBun2PxoWsT3EY/RqsV1q72SSBK7/yjT7s/pU7psQqCd4amGIO3mp71sgCKyARVR0Jh9nKj0wTRUVhGM8OfvI14o0J0oilMxOhq7RT+BFqgI5uSZOiHqb6BpDPa7eAs+jHPcKidtDJV1bhdAhPVb+ZL9w9Q96z+hMB8zbVNdrOE5LaIklNQ5RMTg X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AS8PR04MB8898.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(136003)(346002)(376002)(396003)(39860400002)(366004)(230922051799003)(451199024)(186009)(64100799003)(1800799012)(83380400001)(1076003)(2616005)(6512007)(26005)(38100700002)(44832011)(5660300002)(4744005)(4326008)(8936002)(8676002)(66556008)(2906002)(478600001)(6506007)(6486002)(6666004)(66476007)(6916009)(316002)(66946007)(2013699003)(86362001)(36756003)(41300700001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: MFDNhlpCt1TN9y53IwYw63RDFpXsQli/ibKTaQsmrVjNVMciKpDIyiBi6SlPwFFy8IpZ5e9eSIfvG6DKPFquDlxqJeimjr9O+nfvjThTnuoSpxMKRxy2yQcRiIbIhlh0FPONx/564y8Xg7sj94hPca/3ro6qkWkey82ZZa8jlXRzV/0gYU0Ug24RBjhaNIBzOm9t4HWmt441jNxNYsAlcMvKXssnFoBNkPbD8j3kRd0MHrJG/hYx8qRn+MxNbMfpVy/oq5sQp2/moqCL348bjyfcy6FFJ+6rdhZVHiQPGg3sKA4ElK0OnY+045ClzLm8uvkBr6d+c3AASISoc40dUMZ0puRoJwzaJmLVuT8Et3Sa9LG6kkwMU0f7SGeuJyP6vgD1ePMIYFHDB52+R0QWevmnbA6j7ytGrSb5IaD1RYapq+jv/sSj8rrMnMzOOPQ09Ewiu8NekZ8XzY4/ZIWiLO/KddcVT27ox+ISFxFTCehbCKAjXXcxEAGQBWvfbb06fAYBa0gdj2sf1wlv1vIDr6sd9VyH5PeJyn9UvTj8Ld9C5rC6L0gOTbyNavO2q9MapV3BvXqJXatJuduZvSoDWOC9Pf7LKSjCsScV6sVJiuj3GAyT31f4wpUpv6s6tisNPsuU6mHv6hCyCqV+OicpSzvymWclBd8X3/wCLZILLvRqR1qVLvzcP8a9FUr9IyCurf5mUT823CWzIopAGPAkZ6anxk+eJKWapuY5v3OOFq3ZdoVsgzXNv2YnN1kPTNnbiPjHLNmQaCTUa/2NR0DjAi3UlHUQmBqfTKsYjKzdJUQMsZ4Fvc6H/TyIjf6dOGbqkmhNx0Uln55ZBy2ufQLn3PrqJltpnb3kz762WpOWTTrmM7aqWZkVxPcXYgYBvIl+eVEzh+6+B5mXlNDtFvp/RBIs5lvUUIPiXgHiWbvVYxK7rkIZps+Q32MLkbyTglCUsUFO7TMdEhZiM3PqmPUbBkhrjTvGfow2pyTpdCRA+ky4+Tvn1RgsMe4oE7Iz9iMhHPw52ETmn6ac0mrcEX/jzooV78NAT4rhZOtXIrUzehxG4AwPjiBH38j7TXqzFYOxW6/iRcwqHdHn0DoqC0Pz8FqxqDesHuN6uYUbwc5bzNHFaNjQmWqJI942AtNUWiG+7tXjRjxAdhRoyjKV0IbXE7QD8epOu7FiyXufE21rMy8mLgYLZQnv89vctnuD/DN2C6/tOTJXZHy9nSQy2Oo8Afo3NkwlXOGK52ePSoSy/08rZL2PnKIuXYMOE5aC3HUdfkSPCZZRZY/9utTT3rxN/ozM3ing7I2LUaSSOdOQZ7goA8uc9EqjvSxYNVoOO32AJ2/8iUN8PyMvSLrC/sCZX7qL7VN+JKuJBxioSH5hx5XCEqpklASVKXNuwYd4p743uyV5haheYIhudHv8mk8idQRktvBl9TLm8nsuPHMn97yBkiqwnyfAxde33pCYiYC+faVxT/6ht7KjM4N/VJgzwDWSqd3+NcRFRv+g4OlWaEPVYKMw6TIYkcS4cwOkqZqd1Uw7cW+xz/CE65W/2aEvinIH63MIYeg+R3AgirJXUJLBYV9usDmgqj4ecJmvhjSO8bHT6ZedHvUtuFtfT4MGXg== X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 960fe505-2d7d-40b4-5547-08dc23f8c70a X-MS-Exchange-CrossTenant-AuthSource: AS8PR04MB8898.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Feb 2024 14:10:57.9489 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: an0MpyOL+nC9/G64I2T34X2tR6nsQa9DdNCbSllt6LzDscm4C/smQriJfw+TVqPuCniDARNs7sIeCcZyD+Dpzw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA4PR04MB7999 For a broadacst sink, the io that is notified in iso_bcast_confirm_cb is the stream io, so the listen io should not be updated. --- profiles/audio/bap.c | 1 - 1 file changed, 1 deletion(-) diff --git a/profiles/audio/bap.c b/profiles/audio/bap.c index 909d57121..94c1de1c6 100644 --- a/profiles/audio/bap.c +++ b/profiles/audio/bap.c @@ -1061,7 +1061,6 @@ static void iso_bcast_confirm_cb(GIOChannel *io, GError *err, void *user_data) setup->metadata); setup->id = bt_bap_stream_config(setup->stream, &setup->qos, setup->caps, NULL, NULL); - data->listen_io = io; bt_bap_stream_set_user_data(setup->stream, ep->path);