Lines Matching defs:minor
70 static void snd_request_other(int minor)
74 switch (minor) {
86 * @minor: the minor number
89 * Checks that a minor device with the specified type is registered, and returns
93 * if an associated instance with the given minor number and type is found.
99 void *snd_lookup_minor_data(unsigned int minor, int type)
104 if (minor >= ARRAY_SIZE(snd_minors))
107 mreg = snd_minors[minor];
119 static struct snd_minor *autoload_device(unsigned int minor)
123 dev = SNDRV_MINOR_DEVICE(minor);
126 int card = SNDRV_MINOR_CARD(minor);
134 snd_request_other(minor);
137 return snd_minors[minor];
140 #define autoload_device(minor) NULL
145 unsigned int minor = iminor(inode);
150 if (minor >= ARRAY_SIZE(snd_minors))
153 mptr = snd_minors[minor];
155 mptr = autoload_device(minor);
180 int minor;
188 for (minor = 0; minor < ARRAY_SIZE(snd_minors); ++minor) {
190 if (SNDRV_MINOR_DEVICE(minor) == SNDRV_MINOR_CONTROL)
192 if (minor == SNDRV_MINOR_SEQUENCER ||
193 minor == SNDRV_MINOR_TIMER)
195 if (!snd_minors[minor])
196 return minor;
203 int minor;
208 minor = type;
213 minor = SNDRV_MINOR(card->number, type);
222 minor = SNDRV_MINOR(card->number, type + dev);
227 if (snd_BUG_ON(minor < 0 || minor >= SNDRV_OS_MINORS))
229 if (snd_minors[minor])
231 return minor;
253 int minor;
270 minor = snd_find_free_minor(type, card, dev);
271 if (minor < 0) {
272 err = minor;
277 device->devt = MKDEV(major, minor);
282 snd_minors[minor] = preg;
301 int minor;
305 for (minor = 0; minor < ARRAY_SIZE(snd_minors); ++minor) {
306 preg = snd_minors[minor];
308 snd_minors[minor] = NULL;
314 if (minor >= ARRAY_SIZE(snd_minors))
350 int minor;
354 for (minor = 0; minor < SNDRV_OS_MINORS; ++minor) {
355 mptr = snd_minors[minor];
361 minor, mptr->card, mptr->device,
365 minor, mptr->card,
368 snd_iprintf(buffer, "%3i: : %s\n", minor,