~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/sound/oss/sound_config.h

Version: ~ [ linux-5.4-rc3 ] ~ [ linux-5.3.6 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.79 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.149 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.196 ] ~ [ linux-4.8.17 ] ~ [ linux-4.7.10 ] ~ [ linux-4.6.7 ] ~ [ linux-4.5.7 ] ~ [ linux-4.4.196 ] ~ [ linux-4.3.6 ] ~ [ linux-4.2.8 ] ~ [ linux-4.1.52 ] ~ [ linux-4.0.9 ] ~ [ linux-3.19.8 ] ~ [ linux-3.18.140 ] ~ [ linux-3.17.8 ] ~ [ linux-3.16.75 ] ~ [ linux-3.15.10 ] ~ [ linux-3.14.79 ] ~ [ linux-3.13.11 ] ~ [ linux-3.12.74 ] ~ [ linux-3.11.10 ] ~ [ linux-3.10.108 ] ~ [ linux-3.9.11 ] ~ [ linux-3.8.13 ] ~ [ linux-3.7.10 ] ~ [ linux-3.6.11 ] ~ [ linux-3.5.7 ] ~ [ linux-3.4.113 ] ~ [ linux-3.3.8 ] ~ [ linux-3.2.102 ] ~ [ linux-3.1.10 ] ~ [ linux-3.0.101 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.5 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* sound_config.h
  2  *
  3  * A driver for sound cards, misc. configuration parameters.
  4  */
  5 /*
  6  * Copyright (C) by Hannu Savolainen 1993-1997
  7  *
  8  * OSS/Free for Linux is distributed under the GNU GENERAL PUBLIC LICENSE (GPL)
  9  * Version 2 (June 1991). See the "COPYING" file distributed with this software
 10  * for more info.
 11  */
 12 
 13 
 14 #ifndef  _SOUND_CONFIG_H_
 15 #define  _SOUND_CONFIG_H_
 16 
 17 #include <linux/fs.h>
 18 #include <linux/sound.h>
 19 
 20 #include "os.h"
 21 #include "soundvers.h"
 22 
 23 
 24 #ifndef SND_DEFAULT_ENABLE
 25 #define SND_DEFAULT_ENABLE      1
 26 #endif
 27 
 28 #ifndef MAX_REALTIME_FACTOR
 29 #define MAX_REALTIME_FACTOR     4
 30 #endif
 31 
 32 /*
 33  * Use always 64k buffer size. There is no reason to use shorter.
 34  */
 35 #undef DSP_BUFFSIZE
 36 #define DSP_BUFFSIZE            (64*1024)
 37 
 38 #ifndef DSP_BUFFCOUNT
 39 #define DSP_BUFFCOUNT           1       /* 1 is recommended. */
 40 #endif
 41 
 42 #define FM_MONO         0x388   /* This is the I/O address used by AdLib */
 43 
 44 #ifndef CONFIG_PAS_BASE
 45 #define CONFIG_PAS_BASE 0x388
 46 #endif
 47 
 48 /* SEQ_MAX_QUEUE is the maximum number of sequencer events buffered by the
 49    driver. (There is no need to alter this) */
 50 #define SEQ_MAX_QUEUE   1024
 51 
 52 #define SBFM_MAXINSTR           (256)   /* Size of the FM Instrument bank */
 53 /* 128 instruments for general MIDI setup and 16 unassigned      */
 54 
 55 #define SND_NDEVS       256     /* Number of supported devices */
 56 
 57 #define DSP_DEFAULT_SPEED       8000
 58 
 59 #define MAX_AUDIO_DEV   5
 60 #define MAX_MIXER_DEV   5
 61 #define MAX_SYNTH_DEV   5
 62 #define MAX_MIDI_DEV    6
 63 #define MAX_TIMER_DEV   4
 64 
 65 struct address_info {
 66         int io_base;
 67         int irq;
 68         int dma;
 69         int dma2;
 70         int always_detect;      /* 1=Trust me, it's there */
 71         char *name;
 72         int driver_use_1;       /* Driver defined field 1 */
 73         int driver_use_2;       /* Driver defined field 2 */
 74         int *osp;       /* OS specific info */
 75         int card_subtype;       /* Driver specific. Usually 0 */
 76         void *memptr;           /* Module memory chainer */
 77         int slots[6];           /* To remember driver slot ids */
 78 };
 79 
 80 #define SYNTH_MAX_VOICES        32
 81 
 82 struct voice_alloc_info {
 83                 int max_voice;
 84                 int used_voices;
 85                 int ptr;                /* For device specific use */
 86                 unsigned short map[SYNTH_MAX_VOICES]; /* (ch << 8) | (note+1) */
 87                 int timestamp;
 88                 int alloc_times[SYNTH_MAX_VOICES];
 89         };
 90 
 91 struct channel_info {
 92                 int pgm_num;
 93                 int bender_value;
 94                 int bender_range;
 95                 unsigned char controllers[128];
 96         };
 97 
 98 /*
 99  * Process wakeup reasons
100  */
101 #define WK_NONE         0x00
102 #define WK_WAKEUP       0x01
103 #define WK_TIMEOUT      0x02
104 #define WK_SIGNAL       0x04
105 #define WK_SLEEP        0x08
106 #define WK_SELECT       0x10
107 #define WK_ABORT        0x20
108 
109 #define OPEN_READ       PCM_ENABLE_INPUT
110 #define OPEN_WRITE      PCM_ENABLE_OUTPUT
111 #define OPEN_READWRITE  (OPEN_READ|OPEN_WRITE)
112 
113 static inline int translate_mode(struct file *file)
114 {
115         if (OPEN_READ == (__force int)FMODE_READ &&
116             OPEN_WRITE == (__force int)FMODE_WRITE)
117                 return (__force int)(file->f_mode & (FMODE_READ | FMODE_WRITE));
118         else
119                 return ((file->f_mode & FMODE_READ) ? OPEN_READ : 0) |
120                         ((file->f_mode & FMODE_WRITE) ? OPEN_WRITE : 0);
121 }
122 
123 #include "sound_calls.h"
124 #include "dev_table.h"
125 
126 #ifndef DEB
127 #define DEB(x)
128 #endif
129 
130 #ifndef DDB
131 #define DDB(x) do {} while (0)
132 #endif
133 
134 #ifndef MDB
135 #ifdef MODULE
136 #define MDB(x) x
137 #else
138 #define MDB(x)
139 #endif
140 #endif
141 
142 #define TIMER_ARMED     121234
143 #define TIMER_NOT_ARMED 1
144 
145 #define MAX_MEM_BLOCKS 1024
146 
147 #endif
148 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | Wiki (Japanese) | Wiki (English) | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

osdn.jp