Changeset 695 for GPL/trunk/alsa-kernel/include/sound/control.h
- Timestamp:
- Aug 21, 2021, 3:35:34 AM (4 years ago)
- Location:
- GPL/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
GPL/trunk
- Property svn:mergeinfo changed
/GPL/branches/uniaud32-next merged: 691-694
- Property svn:mergeinfo changed
-
GPL/trunk/alsa-kernel/include/sound/control.h
r679 r695 25 25 /* internal flag for skipping validations */ 26 26 #ifdef CONFIG_SND_CTL_VALIDATION 27 #define SNDRV_CTL_ELEM_ACCESS_SKIP_CHECK (1 << 2 7)27 #define SNDRV_CTL_ELEM_ACCESS_SKIP_CHECK (1 << 24) 28 28 #define snd_ctl_skip_validation(info) \ 29 29 ((info)->access & SNDRV_CTL_ELEM_ACCESS_SKIP_CHECK) … … 32 32 #define snd_ctl_skip_validation(info) true 33 33 #endif 34 35 /* kernel only - LED bits */ 36 #define SNDRV_CTL_ELEM_ACCESS_LED_SHIFT 25 37 #define SNDRV_CTL_ELEM_ACCESS_LED_MASK (7<<25) /* kernel three bits - LED group */ 38 #define SNDRV_CTL_ELEM_ACCESS_SPK_LED (1<<25) /* kernel speaker (output) LED flag */ 39 #define SNDRV_CTL_ELEM_ACCESS_MIC_LED (2<<25) /* kernel microphone (input) LED flag */ 34 40 35 41 enum { … … 109 115 }; 110 116 117 struct snd_ctl_layer_ops { 118 struct snd_ctl_layer_ops *next; 119 const char *module_name; 120 void (*lregister)(struct snd_card *card); 121 void (*ldisconnect)(struct snd_card *card); 122 void (*lnotify)(struct snd_card *card, unsigned int mask, struct snd_kcontrol *kctl, unsigned int ioff); 123 }; 124 111 125 #define snd_ctl_file(n) list_entry(n, struct snd_ctl_file, list) 112 126 … … 116 130 117 131 void snd_ctl_notify(struct snd_card * card, unsigned int mask, struct snd_ctl_elem_id * id); 132 void snd_ctl_notify_one(struct snd_card * card, unsigned int mask, struct snd_kcontrol * kctl, unsigned int ioff); 118 133 119 134 struct snd_kcontrol *snd_ctl_new1(const struct snd_kcontrol_new * kcontrolnew, void * private_data); … … 124 139 int snd_ctl_remove_id(struct snd_card * card, struct snd_ctl_elem_id *id); 125 140 int snd_ctl_rename_id(struct snd_card * card, struct snd_ctl_elem_id *src_id, struct snd_ctl_elem_id *dst_id); 126 int snd_ctl_activate_id(struct snd_card *card, struct snd_ctl_elem_id *id, 127 int active); 141 int snd_ctl_activate_id(struct snd_card *card, struct snd_ctl_elem_id *id, int active); 128 142 struct snd_kcontrol *snd_ctl_find_numid(struct snd_card * card, unsigned int numid); 129 143 struct snd_kcontrol *snd_ctl_find_id(struct snd_card * card, struct snd_ctl_elem_id *id); … … 140 154 #define snd_ctl_unregister_ioctl_compat(fcn) 141 155 #endif 156 157 int snd_ctl_request_layer(const char *module_name); 158 void snd_ctl_register_layer(struct snd_ctl_layer_ops *lops); 159 void snd_ctl_disconnect_layer(struct snd_ctl_layer_ops *lops); 142 160 143 161 int snd_ctl_get_preferred_subdevice(struct snd_card *card, int type); … … 255 273 256 274 /* 275 * Control LED trigger layer 276 */ 277 #define SND_CTL_LAYER_MODULE_LED "snd-ctl-led" 278 279 #if IS_MODULE(CONFIG_SND_CTL_LED) 280 static inline int snd_ctl_led_request(void) { return snd_ctl_request_layer(SND_CTL_LAYER_MODULE_LED); } 281 #else 282 static inline int snd_ctl_led_request(void) { return 0; } 283 #endif 284 285 /* 257 286 * Helper functions for jack-detection controls 258 287 */
Note:
See TracChangeset
for help on using the changeset viewer.