aboutsummaryrefslogtreecommitdiffstats
path: root/include/sound/core.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sound/core.h')
-rw-r--r--include/sound/core.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/sound/core.h b/include/sound/core.h
index bab3ff457e40..b056ea925ecf 100644
--- a/include/sound/core.h
+++ b/include/sound/core.h
@@ -25,8 +25,8 @@
25#include <linux/sched.h> /* wake_up() */ 25#include <linux/sched.h> /* wake_up() */
26#include <linux/mutex.h> /* struct mutex */ 26#include <linux/mutex.h> /* struct mutex */
27#include <linux/rwsem.h> /* struct rw_semaphore */ 27#include <linux/rwsem.h> /* struct rw_semaphore */
28#include <linux/workqueue.h> /* struct workqueue_struct */
29#include <linux/pm.h> /* pm_message_t */ 28#include <linux/pm.h> /* pm_message_t */
29#include <linux/device.h>
30 30
31/* forward declarations */ 31/* forward declarations */
32#ifdef CONFIG_PCI 32#ifdef CONFIG_PCI
@@ -71,7 +71,6 @@ struct snd_device_ops {
71 int (*dev_free)(struct snd_device *dev); 71 int (*dev_free)(struct snd_device *dev);
72 int (*dev_register)(struct snd_device *dev); 72 int (*dev_register)(struct snd_device *dev);
73 int (*dev_disconnect)(struct snd_device *dev); 73 int (*dev_disconnect)(struct snd_device *dev);
74 int (*dev_unregister)(struct snd_device *dev);
75}; 74};
76 75
77struct snd_device { 76struct snd_device {
@@ -131,8 +130,8 @@ struct snd_card {
131 state */ 130 state */
132 spinlock_t files_lock; /* lock the files for this card */ 131 spinlock_t files_lock; /* lock the files for this card */
133 int shutdown; /* this card is going down */ 132 int shutdown; /* this card is going down */
133 int free_on_last_close; /* free in context of file_release */
134 wait_queue_head_t shutdown_sleep; 134 wait_queue_head_t shutdown_sleep;
135 struct work_struct free_workq; /* for free in workqueue */
136 struct device *dev; 135 struct device *dev;
137 136
138#ifdef CONFIG_PM 137#ifdef CONFIG_PM
@@ -188,6 +187,7 @@ struct snd_minor {
188 int device; /* device number */ 187 int device; /* device number */
189 const struct file_operations *f_ops; /* file operations */ 188 const struct file_operations *f_ops; /* file operations */
190 void *private_data; /* private data for f_ops->open */ 189 void *private_data; /* private data for f_ops->open */
190 struct class_device *class_dev; /* class device for sysfs */
191}; 191};
192 192
193/* sound.c */ 193/* sound.c */
@@ -202,6 +202,8 @@ int snd_register_device(int type, struct snd_card *card, int dev,
202 const char *name); 202 const char *name);
203int snd_unregister_device(int type, struct snd_card *card, int dev); 203int snd_unregister_device(int type, struct snd_card *card, int dev);
204void *snd_lookup_minor_data(unsigned int minor, int type); 204void *snd_lookup_minor_data(unsigned int minor, int type);
205int snd_add_device_sysfs_file(int type, struct snd_card *card, int dev,
206 const struct class_device_attribute *attr);
205 207
206#ifdef CONFIG_SND_OSSEMUL 208#ifdef CONFIG_SND_OSSEMUL
207int snd_register_oss_device(int type, struct snd_card *card, int dev, 209int snd_register_oss_device(int type, struct snd_card *card, int dev,
@@ -244,7 +246,7 @@ struct snd_card *snd_card_new(int idx, const char *id,
244 struct module *module, int extra_size); 246 struct module *module, int extra_size);
245int snd_card_disconnect(struct snd_card *card); 247int snd_card_disconnect(struct snd_card *card);
246int snd_card_free(struct snd_card *card); 248int snd_card_free(struct snd_card *card);
247int snd_card_free_in_thread(struct snd_card *card); 249int snd_card_free_when_closed(struct snd_card *card);
248int snd_card_register(struct snd_card *card); 250int snd_card_register(struct snd_card *card);
249int snd_card_info_init(void); 251int snd_card_info_init(void);
250int snd_card_info_done(void); 252int snd_card_info_done(void);