/* Helper function for checking if particular interface is a part of the audio device. 
This function checks if given interface is a part of given audio device. If so then true is returned and audio_dev_data is considered correct device data. */
static bool is_interface_valid(struct usb_audio_dev_data *audio_dev_data, uint8_t interface)
/* Helper function for checking if particular interface is a part of the audio device. 
This function checks if given interface is a part of given audio device. If so then true is returned and audio_dev_data is considered correct device data. */
static bool is_interface_valid(struct usb_audio_dev_data *audio_dev_data, uint8_t interface)
{
	const struct cs_ac_if_descriptor *header;
	header = audio_dev_data->desc_hdr;
	uint8_t desc_iface = 0;
	for (size_t i = 0; i < header->bInCollection; i++) {
		desc_iface = header->baInterfaceNr[i];
		if (desc_iface == interface) {
			return true;
		}
	}
	return false;
}