Changeset 112


Ignore:
Timestamp:
May 31, 2007, 6:45:32 AM (18 years ago)
Author:
Brendan Oakley
Message:

Merged to Alsa 0.9.0rc1. Builds.

Location:
GPL/branches/alsa-resync1/alsa-kernel
Files:
45 edited

Legend:

Unmodified
Added
Removed
  • GPL/branches/alsa-resync1/alsa-kernel/core/info.c

    r92 r112  
    4343 *
    4444 */
     45static inline void dec_mod_count(struct module *module)
     46{
     47        if (module)
     48                __MOD_DEC_USE_COUNT(module);
     49}
    4550
    4651int snd_info_check_reserved_words(const char *str)
     
    5459        "detect",
    5560        "devices",
    56                 "oss-devices",
     61                "oss",
    5762        "cards",
    5863        "timers",
     
    126131
    127132static struct proc_dir_entry *snd_proc_root = NULL;
     133struct proc_dir_entry *snd_proc_dev = NULL;
    128134snd_info_entry_t *snd_seq_root = NULL;
    129135#ifdef CONFIG_SND_OSSEMUL
     
    643649        return -ENOMEM;
    644650    snd_proc_root = p;
     651        p = snd_create_proc_entry("dev", S_IFDIR | S_IRUGO | S_IXUGO, snd_proc_root);
     652        if (p == NULL)
     653                return -ENOMEM;
     654        snd_proc_dev = p;
    645655#ifdef CONFIG_SND_OSSEMUL
    646656    {
     
    697707            snd_info_unregister(snd_seq_root);
    698708#endif
     709#ifdef CONFIG_SND_OSSEMUL
     710                if (snd_oss_root)
     711                        snd_info_unregister(snd_oss_root);
     712#endif
     713                snd_remove_proc_entry(snd_proc_root, snd_proc_dev);
    699714        snd_remove_proc_entry(&proc_root, snd_proc_root);
    700715    }
  • GPL/branches/alsa-resync1/alsa-kernel/core/rtctimer.c

    r92 r112  
    1919 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
    2020 *
    21  *
    22  *================================================================
    23  * For enabling this timer, apply the patch file to your kernel.
    24  * The configure script checks the patch automatically.
    25  * The patches, rtc-xxx.dif, are found under utils/patches, where
    26  * xxx is the kernel version.
    27  *================================================================
    28  *
    2921 */
    3022
     
    3224#include <linux/init.h>
    3325#include <linux/time.h>
     26#include <linux/interrupt.h>
    3427#include <sound/core.h>
    3528#include <sound/timer.h>
     
    5649
    5750/*
    58  * The harware depenant description for this timer.
     51 * The hardware dependent description for this timer.
    5952 */
    6053static struct _snd_timer_hardware rtc_hw = {
     
    6962int rtctimer_freq = RTC_FREQ;           /* frequency */
    7063static snd_timer_t *rtctimer;
    71 static volatile int rtc_inc = 0;
     64static atomic_t rtc_inc = ATOMIC_INIT(0);
    7265static rtc_task_t rtc_task;
    7366
     
    8073rtctimer_open(snd_timer_t *t)
    8174{
     75        int err;
     76
     77        err = rtc_register(&rtc_task);
     78        if (err < 0)
     79                return err;
     80        t->private_data = &rtc_task;
    8281        MOD_INC_USE_COUNT;
    8382        return 0;
     
    8786rtctimer_close(snd_timer_t *t)
    8887{
     88        rtc_task_t *rtc = t->private_data;
     89        if (rtc) {
     90                rtc_unregister(rtc);
     91                t->private_data = NULL;
     92        }
    8993        MOD_DEC_USE_COUNT;
    9094        return 0;
     
    98102        rtc_control(rtc, RTC_IRQP_SET, rtctimer_freq);
    99103        rtc_control(rtc, RTC_PIE_ON, 0);
    100         rtc_inc = 0;
     104        atomic_set(&rtc_inc, 0);
    101105        return 0;
    102106}
     
    116120static void rtctimer_interrupt(void *private_data)
    117121{
    118         rtc_inc++;
     122        atomic_inc(&rtc_inc);
    119123#ifdef USE_TASKLET
    120124        tasklet_hi_schedule(&rtc_tq);
    121125#else
    122         snd_timer_interrupt((snd_timer_t*)private_data, rtc_inc);
    123         rtc_inc = 0;
     126        {
     127                int ticks = atomic_read(&rtc_inc);
     128                snd_timer_interrupt((snd_timer_t*)private_data, ticks);
     129                atomic_sub(ticks, &rtc_inc);
     130        }
    124131#endif /* USE_TASKLET */
    125132}
     
    129136{
    130137        snd_timer_t *timer = (snd_timer_t *)private_data;
     138        int ticks;
     139
    131140        snd_assert(timer != NULL, return);
    132141        do {
    133                 snd_timer_interrupt(timer, 1);
    134         } while (--rtc_inc > 0);
     142                ticks = atomic_read(&rtc_inc);
     143                snd_timer_interrupt(timer, ticks);
     144        } while (!atomic_sub_and_test(ticks, &rtc_inc));
    135145}
    136146#endif /* USE_TASKLET */
    137 
    138 static void rtctimer_private_free(snd_timer_t *timer)
    139 {
    140         rtc_task_t *rtc = timer->private_data;
    141         if (rtc)
    142                 rtc_unregister(rtc);
    143 }
    144147
    145148
     
    176179        timer->hw.resolution = NANO_SEC / rtctimer_freq;
    177180
    178         /* register RTC callback */
     181        /* set up RTC callback */
    179182        rtc_task.func = rtctimer_interrupt;
    180183        rtc_task.private_data = timer;
    181         err = rtc_register(&rtc_task);
    182         if (err < 0) {
    183                 snd_timer_global_free(timer);
    184                 return err;
    185         }
    186         timer->private_data = &rtc_task;
    187         timer->private_free = rtctimer_private_free;
    188184
    189185        err = snd_timer_global_register(timer);
     
    192188                return err;
    193189        }
    194         rtctimer = timer;
     190        rtctimer = timer; /* remember this */
    195191
    196192        return 0;
     
    207203
    208204/*
    209  * exported stuffs
     205 * exported stuff
    210206 */
    211207module_init(rtctimer_init)
  • GPL/branches/alsa-resync1/alsa-kernel/core/seq/makefile.os2

    r32 r112  
    3636FILE2    = seq.obj seq_lock.obj seq_clientmgr.obj seq_memory.obj seq_queue.obj
    3737FILE3    = seq_fifo.obj seq_prioq.obj seq_timer.obj
    38 FILE4    = seq_system.obj seq_ports.obj seq_info.obj seq_sync.obj
    39 FILE5    = seq_midi_clock.obj seq_mtc.obj seq_dtl.obj
     38FILE4    = seq_system.obj seq_ports.obj seq_info.obj
    4039FILELAST =
    4140FILES    = $(FILE0) $(FILE1) $(FILE2) $(FILE3) $(FILE4) $(FILE5) $(FILE6) $(FILE7) $(FILE8) $(FILE9) $(FILE10) $(FILE11) $(FILE12)
  • GPL/branches/alsa-resync1/alsa-kernel/core/sound.c

    r98 r112  
    550550EXPORT_SYMBOL(snd_verbose_printd);
    551551#endif
     552#if defined(CONFIG_SND_DEBUG) && !defined(CONFIG_SND_VERBOSE_PRINTK)
     553EXPORT_SYMBOL(snd_printd);
     554#endif
    552555/* wrappers */
    553556#ifdef CONFIG_SND_DEBUG_MEMORY
  • GPL/branches/alsa-resync1/alsa-kernel/include/sound/adriver.h

    r107 r112  
    106106#define need_resched() (current->need_resched)
    107107#endif
    108 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 5, 5) && !defined TARGET_OS2
     108#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 5, 4) && !defined TARGET_OS2
     109#include <linux/fs.h>
    109110static inline struct proc_dir_entry *PDE(const struct inode *inode)
    110111{
  • GPL/branches/alsa-resync1/alsa-kernel/include/sound/asoundef.h

    r96 r112  
    156156#define MIDI_CTL_MSB_BREATH             0x02
    157157#define MIDI_CTL_MSB_FOOT               0x04
    158 #define MIDI_CTL_MSB_PORTNAMENTO_TIME   0x05
     158#define MIDI_CTL_MSB_PORTAMENTO_TIME    0x05
    159159#define MIDI_CTL_MSB_DATA_ENTRY         0x06
    160160#define MIDI_CTL_MSB_MAIN_VOLUME        0x07
     
    172172#define MIDI_CTL_LSB_BREATH             0x22
    173173#define MIDI_CTL_LSB_FOOT               0x24
    174 #define MIDI_CTL_LSB_PORTNAMENTO_TIME   0x25
     174#define MIDI_CTL_LSB_PORTAMENTO_TIME    0x25
    175175#define MIDI_CTL_LSB_DATA_ENTRY         0x26
    176176#define MIDI_CTL_LSB_MAIN_VOLUME        0x27
     
    204204#define MIDI_CTL_GENERAL_PURPOSE7       0x52
    205205#define MIDI_CTL_GENERAL_PURPOSE8       0x53
    206 #define MIDI_CTL_PORNAMENTO_CONTROL     0x54
     206#define MIDI_CTL_PORTAMENTO_CONTROL     0x54
    207207#define MIDI_CTL_E1_REVERB_DEPTH        0x5b
    208208#define MIDI_CTL_E2_TREMOLO_DEPTH       0x5c
  • GPL/branches/alsa-resync1/alsa-kernel/include/sound/core.h

    r109 r112  
    322322int snd_task_name(struct task_struct *task, char *name, size_t size);
    323323#ifdef CONFIG_SND_VERBOSE_PRINTK
    324 int snd_verbose_printk(const char *file, int line, const char *format);
     324void snd_verbose_printk(const char *file, int line, const char *format, ...);
     325#endif
     326#if defined(CONFIG_SND_DEBUG) && defined(CONFIG_SND_VERBOSE_PRINTK)
     327void snd_verbose_printd(const char *file, int line, const char *format, ...);
     328#endif
     329#if defined(CONFIG_SND_DEBUG) && !defined(CONFIG_SND_VERBOSE_PRINTK)
     330void snd_printd(const char *format, ...);
    325331#endif
    326332
     
    364370
    365371#ifdef CONFIG_SND_VERBOSE_PRINTK
    366 #define snd_printk(format, args...) do { \
    367         printk(snd_verbose_printk(__FILE__, __LINE__, format) ? format + 3 : format, ##args); \
    368 } while (0)
    369 #else
    370 #define snd_printk(format, args...) do { \
    371         printk(format, ##args); \
    372 } while (0)
     372#define snd_printk(format, args...) \
     373        snd_verbose_printk(__FILE__, __LINE__, format, ##args)
     374#else
     375#define snd_printk(format, args...) \
     376        printk(format, ##args)
    373377#endif
    374378
     
    377381#define __ASTRING__(x) #x
    378382
    379 #define snd_printd(format, args...) snd_printk(format, ##args)
     383#ifdef CONFIG_SND_VERBOSE_PRINTK
     384#define snd_printd(format, args...) \
     385        snd_verbose_printd(__FILE__, __LINE__, format, ##args)
     386#endif
    380387#define snd_assert(expr, args...) do {\
    381388        if (!(expr)) {\
  • GPL/branches/alsa-resync1/alsa-kernel/include/sound/driver.h

    r109 r112  
    9494#endif
    9595
    96 /*
    97  * Temporary hack, until linux/init.h is fixed.
    98  */
    99 #include <linux/init.h>
    100 #ifndef __devexit_p
    101 #define __devexit_p(x) x
    102 #endif
    103 
    10496#endif /* __SOUND_DRIVER_H */
  • GPL/branches/alsa-resync1/alsa-kernel/include/sound/minors.h

    r96 r112  
    3232#define SNDRV_MINOR_HWDEP               4       /* 4 - 7 */
    3333#define SNDRV_MINOR_HWDEPS              4
    34 #define SNDRV_MINOR_RAWMIDI             8       /* 8 - 11 */
    35 #define SNDRV_MINOR_RAWMIDIS            4
     34#define SNDRV_MINOR_RAWMIDI             8       /* 8 - 15 */
     35#define SNDRV_MINOR_RAWMIDIS            8
    3636#define SNDRV_MINOR_PCM_PLAYBACK        16      /* 16 - 23 */
    3737#define SNDRV_MINOR_PCM_CAPTURE         24      /* 24 - 31 */
  • GPL/branches/alsa-resync1/alsa-kernel/include/sound/pcm_params.h

    r96 r112  
    2222 *
    2323 */
    24 
    25 #include <linux/bitops.h>
    2624
    2725extern int snd_pcm_hw_param_mask(snd_pcm_substream_t *pcm, snd_pcm_hw_params_t *params,
  • GPL/branches/alsa-resync1/alsa-kernel/isa/ad1816a/ad1816a.c

    r92 r112  
    333333                                            const struct isapnp_card_id *id)
    334334{
    335         static int dev = 0;
     335        static int dev;
    336336        int res;
    337337
  • GPL/branches/alsa-resync1/alsa-kernel/isa/ad1816a/ad1816a_lib.c

    r92 r112  
    2525#include <linux/init.h>
    2626#include <linux/slab.h>
     27#include <linux/ioport.h>
    2728#include <sound/core.h>
    2829#include <sound/ad1816a.h>
  • GPL/branches/alsa-resync1/alsa-kernel/isa/ad1848/ad1848_lib.c

    r92 r112  
    2626#include <linux/delay.h>
    2727#include <linux/slab.h>
     28#include <linux/ioport.h>
    2829#include <sound/core.h>
    2930#include <sound/ad1848.h>
     
    669670                        if (rev & 0x80) {
    670671                                chip->hardware = AD1848_HW_CS4248;
    671                         } else if (rev & 0x0a) {
    672                                 chip->hardware = AD1848_HW_CMI8330;
     672                        } else if ((rev & 0x0f) == 0x0a) {
     673                                snd_ad1848_out(chip, AD1848_MISC_INFO, 0x40);
     674                                for (i = 0; i < 16; ++i) {
     675                                        if (snd_ad1848_in(chip, i) != snd_ad1848_in(chip, i + 16)) {
     676                                                chip->hardware = AD1848_HW_CMI8330;
     677                                                break;
     678                                        }
     679                                }
     680                                snd_ad1848_out(chip, AD1848_MISC_INFO, 0x00);
    673681                        }
    674682                }
  • GPL/branches/alsa-resync1/alsa-kernel/isa/als100.c

    r92 r112  
    354354                                           const struct isapnp_card_id *id)
    355355{
    356         static int dev = 0;
     356        static int dev;
    357357        int res;
    358358
  • GPL/branches/alsa-resync1/alsa-kernel/isa/azt2320.c

    r92 r112  
    139139        /* PRO16V */
    140140        ISAPNP_AZT2320('A','Z','T',0x1008,0x1008,0x2001),
    141         /* --- */
     141        /* Aztech Sound Galaxy 16 */
    142142        ISAPNP_AZT2320('A','Z','T',0x2320,0x0001,0x0002),
    143143        /* Packard Bell Sound III 336 AM/SP */
  • GPL/branches/alsa-resync1/alsa-kernel/isa/cmi8330.c

    r92 r112  
    190190AD1848_SINGLE("Loud Playback Switch", 0, CMI8330_MUTEMUX, 6, 1, 1),
    191191AD1848_DOUBLE("PCM Playback Switch", 0, AD1848_LEFT_OUTPUT, AD1848_RIGHT_OUTPUT, 7, 7, 1, 1),
    192 AD1848_DOUBLE("PCM Playback Volume", 0, AD1848_LEFT_OUTPUT, AD1848_RIGHT_OUTPUT, 0, 0, 63, 0),
     192AD1848_DOUBLE("PCM Playback Volume", 0, AD1848_LEFT_OUTPUT, AD1848_RIGHT_OUTPUT, 0, 0, 63, 1),
    193193AD1848_DOUBLE("Line Playback Switch", 0, CMI8330_MUTEMUX, CMI8330_MUTEMUX, 4, 3, 1, 0),
    194194AD1848_DOUBLE("Line Playback Volume", 0, CMI8330_LINVOL, CMI8330_LINVOL, 4, 0, 15, 0),
     
    464464                                            const struct isapnp_card_id *id)
    465465{
    466         static int dev = 0;
     466        static int dev;
    467467        int res;
    468468
  • GPL/branches/alsa-resync1/alsa-kernel/isa/cs423x/cs4231_lib.c

    r92 r112  
    3333#include <linux/init.h>
    3434#include <linux/slab.h>
     35#include <linux/ioport.h>
    3536#include <sound/core.h>
    3637#include <sound/cs4231.h>
  • GPL/branches/alsa-resync1/alsa-kernel/isa/cs423x/cs4236.c

    r92 r112  
    7171                "{IBM,IntelliStation M Pro},"
    7272                "{Intel,Marlin Spike Mobo CS4235},"
     73                "{Intel PR440FX Onboard},"
    7374                "{Guillemot,MaxiSound 16 PnP},"
    7475                "{NewClear,3D},"
     
    237238        /* some uknown CS4236B */
    238239        ISAPNP_CS4232('C','S','C',0x0b35,0x0000,0x0010,0x0003),
     240        /* Intel PR440FX Onboard sound */
     241        ISAPNP_CS4232('C','S','C',0x0b36,0x0000,0x0010,0x0003),
    239242        /* CS4235 on mainboard without MPU */
    240243        ISAPNP_CS4232_WOMPU('C','S','C',0x1425,0x0100,0x0110),
     
    326329        if (snd_port[dev] != SNDRV_AUTO_PORT)
    327330                isapnp_resource_change(&pdev->resource[0], snd_port[dev], 4);
    328         if (snd_fm_port[dev] != SNDRV_AUTO_PORT)
     331        if (snd_fm_port[dev] != SNDRV_AUTO_PORT && snd_fm_port[dev] >= 0)
    329332                isapnp_resource_change(&pdev->resource[1], snd_fm_port[dev], 4);
    330333        if (snd_sb_port[dev] != SNDRV_AUTO_PORT)
     
    341344        }
    342345        snd_port[dev] = pdev->resource[0].start;
    343         snd_fm_port[dev] = pdev->resource[1].start;
     346        if (snd_fm_port[dev] >= 0)
     347                snd_fm_port[dev] = pdev->resource[1].start;
    344348        snd_sb_port[dev] = pdev->resource[2].start;
    345349        snd_irq[dev] = pdev->irq_resource[0].start;
     
    366370        snd_printdd("isapnp CTRL: control port=0x%lx\n", snd_cport[dev]);
    367371        /* MPU initialization */
    368         if (acard->mpu) {
     372        if (acard->mpu && snd_mpu_port[dev] >= 0) {
    369373                pdev = acard->mpu;
    370374                if (pdev->prepare(pdev) < 0) {
     
    375379                if (snd_mpu_port[dev] != SNDRV_AUTO_PORT)
    376380                        isapnp_resource_change(&pdev->resource[0], snd_mpu_port[dev], 2);
    377                 if (snd_mpu_irq[dev] != SNDRV_AUTO_IRQ)
     381                if (snd_mpu_irq[dev] != SNDRV_AUTO_IRQ && snd_mpu_irq[dev] >= 0)
    378382                        isapnp_resource_change(&pdev->irq_resource[0], snd_mpu_irq[dev], 1);
    379383                if (pdev->activate(pdev)<0) {
     
    383387                } else {
    384388                        snd_mpu_port[dev] = pdev->resource[0].start;
    385                         if (pdev->irq_resource[0].flags & IORESOURCE_IRQ) {
    386                         snd_mpu_irq[dev] = pdev->irq_resource[0].start;
     389                        if ((pdev->irq_resource[0].flags & IORESOURCE_IRQ) &&
     390                            snd_mpu_irq[dev] >= 0) {
     391                                snd_mpu_irq[dev] = pdev->irq_resource[0].start;
    387392                        } else {
    388393                                snd_mpu_irq[dev] = -1;  /* disable interrupt */
     
    538543        }
    539544
    540         if (snd_mpu_irq[dev] >= 0 && snd_mpu_irq[dev] != SNDRV_AUTO_IRQ) {
     545        if (snd_mpu_port[dev] != SNDRV_AUTO_PORT) {
    541546                if (snd_mpu401_uart_new(card, 0, MPU401_HW_CS4232,
    542547                                        snd_mpu_port[dev], 0,
     
    566571                                           const struct isapnp_card_id *id)
    567572{
    568         static int dev = 0;
     573        static int dev;
    569574        int res;
    570575
  • GPL/branches/alsa-resync1/alsa-kernel/isa/dt0197h.c

    r92 r112  
    321321                                            const struct isapnp_card_id *id)
    322322{
    323         static int dev = 0;
     323        static int dev;
    324324        int res;
    325325
  • GPL/branches/alsa-resync1/alsa-kernel/isa/es1688/es1688.c

    r92 r112  
    170170static int __init snd_audiodrive_legacy_auto_probe(unsigned long port)
    171171{
    172         static int dev = 0;
     172        static int dev;
    173173        int res;
    174174       
  • GPL/branches/alsa-resync1/alsa-kernel/isa/es1688/es1688_lib.c

    r92 r112  
    2626#include <linux/delay.h>
    2727#include <linux/slab.h>
     28#include <linux/ioport.h>
    2829#include <sound/core.h>
    2930#include <sound/es1688.h>
  • GPL/branches/alsa-resync1/alsa-kernel/isa/es18xx.c

    r92 r112  
    23812381static int __init snd_audiodrive_probe_legacy_port(unsigned long port)
    23822382{
    2383         static int dev = 0;
     2383        static int dev;
    23842384        int res;
    23852385
     
    24052405                                               const struct isapnp_card_id *id)
    24062406{
    2407         static int dev = 0;
     2407        static int dev;
    24082408        int res;
    24092409
  • GPL/branches/alsa-resync1/alsa-kernel/isa/gus/gus_main.c

    r32 r112  
    1616 *   You should have received a copy of the GNU General Public License
    1717 *   along with this program; if not, write to the Free Software
    18  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
     18 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
    1919 *
    2020 */
    2121
    22 #define SNDRV_MAIN_OBJECT_FILE
    2322#include <sound/driver.h>
     23#include <asm/dma.h>
     24#include <linux/init.h>
     25#include <linux/delay.h>
     26#include <linux/slab.h>
     27#include <linux/ioport.h>
     28#include <sound/core.h>
    2429#include <sound/gus.h>
    2530#include <sound/control.h>
    2631
     32MODULE_AUTHOR("Jaroslav Kysela <perex@suse.cz>");
     33MODULE_DESCRIPTION("Routines for Gravis UltraSound soundcards");
     34MODULE_LICENSE("GPL");
     35
    2736#define chip_t snd_gus_card_t
    2837
    2938static int snd_gus_init_dma_irq(snd_gus_card_t * gus, int latches);
     39
     40static inline void dec_mod_count(struct module *module)
     41{
     42        if (module)
     43                __MOD_DEC_USE_COUNT(module);
     44}
    3045
    3146int snd_gus_use_inc(snd_gus_card_t * gus)
     
    110125        if (gus->gf1.res_port2 == NULL)
    111126                goto __hw_end;
    112 #ifdef CONFIG_SND_SEQUENCER
     127#if defined(CONFIG_SND_SEQUENCER) || defined(CONFIG_SND_SEQUENCER_MODULE)
    113128        if (gus->seq_dev) {
    114129                snd_device_free(gus->card, gus->seq_dev);
     
    119134        snd_gus_init_dma_irq(gus, 0);
    120135      __hw_end:
    121         if (gus->gf1.res_port1)
     136        if (gus->gf1.res_port1) {
    122137                release_resource(gus->gf1.res_port1);
    123         if (gus->gf1.res_port2)
     138                kfree_nocheck(gus->gf1.res_port1);
     139        }
     140        if (gus->gf1.res_port2) {
    124141                release_resource(gus->gf1.res_port2);
     142                kfree_nocheck(gus->gf1.res_port2);
     143        }
    125144        if (gus->gf1.irq >= 0)
    126145                free_irq(gus->gf1.irq, (void *) gus);
     
    440459        if ((err = snd_gus_init_dma_irq(gus, 1)) < 0)
    441460                return err;
    442 #ifdef CONFIG_SND_SEQUENCER
     461#if defined(CONFIG_SND_SEQUENCER) || defined(CONFIG_SND_SEQUENCER_MODULE)
    443462        if (snd_seq_device_new(gus->card, 1, SNDRV_SEQ_DEV_ID_GUS,
    444463                               sizeof(snd_gus_card_t*), &gus->seq_dev) >= 0) {
  • GPL/branches/alsa-resync1/alsa-kernel/isa/gus/gusclassic.c

    r92 r112  
    230230static int __init snd_gusclassic_legacy_auto_probe(unsigned long port)
    231231{
    232         static int dev = 0;
     232        static int dev;
    233233        int res;
    234234
  • GPL/branches/alsa-resync1/alsa-kernel/isa/gus/gusextreme.c

    r92 r112  
    360360static int __init snd_gusextreme_legacy_auto_probe(unsigned long port)
    361361{
    362         static int dev = 0;
     362        static int dev;
    363363        int res;
    364364
  • GPL/branches/alsa-resync1/alsa-kernel/isa/gus/gusmax.c

    r92 r112  
    366366static int __init snd_gusmax_legacy_auto_probe(unsigned long port)
    367367{
    368         static int dev = 0;
     368        static int dev;
    369369        int res;
    370370
  • GPL/branches/alsa-resync1/alsa-kernel/isa/gus/interwave.c

    r92 r112  
    912912static int __init snd_interwave_probe_legacy_port(unsigned long port)
    913913{
    914         static int dev = 0;
     914        static int dev;
    915915        int res;
    916916
     
    936936                                              const struct isapnp_card_id *id)
    937937{
    938         static int dev = 0;
     938        static int dev;
    939939        int res;
    940940
  • GPL/branches/alsa-resync1/alsa-kernel/isa/opl3sa2.c

    r106 r112  
    194194        /* Yamaha OPL3-SA3 (integrated on Intel's Pentium II AL440LX motherboard) */
    195195        ISAPNP_OPL3SA2('Y','M','H',0x0030,0x0021),
    196         /* ??? */
     196        /* Yamaha OPL3-SA2 */
    197197        ISAPNP_OPL3SA2('Y','M','H',0x0800,0x0021),
    198198        /* NeoMagic MagicWave 3DX */
     
    881881                                            const struct isapnp_card_id *id)
    882882{
    883         static int dev = 0;
     883        static int dev;
    884884        int res;
    885885
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sb/emu8000.c

    r32 r112  
    1818 *   You should have received a copy of the GNU General Public License
    1919 *   along with this program; if not, write to the Free Software
    20  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
    21  */
    22 
    23 #define SNDRV_MAIN_OBJECT_FILE
     20 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
     21 */
     22
     23#define __NO_VERSION__
     24#include <sound/driver.h>
     25#include <linux/wait.h>
     26#include <linux/sched.h>
     27#include <linux/slab.h>
     28#include <linux/ioport.h>
     29#include <sound/core.h>
    2430#include <sound/emu8000.h>
    2531#include <sound/emu8000_reg.h>
     32#include <asm/io.h>
     33#include <asm/uaccess.h>
     34#include <linux/init.h>
    2635#include <sound/control.h>
    2736#include <sound/initval.h>
    28 
    29 MODULE_CLASSES("{sound}");
    30 MODULE_AUTHOR("Takashi Iwai, Steve Ratcliffe");
    3137
    3238/*
     
    124130/*
    125131 */
    126 static void /*__init*/
     132static void __init
    127133snd_emu8000_read_wait(emu8000_t *emu)
    128134{
     
    137143/*
    138144 */
    139 static void /*__init*/
     145static void __init
    140146snd_emu8000_write_wait(emu8000_t *emu)
    141147{
     
    151157 * detect a card at the given port
    152158 */
    153 static int /*__init*/
     159static int __init
    154160snd_emu8000_detect(emu8000_t *emu)
    155161{
     
    177183 * intiailize audio channels
    178184 */
    179 static void /*__init*/
     185static void __init
    180186init_audio(emu8000_t *emu)
    181187{
     
    218224 * initialize DMA address
    219225 */
    220 static void /*__init*/
     226static void __init
    221227init_dma(emu8000_t *emu)
    222228{
     
    322328 * is meant to work
    323329 */
    324 static void /*__init*/
     330static void __init
    325331send_array(emu8000_t *emu, unsigned short *data, int size)
    326332{
     
    346352 * initialisation sequence in the adip.
    347353 */
    348 static void /*__init*/
     354static void __init
    349355init_arrays(emu8000_t *emu)
    350356{
     
    373379 * reallocating between read and write.
    374380 */
    375 static void /*__init*/
     381static void __init
    376382size_dram(emu8000_t *emu)
    377383{
     
    499505 * The main initialization routine.
    500506 */
    501 static void /*__init*/
     507static void __init
    502508snd_emu8000_init_hw(emu8000_t *emu)
    503509{
     
    653659        soundfont_chorus_fx_t rec;
    654660        if (mode < SNDRV_EMU8000_CHORUS_PREDEFINED || mode >= SNDRV_EMU8000_CHORUS_NUMBERS) {
    655                 snd_printk("illegal chorus mode %d for uploading\n", mode);
     661                snd_printk(KERN_WARNING "illegal chorus mode %d for uploading\n", mode);
    656662                return -EINVAL;
    657663        }
     
    781787
    782788        if (mode < SNDRV_EMU8000_REVERB_PREDEFINED || mode >= SNDRV_EMU8000_REVERB_NUMBERS) {
    783                 snd_printk("illegal reverb mode %d for uploading\n", mode);
     789                snd_printk(KERN_WARNING "illegal reverb mode %d for uploading\n", mode);
    784790                return -EINVAL;
    785791        }
     
    10851091 * create and attach mixer elements for WaveTable treble/bass controls
    10861092 */
    1087 static int /*__init*/
     1093static int __init
    10881094snd_emu8000_create_mixer(snd_card_t *card, emu8000_t *emu)
    10891095{
     
    11151121static int snd_emu8000_free(emu8000_t *hw)
    11161122{
    1117         if (hw->res_port1)
     1123        if (hw->res_port1) {
    11181124                release_resource(hw->res_port1);
    1119         if (hw->res_port2)
     1125                kfree_nocheck(hw->res_port1);
     1126        }
     1127        if (hw->res_port2) {
    11201128                release_resource(hw->res_port2);
    1121         if (hw->res_port3)
     1129                kfree_nocheck(hw->res_port2);
     1130        }
     1131        if (hw->res_port3) {
    11221132                release_resource(hw->res_port3);
     1133                kfree_nocheck(hw->res_port3);
     1134        }
    11231135        snd_magic_kfree(hw);
    11241136        return 0;
     
    11361148 * initialize and register emu8000 synth device.
    11371149 */
    1138 /*exported*/ int
     1150int __init
    11391151snd_emu8000_new(snd_card_t *card, int index, long port, int seq_ports, snd_seq_device_t **awe_ret)
    11401152{
     
    12131225 */
    12141226
    1215 EXPORT_SYMBOL(snd_emu8000_new);
    12161227EXPORT_SYMBOL(snd_emu8000_poke);
    12171228EXPORT_SYMBOL(snd_emu8000_peek);
     
    12251236EXPORT_SYMBOL(snd_emu8000_update_reverb_mode);
    12261237EXPORT_SYMBOL(snd_emu8000_update_equalizer);
    1227 
    1228 /*
    1229  *  INIT part
    1230  */
    1231 
    1232 static int __init alsa_emu8000_init(void)
    1233 {
    1234         return 0;
    1235 }
    1236 
    1237 static void __exit alsa_emu8000_exit(void)
    1238 {
    1239 }
    1240 
    1241 module_init(alsa_emu8000_init)
    1242 module_exit(alsa_emu8000_exit)
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sb/es968.c

    r92 r112  
    237237                                          const struct isapnp_card_id *id)
    238238{
    239     static int dev = 0;
     239        static int dev;
    240240    int res;
    241241
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sb/sb16.c

    r92 r112  
    589589    static int __init snd_sb16_probe_legacy_port(unsigned long port)
    590590    {
    591         static int dev = 0;
     591        static int dev;
    592592        int res;
    593593
     
    613613                                             const struct isapnp_card_id *id)
    614614    {
    615         static int dev = 0;
     615        static int dev;
    616616        int res;
    617617
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sb/sb16_main.c

    r92 r112  
    210210#define snd_sb16_csp_playback_prepare(chip, runtime)    /*nop*/
    211211#define snd_sb16_csp_capture_prepare(chip, runtime)     /*nop*/
    212 #define snd_sb16_csp_update(chip)               /*nop*/
     212#define snd_sb16_csp_update(chip)                       /*nop*/
    213213#define snd_sb16_csp_playback_open(chip, runtime)       /*nop*/
    214 #define snd_sb16_csp_playback_close(chip)       /*nop*/
     214#define snd_sb16_csp_playback_close(chip)               /*nop*/
    215215#define snd_sb16_csp_capture_open(chip, runtime)        /*nop*/
    216 #define snd_sb16_csp_capture_close(chip)        /*nop*/
     216#define snd_sb16_csp_capture_close(chip)                /*nop*/
    217217#endif
    218218
     
    825825        }
    826826    }
    827     if (chip->dma16 >= 0) {
     827        if (chip->dma16 >= 0 && chip->dma16 != chip->dma8) {
    828828        switch (chip->dma16) {
    829829        case 5:
     
    940940    snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_CAPTURE, &snd_sb16_capture_ops);
    941941
     942        if (chip->dma16 >= 0 && chip->dma8 != chip->dma16)
    942943    snd_ctl_add(card, snd_ctl_new1(&snd_sb16_dma_control, chip));
     944        else
     945                pcm->info_flags = SNDRV_PCM_INFO_HALF_DUPLEX;
    943946
    944947        snd_pcm_lib_preallocate_isa_pages_for_all(pcm, 64*1024, 128*1024);
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sb/sb8.c

    r92 r112  
    2323#include <linux/init.h>
    2424#include <linux/slab.h>
     25#include <linux/ioport.h>
    2526#include <sound/core.h>
    2627#include <sound/sb.h>
     
    183184static int __init snd_card_sb8_legacy_auto_probe(unsigned long port)
    184185{
    185     static int dev = 0;
     186        static int dev;
    186187    int res;
    187188
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sb/sb_common.c

    r92 r112  
    2727#include <linux/init.h>
    2828#include <linux/slab.h>
     29#include <linux/ioport.h>
    2930#include <sound/core.h>
    3031#include <sound/sb.h>
     
    183184        free_dma(chip->dma8);
    184185    }
    185     if (chip->dma16 >= 0) {
     186        if (chip->dma16 >= 0 && chip->dma16 != chip->dma8) {
    186187        disable_dma(chip->dma16);
    187188        free_dma(chip->dma16);
     
    255256    }
    256257    chip->dma8 = dma8;
    257     if (dma16 >= 0 && request_dma(dma16, "SoundBlaster - 16bit")) {
     258        if (dma16 >= 0) {
     259                if (hardware != SB_HW_ALS100 && (dma16 < 5 || dma16 > 7)) {
     260                        /* no duplex */
     261                        dma16 = -1;
     262                } else if (request_dma(dma16, "SoundBlaster - 16bit")) {
    258263        snd_sbdsp_free(chip);
    259264        return -EBUSY;
     265                }
    260266    }
    261267    chip->dma16 = dma16;
  • GPL/branches/alsa-resync1/alsa-kernel/isa/sgalaxy.c

    r92 r112  
    120120        int tmp, tmp1;
    121121
    122         unsigned int flags;
     122        unsigned long flags;
    123123
    124124        if ((tmp = inb(port + 3)) == 0xff)
  • GPL/branches/alsa-resync1/alsa-kernel/isa/wavefront/wavefront.c

    r92 r112  
    5959
    6060MODULE_PARM(snd_index, "1-" __MODULE_STRING(SNDRV_CARDS) "i");
    61 MODULE_PARM_SYNTAX(snd_index, "Index value for WaveFront soundcard.");
     61MODULE_PARM_DESC(snd_index, "Index value for WaveFront soundcard.");
     62MODULE_PARM_SYNTAX(snd_index, SNDRV_INDEX_DESC);
    6263MODULE_PARM(snd_id, "1-" __MODULE_STRING(SNDRV_CARDS) "s");
    6364MODULE_PARM_DESC(snd_id, "ID string for WaveFront soundcard.");
     
    100101MODULE_PARM(snd_use_cs4232_midi, "1-" __MODULE_STRING(SNDRV_CARDS) "i");
    101102MODULE_PARM_DESC(snd_use_cs4232_midi, "Use CS4232 MPU-401 interface (inaccessibly located inside your computer)");
    102 MODULE_PARM_SYNTAX(snd_use_cs4232_midi, SNDRV_ENABLED ",allows use of CS4323 MPU-401 interface");
     103MODULE_PARM_SYNTAX(snd_use_cs4232_midi, SNDRV_ENABLED "," SNDRV_BOOLEAN_FALSE_DESC);
    103104
    104105static snd_card_t *snd_wavefront_cards[SNDRV_CARDS] = SNDRV_DEFAULT_PTR;
     
    702703                                              const struct isapnp_card_id *id)
    703704{
    704         static int dev = 0;
     705        static int dev;
    705706        int res;
    706707
  • GPL/branches/alsa-resync1/alsa-kernel/isa/wavefront/wavefront_fx.c

    r32 r112  
    11/*
    2  *  Copyright (c) 1998-1999 by Paul Barton-Davis <pbd@op.net>
     2 *  Copyright (c) 1998-2002 by Paul Davis <pbd@op.net>
    33 *
    44 *  This program is free software; you can redistribute it and/or modify
     
    1414 *  You should have received a copy of the GNU General Public License
    1515 *  along with this program; if not, write to the Free Software
    16  *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
     16 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
    1717 */
    1818
    19 #define SNDRV_MAIN_OBJECT_FILE
     19#define __NO_VERSION__
    2020#include <sound/driver.h>
     21#include <asm/io.h>
     22#include <linux/init.h>
     23#include <linux/time.h>
     24#include <linux/wait.h>
     25#include <sound/core.h>
    2126#include <sound/snd_wavefront.h>
    2227#include <sound/yss225.h>
    2328#include <sound/initval.h>
    2429
    25 MODULE_AUTHOR("Paul Barton-Davis <pbd@op.net>");
    26 MODULE_DESCRIPTION("ALSA driver for Turtle Beach Tropez+ YSS225 FX Processor");
    27 MODULE_CLASSES("{sound}");
    28 
    2930/* Control bits for the Load Control Register
    3031 */
     
    3334#define FX_MSB_TRANSFER 0x02    /* transfer after DSP MSB byte written */
    3435#define FX_AUTO_INCR    0x04    /* auto-increment DSP address after transfer */
     36
     37static inline void
     38dec_mod_count(struct module *module)
     39{
     40        if (module)
     41                __MOD_DEC_USE_COUNT(module);
     42}
    3543
    3644static int
     
    242250
    243251
    244 int
     252int __init
    245253snd_wavefront_fx_start (snd_wavefront_t *dev)
    246254
     
    699707/* wierd stuff, derived from port I/O tracing with dosemu */
    700708
    701 unsigned char page_zero[] = {
     709static unsigned char page_zero[] __initdata = {
    7027100x01, 0x7c, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf5, 0x00,
    7037110x11, 0x00, 0x20, 0x00, 0x32, 0x00, 0x40, 0x00, 0x13, 0x00, 0x00,
     
    726734};   
    727735
    728 unsigned char page_one[] = {
     736static unsigned char page_one[] __initdata = {
    7297370x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x19, 0x00,
    7307380x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0xd8, 0x00, 0x00,
     
    753761};
    754762
    755 unsigned char page_two[] = {
     763static unsigned char page_two[] __initdata = {
    7567640xc4, 0x00, 0x44, 0x07, 0x44, 0x00, 0x40, 0x25, 0x01, 0x06, 0xc4,
    7577650x07, 0x40, 0x25, 0x01, 0x00, 0x46, 0x46, 0x00, 0x00, 0x00, 0x00,
     
    768776};
    769777
    770 unsigned char page_three[] = {
     778static unsigned char page_three[] __initdata = {
    7717790x07, 0x40, 0x00, 0x00, 0x00, 0x47, 0x00, 0x40, 0x00, 0x40, 0x06,
    7727800x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    783791};
    784792
    785 unsigned char page_four[] = {
     793static unsigned char page_four[] __initdata = {
    7867940x63, 0x03, 0x26, 0x02, 0x2c, 0x00, 0x24, 0x00, 0x2e, 0x02, 0x02,
    7877950x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    798806};
    799807
    800 unsigned char page_six[] = {
     808static unsigned char page_six[] __initdata = {
    8018090x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x04, 0x00, 0x00, 0x06, 0x00,
    8028100x00, 0x08, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0e,
     
    819827};
    820828
    821 unsigned char page_seven[] = {
     829static unsigned char page_seven[] __initdata = {
    8228300x0f, 0xff, 0x00, 0x00, 0x08, 0x00, 0x08, 0x00, 0x02, 0x00, 0x00,
    8238310x00, 0x00, 0x00, 0x0f, 0xff, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00,
     
    846854};
    847855
    848 unsigned char page_zero_v2[] = {
     856static unsigned char page_zero_v2[] __initdata = {
    8498570x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    8508580x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    858866};
    859867
    860 unsigned char page_one_v2[] = {
     868static unsigned char page_one_v2[] __initdata = {
    8618690x01, 0xc0, 0x01, 0xfa, 0x00, 0x1a, 0x00, 0x00, 0x00, 0x00, 0x00,
    8628700x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    870878};
    871879
    872 unsigned char page_two_v2[] = {
     880static unsigned char page_two_v2[] __initdata = {
    8738810x46, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    8748820x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    8778850x00, 0x00, 0x00, 0x00
    878886};
    879 unsigned char page_three_v2[] = {
     887static unsigned char page_three_v2[] __initdata = {
    8808880x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    8818890x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    8848920x00, 0x00, 0x00, 0x00
    885893};
    886 unsigned char page_four_v2[] = {
     894static unsigned char page_four_v2[] __initdata = {
    8878950x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    8888960x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    892900};
    893901
    894 unsigned char page_seven_v2[] = {
     902static unsigned char page_seven_v2[] __initdata = {
    8959030x0f, 0xff, 0x0f, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    8969040x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     
    9039110x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
    904912};
    905 unsigned char mod_v2[] = {
     913
     914static unsigned char mod_v2[] __initdata = {
    9069150x01, 0x00, 0x02, 0x00, 0x01, 0x01, 0x02, 0x00, 0x01, 0x02, 0x02,
    9079160x00, 0x01, 0x03, 0x02, 0x00, 0x01, 0x04, 0x02, 0x00, 0x01, 0x05,
     
    9339420x06, 0x02, 0x01, 0x01, 0x07, 0x02, 0x01
    934943};
    935 unsigned char coefficients[] = {
     944static unsigned char coefficients[] __initdata = {
    9369450x07, 0x46, 0x00, 0x00, 0x07, 0x49, 0x00, 0x00, 0x00, 0x4b, 0x03,
    9379460x11, 0x00, 0x4d, 0x01, 0x32, 0x07, 0x46, 0x00, 0x00, 0x07, 0x49,
     
    9699780xba
    970979};
    971 unsigned char coefficients2[] = {
     980static unsigned char coefficients2[] __initdata = {
    9729810x07, 0x46, 0x00, 0x00, 0x07, 0x49, 0x00, 0x00, 0x07, 0x45, 0x0f,
    9739820xff, 0x07, 0x48, 0x0f, 0xff, 0x07, 0x7b, 0x04, 0xcc, 0x07, 0x7d,
     
    9769850x07, 0x4a, 0x00, 0x00, 0x07, 0x4c, 0x00, 0x00, 0x07, 0x4e, 0x00, 0x00
    977986};
    978 unsigned char coefficients3[] = {
     987static unsigned char coefficients3[] __initdata = {
    9799880x00, 0x00, 0x00, 0x00, 0x00, 0x28, 0x00, 0x28, 0x00, 0x51, 0x00,
    9809890x51, 0x00, 0x7a, 0x00, 0x7a, 0x00, 0xa3, 0x00, 0xa3, 0x00, 0xcc,
     
    10161025};
    10171026
    1018 EXPORT_SYMBOL(snd_wavefront_fx_start);
    1019 EXPORT_SYMBOL(snd_wavefront_fx_detect);
    1020 EXPORT_SYMBOL(snd_wavefront_fx_ioctl);
    1021 EXPORT_SYMBOL(snd_wavefront_fx_open);
    1022 EXPORT_SYMBOL(snd_wavefront_fx_release);
    1023 
    1024 static int __init alsa_wavefront_fx_init(void)
    1025 {
    1026         return 0;
    1027 }
    1028 
    1029 static void __exit alsa_wavefront_fx_exit(void)
    1030 {
    1031 }
    1032 
    1033 module_init(alsa_wavefront_fx_init)
    1034 module_exit(alsa_wavefront_fx_exit)
  • GPL/branches/alsa-resync1/alsa-kernel/isa/wavefront/wavefront_midi.c

    r32 r112  
    473473}
    474474
    475 int
     475int __init
    476476snd_wavefront_midi_start (snd_wavefront_card_t *card)
    477477
  • GPL/branches/alsa-resync1/alsa-kernel/isa/wavefront/wavefront_synth.c

    r32 r112  
    2121 */
    2222
    23 #define SNDRV_MAIN_OBJECT_FILE
     23#define __NO_VERSION__
    2424#include <sound/driver.h>
     25#include <asm/io.h>
     26#include <linux/interrupt.h>
     27#include <linux/init.h>
     28#include <linux/delay.h>
     29#include <linux/time.h>
     30#include <linux/wait.h>
     31#include <sound/core.h>
    2532#include <sound/snd_wavefront.h>
    2633#include <sound/initval.h>
     
    7885                              start running.
    7986                           */
    80 MODULE_AUTHOR("Paul Barton-Davis <pbd@op.net>");
    81 MODULE_DESCRIPTION("ALSA driver for Turtle Beach WaveFront ICS2215 Synth");
    82 MODULE_CLASSES("{sound}");
    8387MODULE_PARM(wf_raw,"i");
    8488MODULE_PARM_DESC(wf_raw, "if non-zero, assume that we need to boot the OS");
     
    101105MODULE_PARM(osrun_time,"i");
    102106MODULE_PARM_DESC(osrun_time, "how many seconds to wait for the ICS2115 OS");
    103 
    104 /*
    105  *      This sucks, hopefully it'll get standardised
    106  */
    107 
    108 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,2,18) && LINUX_VERSION_CODE < KERNEL_VERSION(2,3,0)
    109 #define loops_per_sec loops_per_jiffy*HZ
    110 #elif LINUX_VERSION_CODE == KERNEL_VERSION(2,4,0) && defined(I_DIRTY_PAGES) /* linux/fs.h */
    111 #define loops_per_sec loops_per_jiffy*HZ
    112 #elif LINUX_VERSION_CODE > KERNEL_VERSION(2,4,0)
    113 #define loops_per_sec loops_per_jiffy*HZ
    114 #endif
    115  
    116 #if defined(__alpha__) || defined(__powerpc__)
    117 #ifdef __SMP__
    118 #define LOOPS_PER_SEC   (cpu_data[smp_processor_id()].loops_per_sec)
    119 #else
    120 #define LOOPS_PER_SEC   (loops_per_sec)
    121 #endif
    122 #endif
    123 
    124 #if defined(__i386__)
    125 #define LOOPS_PER_SEC   (current_cpu_data.loops_per_sec)
    126 #endif
    127107 
    128108/* if WF_DEBUG not defined, no run-time debugging messages will
     
    255235};
    256236
     237static inline void
     238dec_mod_count(struct module *module)
     239{
     240        if (module)
     241                __MOD_DEC_USE_COUNT(module);
     242}
     243
    257244static const char *
    258245wavefront_errorstr (int errnum)
     
    307294{
    308295        int             i;
    309         static int      short_loop_cnt = 0;
    310 
    311         /* Compute the loop count that lets us sleep for about the
    312            right amount of time, cache issues, bus speeds and all
    313            other issues being unequal but largely irrelevant.
    314         */
    315 
    316         if (short_loop_cnt == 0) {
    317                 short_loop_cnt = wait_usecs *
    318                         (LOOPS_PER_SEC / 1000000);
    319         }
    320296
    321297        /* Spin for a short period of time, because >99% of all
     
    323299        */
    324300
    325         for (i = 0; i < short_loop_cnt; i++) {
     301        for (i = 0; i < wait_usecs; i += 5) {
    326302                if (wavefront_status (dev) & mask) {
    327303                        return 1;
    328304                }
     305                udelay(5);
    329306        }
    330307
     
    894871wavefront_send_sample (snd_wavefront_t *dev,
    895872                       wavefront_patch_info *header,
    896                        UINT16 *dataptr,
     873                       u16 *dataptr,
    897874                       int data_is_unsigned)
    898875
     
    907884        */
    908885
    909         UINT16 sample_short;
    910         UINT32 length;
    911         UINT16 *data_end = 0;
     886        u16 sample_short;
     887        u32 length;
     888        u16 *data_end = 0;
    912889        unsigned int i;
    913890        const int max_blksize = 4096/2;
     
    10591036        */
    10601037
    1061         shptr = munge_int32 (*((UINT32 *) &header->hdr.s.sampleStartOffset),
     1038        shptr = munge_int32 (*((u32 *) &header->hdr.s.sampleStartOffset),
    10621039                             shptr, 4);
    1063         shptr = munge_int32 (*((UINT32 *) &header->hdr.s.loopStartOffset),
     1040        shptr = munge_int32 (*((u32 *) &header->hdr.s.loopStartOffset),
    10641041                             shptr, 4);
    1065         shptr = munge_int32 (*((UINT32 *) &header->hdr.s.loopEndOffset),
     1042        shptr = munge_int32 (*((u32 *) &header->hdr.s.loopEndOffset),
    10661043                             shptr, 4);
    1067         shptr = munge_int32 (*((UINT32 *) &header->hdr.s.sampleEndOffset),
     1044        shptr = munge_int32 (*((u32 *) &header->hdr.s.sampleEndOffset),
    10681045                             shptr, 4);
    10691046       
     
    13021279        for (i = 0; i < num_samples; i++) {
    13031280                char d[2];
    1304        
    1305                 if ((d[0] = wavefront_read (dev)) == -1) {
     1281                int val;
     1282       
     1283                if ((val = wavefront_read (dev)) == -1) {
    13061284                        snd_printk ("upload multisample failed "
    13071285                                    "during sample loop.\n");
    13081286                        return -(EIO);
    13091287                }
    1310 
    1311                 if ((d[1] = wavefront_read (dev)) == -1) {
     1288                d[0] = val;
     1289
     1290                if ((val = wavefront_read (dev)) == -1) {
    13121291                        snd_printk ("upload multisample failed "
    13131292                                    "during sample loop.\n");
    13141293                        return -(EIO);
    13151294                }
     1295                d[1] = val;
    13161296       
    13171297                header->hdr.ms.SampleNumber[i] =
     
    14721452
    14731453static void
    1474 process_sample_hdr (UCHAR8 *buf)
     1454process_sample_hdr (u8 *buf)
    14751455
    14761456{
    14771457        wavefront_sample s;
    1478         UCHAR8 *ptr;
     1458        u8 *ptr;
    14791459
    14801460        ptr = buf;
     
    14871467        */
    14881468
    1489         *((UINT32 *) &s.sampleStartOffset) = demunge_int32 (ptr, 4); ptr += 4;
    1490         *((UINT32 *) &s.loopStartOffset) = demunge_int32 (ptr, 4); ptr += 4;
    1491         *((UINT32 *) &s.loopEndOffset) = demunge_int32 (ptr, 4); ptr += 4;
    1492         *((UINT32 *) &s.sampleEndOffset) = demunge_int32 (ptr, 4); ptr += 4;
    1493         *((UINT32 *) &s.FrequencyBias) = demunge_int32 (ptr, 3); ptr += 3;
     1469        *((u32 *) &s.sampleStartOffset) = demunge_int32 (ptr, 4); ptr += 4;
     1470        *((u32 *) &s.loopStartOffset) = demunge_int32 (ptr, 4); ptr += 4;
     1471        *((u32 *) &s.loopEndOffset) = demunge_int32 (ptr, 4); ptr += 4;
     1472        *((u32 *) &s.sampleEndOffset) = demunge_int32 (ptr, 4); ptr += 4;
     1473        *((u32 *) &s.FrequencyBias) = demunge_int32 (ptr, 3); ptr += 3;
    14941474
    14951475        s.SampleResolution = *ptr & 0x3;
     
    15581538
    15591539        case WFC_UPLOAD_PATCH:
    1560                 munge_int32 (*((UINT32 *) wc->wbuf), patchnumbuf, 2);
     1540                munge_int32 (*((u32 *) wc->wbuf), patchnumbuf, 2);
    15611541                memcpy (wc->wbuf, patchnumbuf, 2);
    15621542                break;
     
    17481728*/
    17491729
    1750 int
     1730int __init
    17511731snd_wavefront_interrupt_bits (int irq)
    17521732
     
    17761756}
    17771757
    1778 static void
     1758static void __init
    17791759wavefront_should_cause_interrupt (snd_wavefront_t *dev,
    17801760                                  int val, int port, int timeout)
     
    17911771}
    17921772
    1793 int
    1794 snd_wavefront_detect_irq (snd_wavefront_t *dev)
    1795 
    1796 {
    1797         int i;
    1798         int possible_irqs[] = { 5, 9, 12, 15, -1 };
    1799 
    1800         /* Note: according to the PnP dump, 7 and 11 are possible too, but the
    1801            WaveFront SDK doesn't tell us how to set the card to use them. 
    1802         */
    1803 
    1804         snd_printk ("autodetecting WaveFront IRQ\n");
    1805 
    1806         for (i = 0; possible_irqs[i] > 0; i++) {
    1807                 if (snd_wavefront_check_irq (dev, possible_irqs[i]) == 0) {
    1808                         snd_printk ("autodetected IRQ %d\n",
    1809                                     possible_irqs[i]);
    1810                         return possible_irqs[i];
    1811                 }
    1812         }
    1813 
    1814         return -1;
    1815 }
    1816 
    1817 int
    1818 snd_wavefront_check_irq (snd_wavefront_t *dev, int irq)
    1819 
    1820 {
    1821         int bits;
    1822         unsigned long irq_mask;
    1823         short reported_irq;
    1824 
    1825         bits = snd_wavefront_interrupt_bits (irq);
    1826 
    1827         irq_mask = probe_irq_on ();
    1828 
    1829         outb (0x0, dev->control_port);
    1830         outb (0x80 | 0x40 | bits, dev->data_port);     
    1831         wavefront_should_cause_interrupt(dev, 0x80|0x40|0x10|0x1,
    1832                                          dev->control_port,
    1833                                          (reset_time*HZ)/100);
    1834 
    1835         reported_irq = probe_irq_off (irq_mask);
    1836 
    1837         if (reported_irq == 0) {
    1838                 snd_printk ("No unassigned interrupts detected "
    1839                             "after h/w reset\n");
    1840                 return -1;
    1841         } else if (reported_irq < 0) {
    1842                 snd_printk ("Multiple unassigned interrupts detected "
    1843                             "after h/w reset\n");
    1844                 return -1;
    1845         } else if (reported_irq != irq) {
    1846                 return -1;
    1847         }
    1848 
    1849         return 0; /* OK */
    1850 }
    1851 
    1852 static int
     1773static int __init
    18531774wavefront_reset_to_cleanliness (snd_wavefront_t *dev)
    18541775
     
    20041925#include <linux/fs.h>
    20051926#include <linux/mm.h>
    2006 #include <linux/malloc.h>
     1927#include <linux/slab.h>
    20071928#include <linux/unistd.h>
    20081929#include <asm/uaccess.h>
     
    20101931static int errno;
    20111932
    2012 static int
     1933static int __init
    20131934wavefront_download_firmware (snd_wavefront_t *dev, char *path)
    20141935
     
    21052026
    21062027
    2107 static int
     2028static int __init
    21082029wavefront_do_reset (snd_wavefront_t *dev)
    21092030
     
    21942115}
    21952116
    2196 int
     2117int __init
    21972118snd_wavefront_start (snd_wavefront_t *dev)
    21982119
     
    22362157}
    22372158
    2238 int
     2159int __init
    22392160snd_wavefront_detect (snd_wavefront_card_t *card)
    22402161
     
    22902211        return 0;
    22912212}
    2292 
    2293 EXPORT_SYMBOL(snd_wavefront_synth_ioctl);
    2294 EXPORT_SYMBOL(snd_wavefront_synth_open);
    2295 EXPORT_SYMBOL(snd_wavefront_synth_release);
    2296 EXPORT_SYMBOL(snd_wavefront_internal_interrupt);
    2297 EXPORT_SYMBOL(snd_wavefront_interrupt_bits);
    2298 EXPORT_SYMBOL(snd_wavefront_detect_irq);
    2299 EXPORT_SYMBOL(snd_wavefront_check_irq);
    2300 EXPORT_SYMBOL(snd_wavefront_start);
    2301 EXPORT_SYMBOL(snd_wavefront_detect);
    2302 EXPORT_SYMBOL(snd_wavefront_cmd);
    2303   /* wavefront_midi.c */
    2304 EXPORT_SYMBOL(snd_wavefront_midi_interrupt);
    2305 EXPORT_SYMBOL(snd_wavefront_midi_enable_virtual);
    2306 EXPORT_SYMBOL(snd_wavefront_midi_disable_virtual);
    2307 EXPORT_SYMBOL(snd_wavefront_midi_start);
    2308 EXPORT_SYMBOL(snd_wavefront_midi_input);
    2309 EXPORT_SYMBOL(snd_wavefront_midi_output);
    2310 
    2311 static int __init alsa_wavefront_init(void)
    2312 {
    2313         return 0;
    2314 }
    2315 
    2316 static void __exit alsa_wavefront_exit(void)
    2317 {
    2318 }
    2319 
    2320 module_init(alsa_wavefront_init)
    2321 module_exit(alsa_wavefront_exit)
  • GPL/branches/alsa-resync1/alsa-kernel/pci/es1968.c

    r106 r112  
    19171917    es->count += diff;
    19181918
    1919         while (es->count > es->frag_size) {
     1919        if (es->count > es->frag_size) {
    19201920        spin_unlock(&chip->substream_lock);
    19211921        snd_pcm_period_elapsed(subs);
  • GPL/branches/alsa-resync1/alsa-kernel/pci/ice1712.c

    r92 r112  
    9999#define ICE1712_SUBDEVICE_DELTA44       0x121433d6
    100100#define ICE1712_SUBDEVICE_AUDIOPHILE    0x121434d6
     101#define ICE1712_SUBDEVICE_DELTA1010LT   0x12143bd6
    101102#define ICE1712_SUBDEVICE_EWX2496       0x3b153011
    102103#define ICE1712_SUBDEVICE_EWS88MT       0x3b151511
     
    11851186                nval |= 0x04;
    11861187        if (val != nval) {
     1188                reg[1] = nval;
    11871189                if (snd_i2c_sendbytes(ice->cs8427, reg, 2) != 2) {
    11881190                        snd_i2c_unlock(ice->i2c);
     
    45404542                                    const struct pci_device_id *id)
    45414543{
    4542         static int dev = 0;
     4544        static int dev;
    45434545        snd_card_t *card;
    45444546        ice1712_t *ice;
     
    46094611        case ICE1712_SUBDEVICE_AUDIOPHILE:
    46104612                strcpy(card->shortname, "M Audio Audiophile 24/96");
     4613                break;
     4614        case ICE1712_SUBDEVICE_DELTA1010LT:
     4615                strcpy(card->shortname, "M Audio Delta 1010LT");
    46114616                break;
    46124617        case ICE1712_SUBDEVICE_EWX2496:
  • GPL/branches/alsa-resync1/alsa-kernel/pci/korg1212/korg1212.c

    r32 r112  
    22502250                const struct pci_device_id *id)
    22512251{
    2252         static int dev = 0;
     2252        static int dev;
    22532253        korg1212_t *korg1212;
    22542254        snd_card_t *card;
  • GPL/branches/alsa-resync1/alsa-kernel/pci/rme96.c

    r92 r112  
    26662666                const struct pci_device_id *id)
    26672667{
    2668         static int dev = 0;
     2668        static int dev;
    26692669        rme96_t *rme96;
    26702670        snd_card_t *card;
  • GPL/branches/alsa-resync1/alsa-kernel/pci/rme9652/rme9652.c

    r92 r112  
    28902890                             const struct pci_device_id *id)
    28912891{
    2892         static int dev = 0;
     2892        static int dev;
    28932893        rme9652_t *rme9652;
    28942894        snd_card_t *card;
  • GPL/branches/alsa-resync1/alsa-kernel/pci/sonicvibes.c

    r77 r112  
    1919 *   You should have received a copy of the GNU General Public License
    2020 *   along with this program; if not, write to the Free Software
    21  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
     21 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
    2222 *
    2323 */
    2424
    25 #define SNDRV_MAIN_OBJECT_FILE
    2625#include <sound/driver.h>
     26#include <asm/io.h>
     27#include <linux/delay.h>
     28#include <linux/init.h>
     29#include <linux/slab.h>
     30#include <sound/core.h>
    2731#include <sound/pcm.h>
    2832#include <sound/info.h>
     
    3236#define SNDRV_GET_ID
    3337#include <sound/initval.h>
     38#ifndef LINUX_2_2
     39#include <linux/gameport.h>
     40#endif
    3441
    3542EXPORT_NO_SYMBOLS;
     43
     44MODULE_AUTHOR("Jaroslav Kysela <perex@suse.cz>");
    3645MODULE_DESCRIPTION("S3 SonicVibes PCI");
     46MODULE_LICENSE("GPL");
    3747MODULE_CLASSES("{sound}");
    3848MODULE_DEVICES("{{S3,SonicVibes PCI}}");
     
    4757static int snd_index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX;  /* Index 0-MAX */
    4858static char *snd_id[SNDRV_CARDS] = SNDRV_DEFAULT_STR;   /* ID for this card */
    49 static int snd_enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE;      /* Enable this card */
     59static int snd_enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE_PNP;  /* Enable this card */
    5060#ifdef TARGET_OS2
    5161static int snd_reverb[SNDRV_CARDS] = {0,0,0,0,0,0,0,0};
     
    250260        snd_kcontrol_t *master_mute;
    251261        snd_kcontrol_t *master_volume;
     262
     263#ifndef LINUX_2_2
     264        struct gameport gameport;
     265#endif
    252266};
    253267
     
    940954}
    941955
    942 static int __init snd_sonicvibes_pcm(sonicvibes_t * sonic, int device, snd_pcm_t ** rpcm)
     956static int __devinit snd_sonicvibes_pcm(sonicvibes_t * sonic, int device, snd_pcm_t ** rpcm)
    943957{
    944958        snd_pcm_t *pcm;
     
    11791193#define SONICVIBES_CONTROLS (sizeof(snd_sonicvibes_controls)/sizeof(snd_kcontrol_new_t))
    11801194
    1181 static snd_kcontrol_new_t snd_sonicvibes_controls[] = {
     1195static snd_kcontrol_new_t snd_sonicvibes_controls[] __devinitdata = {
    11821196SONICVIBES_DOUBLE("Capture Volume", 0, SV_IREG_LEFT_ADC, SV_IREG_RIGHT_ADC, 0, 0, 15, 0),
    11831197SONICVIBES_DOUBLE("Aux Playback Switch", 0, SV_IREG_LEFT_AUX1, SV_IREG_RIGHT_AUX1, 7, 7, 1, 1),
     
    12101224}
    12111225
    1212 static int __init snd_sonicvibes_mixer(sonicvibes_t * sonic)
     1226static int __devinit snd_sonicvibes_mixer(sonicvibes_t * sonic)
    12131227{
    12141228        snd_card_t *card;
     
    12651279}
    12661280
    1267 static void __init snd_sonicvibes_proc_init(sonicvibes_t * sonic)
     1281static void __devinit snd_sonicvibes_proc_init(sonicvibes_t * sonic)
    12681282{
    12691283        snd_info_entry_t *entry;
     
    12951309 */
    12961310
    1297 static snd_kcontrol_new_t snd_sonicvibes_game_control =
     1311static snd_kcontrol_new_t snd_sonicvibes_game_control __devinitdata =
    12981312SONICVIBES_SINGLE("Joystick Speed", 0, SV_IREG_GAME_PORT, 1, 15, 0);
    12991313
    13001314static int snd_sonicvibes_free(sonicvibes_t *sonic)
    13011315{
     1316#ifndef LINUX_2_2
     1317        if (sonic->gameport.io)
     1318                gameport_unregister_port(&sonic->gameport);
     1319#endif
    13021320        snd_sonicvibes_proc_done(sonic);
    13031321        pci_write_config_dword(sonic->pci, 0x40, sonic->dmaa_port);
    13041322        pci_write_config_dword(sonic->pci, 0x48, sonic->dmac_port);
    1305         if (sonic->res_sb_port)
     1323        if (sonic->res_sb_port) {
    13061324                release_resource(sonic->res_sb_port);
    1307         if (sonic->res_enh_port)
     1325                kfree_nocheck(sonic->res_sb_port);
     1326        }
     1327        if (sonic->res_enh_port) {
    13081328                release_resource(sonic->res_enh_port);
    1309         if (sonic->res_synth_port)
     1329                kfree_nocheck(sonic->res_enh_port);
     1330        }
     1331        if (sonic->res_synth_port) {
    13101332                release_resource(sonic->res_synth_port);
    1311         if (sonic->res_midi_port)
     1333                kfree_nocheck(sonic->res_synth_port);
     1334        }
     1335        if (sonic->res_midi_port) {
    13121336                release_resource(sonic->res_midi_port);
    1313         if (sonic->res_dmaa)
     1337                kfree_nocheck(sonic->res_midi_port);
     1338        }
     1339        if (sonic->res_dmaa) {
    13141340                release_resource(sonic->res_dmaa);
    1315         if (sonic->res_dmac)
     1341                kfree_nocheck(sonic->res_dmaa);
     1342        }
     1343        if (sonic->res_dmac) {
    13161344                release_resource(sonic->res_dmac);
     1345                kfree_nocheck(sonic->res_dmac);
     1346        }
    13171347        if (sonic->irq >= 0)
    13181348                free_irq(sonic->irq, (void *)sonic);
     
    13271357}
    13281358
    1329 static int __init snd_sonicvibes_create(snd_card_t * card,
     1359static int __devinit snd_sonicvibes_create(snd_card_t * card,
    13301360                                        struct pci_dev *pci,
    13311361                                        int reverb,
     
    14961526#define SONICVIBES_MIDI_CONTROLS (sizeof(snd_sonicvibes_midi_controls)/sizeof(snd_kcontrol_new_t))
    14971527
    1498 static snd_kcontrol_new_t snd_sonicvibes_midi_controls[] = {
     1528static snd_kcontrol_new_t snd_sonicvibes_midi_controls[] __devinitdata = {
    14991529SONICVIBES_SINGLE("SonicVibes Wave Source RAM", 0, SV_IREG_WAVE_SOURCE, 0, 1, 0),
    15001530SONICVIBES_SINGLE("SonicVibes Wave Source RAM+ROM", 0, SV_IREG_WAVE_SOURCE, 1, 1, 0),
     
    15041534};
    15051535
    1506 static void snd_sonicvibes_midi_input_open(mpu401_t * mpu)
    1507 {
    1508         sonicvibes_t *sonic = snd_magic_cast(sonicvibes_t, mpu->private_data, return);
     1536static int snd_sonicvibes_midi_input_open(mpu401_t * mpu)
     1537{
     1538        sonicvibes_t *sonic = snd_magic_cast(sonicvibes_t, mpu->private_data, return -EIO);
    15091539        outb(sonic->irqmask &= ~SV_MIDI_MASK, SV_REG(sonic, IRQMASK));
     1540        return 0;
    15101541}
    15111542
     
    15161547}
    15171548
    1518 static int snd_sonicvibes_midi(sonicvibes_t * sonic, snd_rawmidi_t * rmidi)
     1549static int __devinit snd_sonicvibes_midi(sonicvibes_t * sonic, snd_rawmidi_t * rmidi)
    15191550{
    15201551        mpu401_t * mpu = snd_magic_cast(mpu401_t, rmidi->private_data, return -ENXIO);
     
    15331564}
    15341565
    1535 static int __init snd_sonic_probe(struct pci_dev *pci,
     1566static int __devinit snd_sonic_probe(struct pci_dev *pci,
    15361567                                  const struct pci_device_id *id)
    15371568{
    1538         static int dev = 0;
     1569        static int dev;
    15391570        snd_card_t *card;
    15401571        sonicvibes_t *sonic;
     
    15431574        int idx, err;
    15441575
    1545         for ( ; dev < SNDRV_CARDS; dev++) {
     1576        if (dev >= SNDRV_CARDS)
     1577                return -ENODEV;
    15461578                if (!snd_enable[dev]) {
    15471579                        dev++;
    15481580                        return -ENOENT;
    15491581                }
    1550                 break;
    1551         }
    1552         if (dev >= SNDRV_CARDS)
    1553                 return -ENODEV;
    15541582 
    15551583        card = snd_card_new(snd_index[dev], snd_id[dev], THIS_MODULE, 0);
     
    15961624                return err;
    15971625        }
     1626#ifndef LINUX_2_2
     1627        sonic->gameport.io = sonic->game_port;
     1628        gameport_register_port(&sonic->gameport);
     1629#endif
    15981630        strcpy(card->driver, "SonicVibes");
    15991631        strcpy(card->shortname, "S3 SonicVibes");
     
    16091641        }
    16101642       
    1611         PCI_SET_DRIVER_DATA(pci, card);
     1643        pci_set_drvdata(pci, card);
    16121644        dev++;
    16131645        return 0;
    16141646}
    16151647
    1616 static void __exit snd_sonic_remove(struct pci_dev *pci)
    1617 {
    1618         snd_card_free(PCI_GET_DRIVER_DATA(pci));
    1619         PCI_SET_DRIVER_DATA(pci, NULL);
     1648static void __devexit snd_sonic_remove(struct pci_dev *pci)
     1649{
     1650        snd_card_free(pci_get_drvdata(pci));
     1651        pci_set_drvdata(pci, NULL);
    16201652}
    16211653
     
    16321664        id_table: snd_sonic_ids,
    16331665        probe: snd_sonic_probe,
    1634         remove: snd_sonic_remove,
     1666        remove: __devexit_p(snd_sonic_remove),
    16351667#endif
    16361668};
     
    16421674        if ((err = pci_module_init(&driver)) < 0) {
    16431675#ifdef MODULE
    1644 //              snd_printk("S3 SonicVibes soundcard not found or device busy\n");
     1676//              printk(KERN_ERR "S3 SonicVibes soundcard not found or device busy\n");
    16451677#endif
    16461678                return err;
     
    16591691#ifndef MODULE
    16601692
    1661 /* format is: snd-card-sonicvibes=snd_enable,snd_index,snd_id,
     1693/* format is: snd-sonicvibes=snd_enable,snd_index,snd_id,
    16621694                                  snd_reverb,snd_mge,snd_dmaio */
    16631695
     
    16781710}
    16791711
    1680 __setup("snd-card-sonicvibes=", alsa_card_sonicvibes_setup);
     1712__setup("snd-sonicvibes=", alsa_card_sonicvibes_setup);
    16811713
    16821714#endif /* ifndef MODULE */
Note: See TracChangeset for help on using the changeset viewer.