diff options
Diffstat (limited to 'sound/usb/usbaudio.h')
| -rw-r--r-- | sound/usb/usbaudio.h | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/sound/usb/usbaudio.h b/sound/usb/usbaudio.h index 3e2b0357793..91d0380431b 100644 --- a/sound/usb/usbaudio.h +++ b/sound/usb/usbaudio.h @@ -36,9 +36,11 @@ struct snd_usb_audio { struct snd_card *card; struct usb_interface *pm_intf; u32 usb_id; - struct mutex shutdown_mutex; + struct mutex mutex; + struct rw_semaphore shutdown_rwsem; unsigned int shutdown:1; unsigned int probing:1; + unsigned int in_pm:1; unsigned int autosuspended:1; unsigned int txfr_quirk:1; /* Subframe boundaries on transfers */ @@ -46,6 +48,7 @@ struct snd_usb_audio { int num_suspended_intf; struct list_head pcm_list; /* list of pcm streams */ + struct list_head ep_list; /* list of audio-related endpoints */ int pcm_devs; struct list_head midi_list; /* list of midi interfaces */ @@ -53,12 +56,20 @@ struct snd_usb_audio { struct list_head mixer_list; /* list of mixer interfaces */ int setup; /* from the 'device_setup' module param */ - int nrpacks; /* from the 'nrpacks' module param */ - int async_unlink; /* from the 'async_unlink' module param */ + bool autoclock; /* from the 'autoclock' module param */ struct usb_host_interface *ctrl_intf; /* the audio control interface */ }; +#define usb_audio_err(chip, fmt, args...) \ + dev_err(&(chip)->dev->dev, fmt, ##args) +#define usb_audio_warn(chip, fmt, args...) \ + dev_warn(&(chip)->dev->dev, fmt, ##args) +#define usb_audio_info(chip, fmt, args...) \ + dev_info(&(chip)->dev->dev, fmt, ##args) +#define usb_audio_dbg(chip, fmt, args...) \ + dev_dbg(&(chip)->dev->dev, fmt, ##args) + /* * Information about devices with broken descriptors */ @@ -70,9 +81,11 @@ struct snd_usb_audio { enum quirk_type { QUIRK_IGNORE_INTERFACE, QUIRK_COMPOSITE, + QUIRK_AUTODETECT, QUIRK_MIDI_STANDARD_INTERFACE, QUIRK_MIDI_FIXED_ENDPOINT, QUIRK_MIDI_YAMAHA, + QUIRK_MIDI_ROLAND, QUIRK_MIDI_MIDIMAN, QUIRK_MIDI_NOVATION, QUIRK_MIDI_RAW_BYTES, |
