Lines Matching full:bis
145 /* Create a mask for the maximum BIS we can sync to using the number of streams
146 * we have. Bit 0 is BIS index 1.
605 } bis[BT_ISO_BIS_INDEX_MAX]; member
611 * This is called for each BIS in a subgroup
613 * Gets BIS channel allocation (if exists).
614 * Always returns `true` to continue to next BIS
616 static bool bis_get_channel_allocation_cb(const struct bt_bap_base_subgroup_bis *bis, in bis_get_channel_allocation_cb() argument
624 data->bis[idx].index = bis->index; in bis_get_channel_allocation_cb()
625 data->bis[idx].chan_allocation_available = false; in bis_get_channel_allocation_cb()
627 err = bt_bap_base_subgroup_bis_codec_to_codec_cfg(bis, &codec_cfg); in bis_get_channel_allocation_cb()
629 printk("Could not get codec configuration for BIS: %d\n", err); in bis_get_channel_allocation_cb()
631 return true; /* continue to next BIS */ in bis_get_channel_allocation_cb()
634 err = bt_audio_codec_cfg_get_chan_allocation(&codec_cfg, &data->bis[idx].chan_allocation, in bis_get_channel_allocation_cb()
637 printk("Could not find channel allocation for BIS: %d\n", err); in bis_get_channel_allocation_cb()
639 return true; /* continue to next BIS */ in bis_get_channel_allocation_cb()
642 /* Channel allocation data available for this bis */ in bis_get_channel_allocation_cb()
643 data->bis[idx].chan_allocation_available = true; in bis_get_channel_allocation_cb()
645 return true; /* continue to next BIS */ in bis_get_channel_allocation_cb()
649 * Called for each subgroup in the BASE. Will populate the 32-bit bitfield of BIS indexes if the
655 * - Exist only in the BIS codec configuration
656 * - Exist in both the subgroup and BIS codec configuration, in which case, the BIS codec
698 /* Get channel allocation at BIS level */ in subgroup_get_valid_bis_indexes_cb()
706 /* If no BIS channel allocation available use subgroup channel allocation instead if in subgroup_get_valid_bis_indexes_cb()
710 if (!data.bis[i].chan_allocation_available) { in subgroup_get_valid_bis_indexes_cb()
711 data.bis[i].chan_allocation = subgroup_chan_allocation_available in subgroup_get_valid_bis_indexes_cb()
717 /* Get the BIS indexes */ in subgroup_get_valid_bis_indexes_cb()
719 if ((data.bis[i].chan_allocation == CONFIG_TARGET_BROADCAST_CHANNEL) || in subgroup_get_valid_bis_indexes_cb()
720 ((data.bis[i].chan_allocation & CONFIG_TARGET_BROADCAST_CHANNEL) == in subgroup_get_valid_bis_indexes_cb()
723 bis_indexes = BT_ISO_BIS_INDEX_BIT(data.bis[i].index); in subgroup_get_valid_bis_indexes_cb()
725 printk("Channel allocation match. BIS index bitfield 0x%x\n", bis_indexes); in subgroup_get_valid_bis_indexes_cb()
728 return false; /* bis index found */ in subgroup_get_valid_bis_indexes_cb()
729 } else if ((data.bis[i].chan_allocation & CONFIG_TARGET_BROADCAST_CHANNEL) != 0) { in subgroup_get_valid_bis_indexes_cb()
731 chan_allocation |= data.bis[i].chan_allocation; in subgroup_get_valid_bis_indexes_cb()
732 bis_indexes |= BT_ISO_BIS_INDEX_BIT(data.bis[i].index); in subgroup_get_valid_bis_indexes_cb()
736 printk("Channel allocation match. BIS index bitfield 0x%x\n", in subgroup_get_valid_bis_indexes_cb()
740 return false; /* bis indexes found */ in subgroup_get_valid_bis_indexes_cb()
763 * Get a 32-bit bitfield of BIS indexes that cover the channel allocation values in in base_recv_cb()
771 printk("Failed to get valid BIS indexes: %d\n", err); in base_recv_cb()
778 printk("Failed to get BIS indexes: %d\n", err); in base_recv_cb()
993 /* Bit field indicating from which subgroup(s) BIS sync is requested */ in bis_sync_req_cb()
1006 * BIS sync request from more than 1 subgroup is not in bis_sync_req_cb()
1010 printk("Unsupported BIS sync request from more than 1 " in bis_sync_req_cb()
1019 printk("BIS sync req for %p: BIS indexes 0x%08x (subgroup indexes 0x%08x), " in bis_sync_req_cb()
1618 printk("Waiting for BIS sync request\n"); in main()