Received: by 2002:a05:7412:f690:b0:e2:908c:2ebd with SMTP id ej16csp1051862rdb; Fri, 20 Oct 2023 07:13:49 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFGC43VtXW9JW6HOmy9qai6JAxUK+yiytS4QwDpv/S018fOiPTfAbCYJlapjuVhH/HTkgMW X-Received: by 2002:a05:6a20:4424:b0:13a:dd47:c31a with SMTP id ce36-20020a056a20442400b0013add47c31amr8139746pzb.20.1697811229556; Fri, 20 Oct 2023 07:13:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697811229; cv=none; d=google.com; s=arc-20160816; b=ZZgp52ycMhpHMCeBQkcZBNBtTU/VyMaPpU83+kzNmg861+mtCKpXCOj5EQab+/s/Ub WhBx86gwHg5Nr5OB0+0rHIkl6UuiCTxdMx28fCp1PC1lXZ4UnHleilX641zWr2dPjrNw +UsSg/MLy5nbS8Mv5gXfLxG0XiZ6yaaTzXlqwsAfiX7key/SdHZsfTz/sF4vh/HcUrTd d5sCOwdN4fOCiFvQLMkt5Z40r2PnEZjXkCBTft0m98QaL/WA7zESL8gSDPakTsSdMshO PkzhHn0K8EvkwlI4qUYO0IXNm33mqRPLyuKqR7Ja0HRFf26Ex3mPOaCrEzpmRr8gBboo SJzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=elzhYWt4GblEYd780jYX1GfL9dSK3dJg3ZWEUL9xv1A=; fh=U3ev7U7uX1ilviB+nfdu7oOFhneDnAUw+Nb8W7HsKBg=; b=Wg0UpWHUWUQ1gD4rIL/gMISYAyGedFSB7QyGrDYvHV6yywKPgKg65HyXCGD8w9RyxM ZTtX7PePi8HcoQs/U0EbK6m3L3Q/Y8MoOJsWgqjN+eZdVcHtjxx4Ss+TS57o4edl5byA fuymnrmJG4EQg+uPWM4MVDuMtYasRkbcJADvqKXg1aT4aZm3nxK7znFKAOI1bK+FkISx EhVrp2l12KAW7kYYQYJMDhW0t/FcOLUfzyJYdBn6alrJGET+ohuZwrUE0wLtchSa4FD3 5lXpIVsVtdOXuOqddmZ0lsLAi5KFkXdIibPzfXDaHDJhtDU0qfd9HY/A1a2sd/6rA7Fn rUHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=RMgu5prW; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id w15-20020a63934f000000b00578db71451fsi1968267pgm.501.2023.10.20.07.13.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Oct 2023 07:13:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=RMgu5prW; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 650F183C9FBA; Fri, 20 Oct 2023 07:13:46 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377419AbjJTONp (ORCPT + 99 others); Fri, 20 Oct 2023 10:13:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42068 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377530AbjJTONo (ORCPT ); Fri, 20 Oct 2023 10:13:44 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1B94B1A8 for ; Fri, 20 Oct 2023 07:13:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1697811223; x=1729347223; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=aBVfpb1kYIWESCE+iWgnY0qK9+sW7PPcGg7TBzMu0OA=; b=RMgu5prW18gPLUD8oug2wZ1v1Woin56Orvvf0P2GhQDqFSilpKrjOYzQ U/p5TbLnq35E7TpQMT0KBxKKe9lAd5egM+BdI8ij+tjIIBRjkG3x9tGcq yDXHz8nWtoHmD6NGJ08OVgESSP1ZCGP6RvkBnOc/iA+rHfJesfzHoSKcc l8ydBcVH7+5PWnCgwYJv8qcNk2oT5FjSp8+B4LM7DL1SwOC7Enm7ghGK0 apzwNxdN2u5c2Wa4goPRnh0XSIsPG0whTv7T49UP5r/NpkI2Zl9ctE5LZ Fux/gq409neBymxWSjYMttSHkks9v4HdxBPBn4WjH/u0iNmLQsxVWGTMZ w==; X-IronPort-AV: E=McAfee;i="6600,9927,10869"; a="365840862" X-IronPort-AV: E=Sophos;i="6.03,239,1694761200"; d="scan'208";a="365840862" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Oct 2023 07:13:42 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10869"; a="1088756485" X-IronPort-AV: E=Sophos;i="6.03,239,1694761200"; d="scan'208";a="1088756485" Received: from intel-lenovo-legion-y540-15irh-pg0.iind.intel.com ([10.224.186.95]) by fmsmga005.fm.intel.com with ESMTP; 20 Oct 2023 07:13:41 -0700 From: Kiran K To: linux-bluetooth@vger.kernel.org Cc: ravishankar.srivatsa@intel.com, Kiran K Subject: [PATCH v1 2/5] bap: Fix update of sink location value Date: Fri, 20 Oct 2023 19:55:51 +0530 Message-Id: <20231020142554.486629-2-kiran.k@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231020142554.486629-1-kiran.k@intel.com> References: <20231020142554.486629-1-kiran.k@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Fri, 20 Oct 2023 07:13:46 -0700 (PDT) pac->sink_loc needs to be updated only if there is a change. --- src/shared/bap.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/shared/bap.c b/src/shared/bap.c index 925501c48d98..2fd21b81b72d 100644 --- a/src/shared/bap.c +++ b/src/shared/bap.c @@ -2491,13 +2491,11 @@ static void pacs_sink_location_changed(struct bt_pacs *pacs) static void pacs_add_sink_location(struct bt_pacs *pacs, uint32_t location) { - location |= pacs->sink_loc_value; - /* Check if location value needs updating */ if (location == pacs->sink_loc_value) return; - pacs->sink_loc_value = location; + pacs->sink_loc_value |= location; pacs_sink_location_changed(pacs); } -- 2.34.1