History

Merge tag 'sound-5.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound updates from Takashi Iwai: "Many updates in this development cycle are found in ASoC where it got a wide range of changes for the continued refactoring. Some highlights are below. ASoC: - Continued refactoring work by Morimoto-san toward the full componentization; the changes are seen allover the places - Support for force disconnecting muxes in DAPM - Continued development of ASoC Intel SOF stuff - New drivers for Cirrus Logic CS47L35, CS47L85 and CS47L90, Conexant CX2072X, Realtek RT1011 and RT1308 HD-audio: - More fixes and adjustments for ASoC SOF HD-audio - Fix for resume problem on some Realtek codecs USB-audio: - A few fixes for the issues reported by syzbot USB fuzzer - Fix for UAC2 extension unit parser - Quirks for Line6 Helix, Emgaic Unitor 8 FireWire: - Lots of code refactoring and fixes in most of its components" * tag 'sound-5.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (626 commits) ALSA: firewire-lib: code refactoring for local variables ALSA: firewire-lib: code refactoring for post operation to data block counter ALSA: firewire-lib: code refactoring for error path of parser for CIP header ALSA: firewire-lib: fix different data block counter between probed event and transferred isochronous packet ALSA: firewire-lib: fix initial value of data block count for IR context without CIP_DBC_IS_END_EVENT ALSA: firewire-lib/fireface: fix initial value of data block counter for IR context with CIP_NO_HEADER ALSA: firewire-lib: fix invalid length of rx packet payload for tracepoint events ALSA: usb-audio: fix Line6 Helix audio format rates firewire-motu: fix wrong reference count for stream functionality at error path of rawmidi interface ALSA: firewire-digi00x: fix wrong reference count for stream functionality at error path of rawmidi interface ALSA: dice: fix wrong reference count for stream functionality at error path of rawmidi interface ALSA: oxfw: fix wrong reference count for stream functionality at error path of rawmidi interface ALSA: fireworks: fix wrong reference count for stream functionality at error path of rawmidi interface ALSA: bebob: fix wrong reference count for stream functionality at error path of rawmidi interface ASoC: SOF: Intel: implement runtime idle for CNL/APL ASoC: SOF: add runtime idle callback ASoC: hdac_hdmi: report codec link up/down status to bus ASoC: SOF: debug: fix possible memory leak in sof_dfsentry_write() ASoC: sunxi: sun50i-codec-analog: Add earpiece ASoC: rt5665: remove redundant assignment to variable idx ...

Linus Torvalds committed 7 years ago

Commit 4cdd5f92 parents 2d41ef5 0dcb4ef397 files · +28605 −7206Browse files

Showing the changes to include/uapi/linux (1 of 397 files). Show all

Unified · Split

include/uapi/linux/usb/audio.h+37−0
@@ -450,6 +450,43 @@ static inline __u8 *uac_processing_unit_specific(struct uac_processing_unit_desc · 449 unmodified lines
450450 }
451451 }
452452
453+/*
454+ * Extension Unit (XU) has almost compatible layout with Processing Unit, but
455+ * on UAC2, it has a different bmControls size (bControlSize); it's 1 byte for
456+ * XU while 2 bytes for PU. The last iExtension field is a one-byte index as
457+ * well as iProcessing field of PU.
458+ */
459+static inline __u8 uac_extension_unit_bControlSize(struct uac_processing_unit_descriptor *desc,
460+ int protocol)
461+{
462+ switch (protocol) {
463+ case UAC_VERSION_1:
464+ return desc->baSourceID[desc->bNrInPins + 4];
465+ case UAC_VERSION_2:
466+ return 1; /* in UAC2, this value is constant */
467+ case UAC_VERSION_3:
468+ return 4; /* in UAC3, this value is constant */
469+ default:
470+ return 1;
471+ }
472+}
473+
474+static inline __u8 uac_extension_unit_iExtension(struct uac_processing_unit_descriptor *desc,
475+ int protocol)
476+{
477+ __u8 control_size = uac_extension_unit_bControlSize(desc, protocol);
478+
479+ switch (protocol) {
480+ case UAC_VERSION_1:
481+ case UAC_VERSION_2:
482+ default:
483+ return *(uac_processing_unit_bmControls(desc, protocol)
484+ + control_size);
485+ case UAC_VERSION_3:
486+ return 0; /* UAC3 does not have this field */
487+ }
488+}
489+
453490 /* 4.5.2 Class-Specific AS Interface Descriptor */
454491 struct uac1_as_header_descriptor {
455492 __u8 bLength; /* in bytes: 7 */