aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/DocBook/writing-an-alsa-driver.tmpl36
-rw-r--r--include/sound/mpu401.h7
-rw-r--r--sound/drivers/mpu401/mpu401.c3
-rw-r--r--sound/drivers/mpu401/mpu401_uart.c20
-rw-r--r--sound/isa/ad1816a/ad1816a.c2
-rw-r--r--sound/isa/als100.c1
-rw-r--r--sound/isa/azt2320.c3
-rw-r--r--sound/isa/cmi8330.c2
-rw-r--r--sound/isa/cs423x/cs4231.c1
-rw-r--r--sound/isa/cs423x/cs4236.c3
-rw-r--r--sound/isa/es1688/es1688.c2
-rw-r--r--sound/isa/es18xx.c4
-rw-r--r--sound/isa/galaxy/galaxy.c3
-rw-r--r--sound/isa/gus/gusextreme.c3
-rw-r--r--sound/isa/msnd/msnd_pinnacle.c2
-rw-r--r--sound/isa/opl3sa2.c5
-rw-r--r--sound/isa/opti9xx/miro.c3
-rw-r--r--sound/isa/opti9xx/opti92x-ad1848.c2
-rw-r--r--sound/isa/sb/jazz16.c1
-rw-r--r--sound/isa/sb/sb16.c5
-rw-r--r--sound/isa/sc6000.c3
-rw-r--r--sound/isa/sscape.c3
-rw-r--r--sound/isa/wavefront/wavefront.c3
-rw-r--r--sound/pci/als4000.c5
-rw-r--r--sound/pci/au88x0/au88x0_mpu401.c6
-rw-r--r--sound/pci/azt3328.c5
-rw-r--r--sound/pci/cmipci.c5
-rw-r--r--sound/pci/es1938.c5
-rw-r--r--sound/pci/es1968.c5
-rw-r--r--sound/pci/fm801.c5
-rw-r--r--sound/pci/ice1712/ice1712.c10
-rw-r--r--sound/pci/maestro3.c4
-rw-r--r--sound/pci/oxygen/oxygen_lib.c6
-rw-r--r--sound/pci/riptide/riptide.c2
-rw-r--r--sound/pci/sonicvibes.c7
-rw-r--r--sound/pci/trident/trident.c5
-rw-r--r--sound/pci/via82xx.c5
-rw-r--r--sound/pci/ymfpci/ymfpci.c5
38 files changed, 103 insertions, 94 deletions
diff --git a/Documentation/DocBook/writing-an-alsa-driver.tmpl b/Documentation/DocBook/writing-an-alsa-driver.tmpl
index 598c22f3b3ac..5de23c007078 100644
--- a/Documentation/DocBook/writing-an-alsa-driver.tmpl
+++ b/Documentation/DocBook/writing-an-alsa-driver.tmpl
@@ -4288,7 +4288,7 @@ struct _snd_pcm_runtime {
4288<![CDATA[ 4288<![CDATA[
4289 struct snd_rawmidi *rmidi; 4289 struct snd_rawmidi *rmidi;
4290 snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, port, info_flags, 4290 snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, port, info_flags,
4291 irq, irq_flags, &rmidi); 4291 irq, &rmidi);
4292]]> 4292]]>
4293 </programlisting> 4293 </programlisting>
4294 </informalexample> 4294 </informalexample>
@@ -4343,6 +4343,13 @@ struct _snd_pcm_runtime {
4343 by itself to start processing the output stream in the irq handler. 4343 by itself to start processing the output stream in the irq handler.
4344 </para> 4344 </para>
4345 4345
4346 <para>
4347 If the MPU-401 interface shares its interrupt with the other logical
4348 devices on the card, set <constant>MPU401_INFO_IRQ_HOOK</constant>
4349 (see <link linkend="midi-interface-interrupt-handler"><citetitle>
4350 below</citetitle></link>).
4351 </para>
4352
4346 <para> 4353 <para>
4347 Usually, the port address corresponds to the command port and 4354 Usually, the port address corresponds to the command port and
4348 port + 1 corresponds to the data port. If not, you may change 4355 port + 1 corresponds to the data port. If not, you may change
@@ -4375,14 +4382,12 @@ struct _snd_pcm_runtime {
4375 </para> 4382 </para>
4376 4383
4377 <para> 4384 <para>
4378 The 6th argument specifies the irq number for UART. If the irq 4385 The 6th argument specifies the ISA irq number that will be
4379 is already allocated, pass 0 to the 7th argument 4386 allocated. If no interrupt is to be allocated (because your
4380 (<parameter>irq_flags</parameter>). Otherwise, pass the flags 4387 code is already allocating a shared interrupt, or because the
4381 for irq allocation 4388 device does not use interrupts), pass -1 instead.
4382 (<constant>SA_XXX</constant> bits) to it, and the irq will be 4389 For a MPU-401 device without an interrupt, a polling timer
4383 reserved by the mpu401-uart layer. If the card doesn't generate 4390 will be used instead.
4384 UART interrupts, pass -1 as the irq number. Then a timer
4385 interrupt will be invoked for polling.
4386 </para> 4391 </para>
4387 </section> 4392 </section>
4388 4393
@@ -4390,12 +4395,13 @@ struct _snd_pcm_runtime {
4390 <title>Interrupt Handler</title> 4395 <title>Interrupt Handler</title>
4391 <para> 4396 <para>
4392 When the interrupt is allocated in 4397 When the interrupt is allocated in
4393 <function>snd_mpu401_uart_new()</function>, the private 4398 <function>snd_mpu401_uart_new()</function>, an exclusive ISA
4394 interrupt handler is used, hence you don't have anything else to do 4399 interrupt handler is automatically used, hence you don't have
4395 than creating the mpu401 stuff. Otherwise, you have to call 4400 anything else to do than creating the mpu401 stuff. Otherwise, you
4396 <function>snd_mpu401_uart_interrupt()</function> explicitly when 4401 have to set <constant>MPU401_INFO_IRQ_HOOK</constant>, and call
4397 a UART interrupt is invoked and checked in your own interrupt 4402 <function>snd_mpu401_uart_interrupt()</function> explicitly from your
4398 handler. 4403 own interrupt handler when it has determined that a UART interrupt
4404 has occurred.
4399 </para> 4405 </para>
4400 4406
4401 <para> 4407 <para>
diff --git a/include/sound/mpu401.h b/include/sound/mpu401.h
index 1f1d53f8830b..20230db00ef1 100644
--- a/include/sound/mpu401.h
+++ b/include/sound/mpu401.h
@@ -50,7 +50,10 @@
50#define MPU401_INFO_INTEGRATED (1 << 2) /* integrated h/w port */ 50#define MPU401_INFO_INTEGRATED (1 << 2) /* integrated h/w port */
51#define MPU401_INFO_MMIO (1 << 3) /* MMIO access */ 51#define MPU401_INFO_MMIO (1 << 3) /* MMIO access */
52#define MPU401_INFO_TX_IRQ (1 << 4) /* independent TX irq */ 52#define MPU401_INFO_TX_IRQ (1 << 4) /* independent TX irq */
53#define MPU401_INFO_IRQ_HOOK (1 << 5) /* mpu401 irq handler is called
54 from driver irq handler */
53#define MPU401_INFO_NO_ACK (1 << 6) /* No ACK cmd needed */ 55#define MPU401_INFO_NO_ACK (1 << 6) /* No ACK cmd needed */
56#define MPU401_INFO_USE_TIMER (1 << 15) /* internal */
54 57
55#define MPU401_MODE_BIT_INPUT 0 58#define MPU401_MODE_BIT_INPUT 0
56#define MPU401_MODE_BIT_OUTPUT 1 59#define MPU401_MODE_BIT_OUTPUT 1
@@ -73,8 +76,7 @@ struct snd_mpu401 {
73 unsigned long port; /* base port of MPU-401 chip */ 76 unsigned long port; /* base port of MPU-401 chip */
74 unsigned long cport; /* port + 1 (usually) */ 77 unsigned long cport; /* port + 1 (usually) */
75 struct resource *res; /* port resource */ 78 struct resource *res; /* port resource */
76 int irq; /* IRQ number of MPU-401 chip (-1 = poll) */ 79 int irq; /* IRQ number of MPU-401 chip */
77 int irq_flags;
78 80
79 unsigned long mode; /* MPU401_MODE_XXXX */ 81 unsigned long mode; /* MPU401_MODE_XXXX */
80 int timer_invoked; 82 int timer_invoked;
@@ -131,7 +133,6 @@ int snd_mpu401_uart_new(struct snd_card *card,
131 unsigned long port, 133 unsigned long port,
132 unsigned int info_flags, 134 unsigned int info_flags,
133 int irq, 135 int irq,
134 int irq_flags,
135 struct snd_rawmidi ** rrawmidi); 136 struct snd_rawmidi ** rrawmidi);
136 137
137#endif /* __SOUND_MPU401_H */ 138#endif /* __SOUND_MPU401_H */
diff --git a/sound/drivers/mpu401/mpu401.c b/sound/drivers/mpu401/mpu401.c
index 149d05a8202d..1c02852aceea 100644
--- a/sound/drivers/mpu401/mpu401.c
+++ b/sound/drivers/mpu401/mpu401.c
@@ -86,8 +86,7 @@ static int snd_mpu401_create(int dev, struct snd_card **rcard)
86 } 86 }
87 87
88 err = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, port[dev], 0, 88 err = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, port[dev], 0,
89 irq[dev], irq[dev] >= 0 ? IRQF_DISABLED : 0, 89 irq[dev], NULL);
90 NULL);
91 if (err < 0) { 90 if (err < 0) {
92 printk(KERN_ERR "MPU401 not detected at 0x%lx\n", port[dev]); 91 printk(KERN_ERR "MPU401 not detected at 0x%lx\n", port[dev]);
93 goto _err; 92 goto _err;
diff --git a/sound/drivers/mpu401/mpu401_uart.c b/sound/drivers/mpu401/mpu401_uart.c
index 2af09996a3d0..9d01c181feca 100644
--- a/sound/drivers/mpu401/mpu401_uart.c
+++ b/sound/drivers/mpu401/mpu401_uart.c
@@ -3,7 +3,7 @@
3 * Routines for control of MPU-401 in UART mode 3 * Routines for control of MPU-401 in UART mode
4 * 4 *
5 * MPU-401 supports UART mode which is not capable generate transmit 5 * MPU-401 supports UART mode which is not capable generate transmit
6 * interrupts thus output is done via polling. Also, if irq < 0, then 6 * interrupts thus output is done via polling. Without interrupt,
7 * input is done also via polling. Do not expect good performance. 7 * input is done also via polling. Do not expect good performance.
8 * 8 *
9 * 9 *
@@ -374,7 +374,7 @@ snd_mpu401_uart_input_trigger(struct snd_rawmidi_substream *substream, int up)
374 /* first time - flush FIFO */ 374 /* first time - flush FIFO */
375 while (max-- > 0) 375 while (max-- > 0)
376 mpu->read(mpu, MPU401D(mpu)); 376 mpu->read(mpu, MPU401D(mpu));
377 if (mpu->irq < 0) 377 if (mpu->info_flags & MPU401_INFO_USE_TIMER)
378 snd_mpu401_uart_add_timer(mpu, 1); 378 snd_mpu401_uart_add_timer(mpu, 1);
379 } 379 }
380 380
@@ -383,7 +383,7 @@ snd_mpu401_uart_input_trigger(struct snd_rawmidi_substream *substream, int up)
383 snd_mpu401_uart_input_read(mpu); 383 snd_mpu401_uart_input_read(mpu);
384 spin_unlock_irqrestore(&mpu->input_lock, flags); 384 spin_unlock_irqrestore(&mpu->input_lock, flags);
385 } else { 385 } else {
386 if (mpu->irq < 0) 386 if (mpu->info_flags & MPU401_INFO_USE_TIMER)
387 snd_mpu401_uart_remove_timer(mpu, 1); 387 snd_mpu401_uart_remove_timer(mpu, 1);
388 clear_bit(MPU401_MODE_BIT_INPUT_TRIGGER, &mpu->mode); 388 clear_bit(MPU401_MODE_BIT_INPUT_TRIGGER, &mpu->mode);
389 } 389 }
@@ -496,7 +496,7 @@ static struct snd_rawmidi_ops snd_mpu401_uart_input =
496static void snd_mpu401_uart_free(struct snd_rawmidi *rmidi) 496static void snd_mpu401_uart_free(struct snd_rawmidi *rmidi)
497{ 497{
498 struct snd_mpu401 *mpu = rmidi->private_data; 498 struct snd_mpu401 *mpu = rmidi->private_data;
499 if (mpu->irq_flags && mpu->irq >= 0) 499 if (mpu->irq >= 0)
500 free_irq(mpu->irq, (void *) mpu); 500 free_irq(mpu->irq, (void *) mpu);
501 release_and_free_resource(mpu->res); 501 release_and_free_resource(mpu->res);
502 kfree(mpu); 502 kfree(mpu);
@@ -509,8 +509,7 @@ static void snd_mpu401_uart_free(struct snd_rawmidi *rmidi)
509 * @hardware: the hardware type, MPU401_HW_XXXX 509 * @hardware: the hardware type, MPU401_HW_XXXX
510 * @port: the base address of MPU401 port 510 * @port: the base address of MPU401 port
511 * @info_flags: bitflags MPU401_INFO_XXX 511 * @info_flags: bitflags MPU401_INFO_XXX
512 * @irq: the irq number, -1 if no interrupt for mpu 512 * @irq: the ISA irq number, -1 if not to be allocated
513 * @irq_flags: the irq request flags (SA_XXX), 0 if irq was already reserved.
514 * @rrawmidi: the pointer to store the new rawmidi instance 513 * @rrawmidi: the pointer to store the new rawmidi instance
515 * 514 *
516 * Creates a new MPU-401 instance. 515 * Creates a new MPU-401 instance.
@@ -525,7 +524,7 @@ int snd_mpu401_uart_new(struct snd_card *card, int device,
525 unsigned short hardware, 524 unsigned short hardware,
526 unsigned long port, 525 unsigned long port,
527 unsigned int info_flags, 526 unsigned int info_flags,
528 int irq, int irq_flags, 527 int irq,
529 struct snd_rawmidi ** rrawmidi) 528 struct snd_rawmidi ** rrawmidi)
530{ 529{
531 struct snd_mpu401 *mpu; 530 struct snd_mpu401 *mpu;
@@ -577,8 +576,8 @@ int snd_mpu401_uart_new(struct snd_card *card, int device,
577 mpu->cport = port + 2; 576 mpu->cport = port + 2;
578 else 577 else
579 mpu->cport = port + 1; 578 mpu->cport = port + 1;
580 if (irq >= 0 && irq_flags) { 579 if (irq >= 0) {
581 if (request_irq(irq, snd_mpu401_uart_interrupt, irq_flags, 580 if (request_irq(irq, snd_mpu401_uart_interrupt, IRQF_DISABLED,
582 "MPU401 UART", (void *) mpu)) { 581 "MPU401 UART", (void *) mpu)) {
583 snd_printk(KERN_ERR "mpu401_uart: " 582 snd_printk(KERN_ERR "mpu401_uart: "
584 "unable to grab IRQ %d\n", irq); 583 "unable to grab IRQ %d\n", irq);
@@ -586,9 +585,10 @@ int snd_mpu401_uart_new(struct snd_card *card, int device,
586 return -EBUSY; 585 return -EBUSY;
587 } 586 }
588 } 587 }
588 if (irq < 0 && !(info_flags & MPU401_INFO_IRQ_HOOK))
589 info_flags |= MPU401_INFO_USE_TIMER;
589 mpu->info_flags = info_flags; 590 mpu->info_flags = info_flags;
590 mpu->irq = irq; 591 mpu->irq = irq;
591 mpu->irq_flags = irq_flags;
592 if (card->shortname[0]) 592 if (card->shortname[0])
593 snprintf(rmidi->name, sizeof(rmidi->name), "%s MIDI", 593 snprintf(rmidi->name, sizeof(rmidi->name), "%s MIDI",
594 card->shortname); 594 card->shortname);
diff --git a/sound/isa/ad1816a/ad1816a.c b/sound/isa/ad1816a/ad1816a.c
index 3cb75bc97699..a87a2b566e19 100644
--- a/sound/isa/ad1816a/ad1816a.c
+++ b/sound/isa/ad1816a/ad1816a.c
@@ -204,7 +204,7 @@ static int __devinit snd_card_ad1816a_probe(int dev, struct pnp_card_link *pcard
204 204
205 if (mpu_port[dev] > 0) { 205 if (mpu_port[dev] > 0) {
206 if (snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 206 if (snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
207 mpu_port[dev], 0, mpu_irq[dev], IRQF_DISABLED, 207 mpu_port[dev], 0, mpu_irq[dev],
208 NULL) < 0) 208 NULL) < 0)
209 printk(KERN_ERR PFX "no MPU-401 device at 0x%lx.\n", mpu_port[dev]); 209 printk(KERN_ERR PFX "no MPU-401 device at 0x%lx.\n", mpu_port[dev]);
210 } 210 }
diff --git a/sound/isa/als100.c b/sound/isa/als100.c
index 20becc89f6f6..706effd6b3cd 100644
--- a/sound/isa/als100.c
+++ b/sound/isa/als100.c
@@ -256,7 +256,6 @@ static int __devinit snd_card_als100_probe(int dev,
256 mpu_type, 256 mpu_type,
257 mpu_port[dev], 0, 257 mpu_port[dev], 0,
258 mpu_irq[dev], 258 mpu_irq[dev],
259 mpu_irq[dev] >= 0 ? IRQF_DISABLED : 0,
260 NULL) < 0) 259 NULL) < 0)
261 snd_printk(KERN_ERR PFX "no MPU-401 device at 0x%lx\n", mpu_port[dev]); 260 snd_printk(KERN_ERR PFX "no MPU-401 device at 0x%lx\n", mpu_port[dev]);
262 } 261 }
diff --git a/sound/isa/azt2320.c b/sound/isa/azt2320.c
index aac8dc15c2fe..b7bdbf307740 100644
--- a/sound/isa/azt2320.c
+++ b/sound/isa/azt2320.c
@@ -234,8 +234,7 @@ static int __devinit snd_card_azt2320_probe(int dev,
234 if (mpu_port[dev] > 0 && mpu_port[dev] != SNDRV_AUTO_PORT) { 234 if (mpu_port[dev] > 0 && mpu_port[dev] != SNDRV_AUTO_PORT) {
235 if (snd_mpu401_uart_new(card, 0, MPU401_HW_AZT2320, 235 if (snd_mpu401_uart_new(card, 0, MPU401_HW_AZT2320,
236 mpu_port[dev], 0, 236 mpu_port[dev], 0,
237 mpu_irq[dev], IRQF_DISABLED, 237 mpu_irq[dev], NULL) < 0)
238 NULL) < 0)
239 snd_printk(KERN_ERR PFX "no MPU-401 device at 0x%lx\n", mpu_port[dev]); 238 snd_printk(KERN_ERR PFX "no MPU-401 device at 0x%lx\n", mpu_port[dev]);
240 } 239 }
241 240
diff --git a/sound/isa/cmi8330.c b/sound/isa/cmi8330.c
index fe79a169acb5..dca69f80305f 100644
--- a/sound/isa/cmi8330.c
+++ b/sound/isa/cmi8330.c
@@ -597,7 +597,7 @@ static int __devinit snd_cmi8330_probe(struct snd_card *card, int dev)
597 if (mpuport[dev] != SNDRV_AUTO_PORT) { 597 if (mpuport[dev] != SNDRV_AUTO_PORT) {
598 if (snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 598 if (snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
599 mpuport[dev], 0, mpuirq[dev], 599 mpuport[dev], 0, mpuirq[dev],
600 IRQF_DISABLED, NULL) < 0) 600 NULL) < 0)
601 printk(KERN_ERR PFX "no MPU-401 device at 0x%lx.\n", 601 printk(KERN_ERR PFX "no MPU-401 device at 0x%lx.\n",
602 mpuport[dev]); 602 mpuport[dev]);
603 } 603 }
diff --git a/sound/isa/cs423x/cs4231.c b/sound/isa/cs423x/cs4231.c
index cb9153e75b82..409fa0ad7843 100644
--- a/sound/isa/cs423x/cs4231.c
+++ b/sound/isa/cs423x/cs4231.c
@@ -131,7 +131,6 @@ static int __devinit snd_cs4231_probe(struct device *dev, unsigned int n)
131 mpu_irq[n] = -1; 131 mpu_irq[n] = -1;
132 if (snd_mpu401_uart_new(card, 0, MPU401_HW_CS4232, 132 if (snd_mpu401_uart_new(card, 0, MPU401_HW_CS4232,
133 mpu_port[n], 0, mpu_irq[n], 133 mpu_port[n], 0, mpu_irq[n],
134 mpu_irq[n] >= 0 ? IRQF_DISABLED : 0,
135 NULL) < 0) 134 NULL) < 0)
136 dev_warn(dev, "MPU401 not detected\n"); 135 dev_warn(dev, "MPU401 not detected\n");
137 } 136 }
diff --git a/sound/isa/cs423x/cs4236.c b/sound/isa/cs423x/cs4236.c
index 999dc1e0fdbd..0dbde461e6c1 100644
--- a/sound/isa/cs423x/cs4236.c
+++ b/sound/isa/cs423x/cs4236.c
@@ -449,8 +449,7 @@ static int __devinit snd_cs423x_probe(struct snd_card *card, int dev)
449 mpu_irq[dev] = -1; 449 mpu_irq[dev] = -1;
450 if (snd_mpu401_uart_new(card, 0, MPU401_HW_CS4232, 450 if (snd_mpu401_uart_new(card, 0, MPU401_HW_CS4232,
451 mpu_port[dev], 0, 451 mpu_port[dev], 0,
452 mpu_irq[dev], 452 mpu_irq[dev], NULL) < 0)
453 mpu_irq[dev] >= 0 ? IRQF_DISABLED : 0, NULL) < 0)
454 printk(KERN_WARNING IDENT ": MPU401 not detected\n"); 453 printk(KERN_WARNING IDENT ": MPU401 not detected\n");
455 } 454 }
456 455
diff --git a/sound/isa/es1688/es1688.c b/sound/isa/es1688/es1688.c
index 0cde8131a575..5493e9e4bcd5 100644
--- a/sound/isa/es1688/es1688.c
+++ b/sound/isa/es1688/es1688.c
@@ -174,7 +174,7 @@ static int __devinit snd_es1688_probe(struct snd_card *card, unsigned int n)
174 chip->mpu_port > 0) { 174 chip->mpu_port > 0) {
175 error = snd_mpu401_uart_new(card, 0, MPU401_HW_ES1688, 175 error = snd_mpu401_uart_new(card, 0, MPU401_HW_ES1688,
176 chip->mpu_port, 0, 176 chip->mpu_port, 0,
177 mpu_irq[n], IRQF_DISABLED, NULL); 177 mpu_irq[n], NULL);
178 if (error < 0) 178 if (error < 0)
179 return error; 179 return error;
180 } 180 }
diff --git a/sound/isa/es18xx.c b/sound/isa/es18xx.c
index fb4d6b34bbca..aeee8f8bf5e9 100644
--- a/sound/isa/es18xx.c
+++ b/sound/isa/es18xx.c
@@ -2160,8 +2160,8 @@ static int __devinit snd_audiodrive_probe(struct snd_card *card, int dev)
2160 2160
2161 if (mpu_port[dev] > 0 && mpu_port[dev] != SNDRV_AUTO_PORT) { 2161 if (mpu_port[dev] > 0 && mpu_port[dev] != SNDRV_AUTO_PORT) {
2162 err = snd_mpu401_uart_new(card, 0, MPU401_HW_ES18XX, 2162 err = snd_mpu401_uart_new(card, 0, MPU401_HW_ES18XX,
2163 mpu_port[dev], 0, 2163 mpu_port[dev], MPU401_INFO_IRQ_HOOK,
2164 irq[dev], 0, &chip->rmidi); 2164 -1, &chip->rmidi);
2165 if (err < 0) 2165 if (err < 0)
2166 return err; 2166 return err;
2167 } 2167 }
diff --git a/sound/isa/galaxy/galaxy.c b/sound/isa/galaxy/galaxy.c
index ee54df082b9c..e51d3244742a 100644
--- a/sound/isa/galaxy/galaxy.c
+++ b/sound/isa/galaxy/galaxy.c
@@ -585,8 +585,7 @@ static int __devinit snd_galaxy_probe(struct device *dev, unsigned int n)
585 585
586 if (mpu_port[n] >= 0) { 586 if (mpu_port[n] >= 0) {
587 err = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 587 err = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
588 mpu_port[n], 0, mpu_irq[n], 588 mpu_port[n], 0, mpu_irq[n], NULL);
589 IRQF_DISABLED, NULL);
590 if (err < 0) 589 if (err < 0)
591 goto error; 590 goto error;
592 } 591 }
diff --git a/sound/isa/gus/gusextreme.c b/sound/isa/gus/gusextreme.c
index 008e8e5bfa37..c4733c08b60b 100644
--- a/sound/isa/gus/gusextreme.c
+++ b/sound/isa/gus/gusextreme.c
@@ -317,8 +317,7 @@ static int __devinit snd_gusextreme_probe(struct device *dev, unsigned int n)
317 317
318 if (es1688->mpu_port >= 0x300) { 318 if (es1688->mpu_port >= 0x300) {
319 error = snd_mpu401_uart_new(card, 0, MPU401_HW_ES1688, 319 error = snd_mpu401_uart_new(card, 0, MPU401_HW_ES1688,
320 es1688->mpu_port, 0, 320 es1688->mpu_port, 0, mpu_irq[n], NULL);
321 mpu_irq[n], IRQF_DISABLED, NULL);
322 if (error < 0) 321 if (error < 0)
323 goto out; 322 goto out;
324 } 323 }
diff --git a/sound/isa/msnd/msnd_pinnacle.c b/sound/isa/msnd/msnd_pinnacle.c
index 91d6023a63e5..0961e2cf20ca 100644
--- a/sound/isa/msnd/msnd_pinnacle.c
+++ b/sound/isa/msnd/msnd_pinnacle.c
@@ -600,7 +600,7 @@ static int __devinit snd_msnd_attach(struct snd_card *card)
600 mpu_io[0], 600 mpu_io[0],
601 MPU401_MODE_INPUT | 601 MPU401_MODE_INPUT |
602 MPU401_MODE_OUTPUT, 602 MPU401_MODE_OUTPUT,
603 mpu_irq[0], IRQF_DISABLED, 603 mpu_irq[0],
604 &chip->rmidi); 604 &chip->rmidi);
605 if (err < 0) { 605 if (err < 0) {
606 printk(KERN_ERR LOGNAME 606 printk(KERN_ERR LOGNAME
diff --git a/sound/isa/opl3sa2.c b/sound/isa/opl3sa2.c
index 9b915e27b5bd..de99f47770bf 100644
--- a/sound/isa/opl3sa2.c
+++ b/sound/isa/opl3sa2.c
@@ -707,8 +707,9 @@ static int __devinit snd_opl3sa2_probe(struct snd_card *card, int dev)
707 } 707 }
708 if (midi_port[dev] >= 0x300 && midi_port[dev] < 0x340) { 708 if (midi_port[dev] >= 0x300 && midi_port[dev] < 0x340) {
709 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_OPL3SA2, 709 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_OPL3SA2,
710 midi_port[dev], 0, 710 midi_port[dev],
711 xirq, 0, &chip->rmidi)) < 0) 711 MPU401_INFO_IRQ_HOOK, -1,
712 &chip->rmidi)) < 0)
712 return err; 713 return err;
713 } 714 }
714 sprintf(card->longname, "%s at 0x%lx, irq %d, dma %d", 715 sprintf(card->longname, "%s at 0x%lx, irq %d, dma %d",
diff --git a/sound/isa/opti9xx/miro.c b/sound/isa/opti9xx/miro.c
index 8c24102d0d93..d94d0f35cb76 100644
--- a/sound/isa/opti9xx/miro.c
+++ b/sound/isa/opti9xx/miro.c
@@ -1377,8 +1377,7 @@ static int __devinit snd_miro_probe(struct snd_card *card)
1377 rmidi = NULL; 1377 rmidi = NULL;
1378 else { 1378 else {
1379 error = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 1379 error = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
1380 mpu_port, 0, miro->mpu_irq, IRQF_DISABLED, 1380 mpu_port, 0, miro->mpu_irq, &rmidi);
1381 &rmidi);
1382 if (error < 0) 1381 if (error < 0)
1383 snd_printk(KERN_WARNING "no MPU-401 device at 0x%lx?\n", 1382 snd_printk(KERN_WARNING "no MPU-401 device at 0x%lx?\n",
1384 mpu_port); 1383 mpu_port);
diff --git a/sound/isa/opti9xx/opti92x-ad1848.c b/sound/isa/opti9xx/opti92x-ad1848.c
index c35dc68930dc..346e12baa98e 100644
--- a/sound/isa/opti9xx/opti92x-ad1848.c
+++ b/sound/isa/opti9xx/opti92x-ad1848.c
@@ -914,7 +914,7 @@ static int __devinit snd_opti9xx_probe(struct snd_card *card)
914 rmidi = NULL; 914 rmidi = NULL;
915 else { 915 else {
916 error = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 916 error = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
917 mpu_port, 0, mpu_irq, IRQF_DISABLED, &rmidi); 917 mpu_port, 0, mpu_irq, &rmidi);
918 if (error) 918 if (error)
919 snd_printk(KERN_WARNING "no MPU-401 device at 0x%lx?\n", 919 snd_printk(KERN_WARNING "no MPU-401 device at 0x%lx?\n",
920 mpu_port); 920 mpu_port);
diff --git a/sound/isa/sb/jazz16.c b/sound/isa/sb/jazz16.c
index 8ccbcddf08e1..54e3c2c18060 100644
--- a/sound/isa/sb/jazz16.c
+++ b/sound/isa/sb/jazz16.c
@@ -322,7 +322,6 @@ static int __devinit snd_jazz16_probe(struct device *devptr, unsigned int dev)
322 MPU401_HW_MPU401, 322 MPU401_HW_MPU401,
323 mpu_port[dev], 0, 323 mpu_port[dev], 0,
324 mpu_irq[dev], 324 mpu_irq[dev],
325 mpu_irq[dev] >= 0 ? IRQF_DISABLED : 0,
326 NULL) < 0) 325 NULL) < 0)
327 snd_printk(KERN_ERR "no MPU-401 device at 0x%lx\n", 326 snd_printk(KERN_ERR "no MPU-401 device at 0x%lx\n",
328 mpu_port[dev]); 327 mpu_port[dev]);
diff --git a/sound/isa/sb/sb16.c b/sound/isa/sb/sb16.c
index 4d1c5a300ff8..237f8bd7fbe4 100644
--- a/sound/isa/sb/sb16.c
+++ b/sound/isa/sb/sb16.c
@@ -394,8 +394,9 @@ static int __devinit snd_sb16_probe(struct snd_card *card, int dev)
394 394
395 if (chip->mpu_port > 0 && chip->mpu_port != SNDRV_AUTO_PORT) { 395 if (chip->mpu_port > 0 && chip->mpu_port != SNDRV_AUTO_PORT) {
396 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_SB, 396 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_SB,
397 chip->mpu_port, 0, 397 chip->mpu_port,
398 xirq, 0, &chip->rmidi)) < 0) 398 MPU401_INFO_IRQ_HOOK, -1,
399 &chip->rmidi)) < 0)
399 return err; 400 return err;
400 chip->rmidi_callback = snd_mpu401_uart_interrupt; 401 chip->rmidi_callback = snd_mpu401_uart_interrupt;
401 } 402 }
diff --git a/sound/isa/sc6000.c b/sound/isa/sc6000.c
index 9a8bbf6dd62a..207c161f100c 100644
--- a/sound/isa/sc6000.c
+++ b/sound/isa/sc6000.c
@@ -658,8 +658,7 @@ static int __devinit snd_sc6000_probe(struct device *devptr, unsigned int dev)
658 if (snd_mpu401_uart_new(card, 0, 658 if (snd_mpu401_uart_new(card, 0,
659 MPU401_HW_MPU401, 659 MPU401_HW_MPU401,
660 mpu_port[dev], 0, 660 mpu_port[dev], 0,
661 mpu_irq[dev], IRQF_DISABLED, 661 mpu_irq[dev], NULL) < 0)
662 NULL) < 0)
663 snd_printk(KERN_ERR "no MPU-401 device at 0x%lx ?\n", 662 snd_printk(KERN_ERR "no MPU-401 device at 0x%lx ?\n",
664 mpu_port[dev]); 663 mpu_port[dev]);
665 } 664 }
diff --git a/sound/isa/sscape.c b/sound/isa/sscape.c
index e2d5d2d3ed96..f2379e102b63 100644
--- a/sound/isa/sscape.c
+++ b/sound/isa/sscape.c
@@ -825,8 +825,7 @@ static int __devinit create_mpu401(struct snd_card *card, int devnum,
825 int err; 825 int err;
826 826
827 err = snd_mpu401_uart_new(card, devnum, MPU401_HW_MPU401, port, 827 err = snd_mpu401_uart_new(card, devnum, MPU401_HW_MPU401, port,
828 MPU401_INFO_INTEGRATED, irq, IRQF_DISABLED, 828 MPU401_INFO_INTEGRATED, irq, &rawmidi);
829 &rawmidi);
830 if (err == 0) { 829 if (err == 0) {
831 struct snd_mpu401 *mpu = rawmidi->private_data; 830 struct snd_mpu401 *mpu = rawmidi->private_data;
832 mpu->open_input = mpu401_open; 831 mpu->open_input = mpu401_open;
diff --git a/sound/isa/wavefront/wavefront.c b/sound/isa/wavefront/wavefront.c
index 711670e4a425..83f291d89a95 100644
--- a/sound/isa/wavefront/wavefront.c
+++ b/sound/isa/wavefront/wavefront.c
@@ -449,8 +449,7 @@ snd_wavefront_probe (struct snd_card *card, int dev)
449 if (cs4232_mpu_port[dev] > 0 && cs4232_mpu_port[dev] != SNDRV_AUTO_PORT) { 449 if (cs4232_mpu_port[dev] > 0 && cs4232_mpu_port[dev] != SNDRV_AUTO_PORT) {
450 err = snd_mpu401_uart_new(card, midi_dev, MPU401_HW_CS4232, 450 err = snd_mpu401_uart_new(card, midi_dev, MPU401_HW_CS4232,
451 cs4232_mpu_port[dev], 0, 451 cs4232_mpu_port[dev], 0,
452 cs4232_mpu_irq[dev], IRQF_DISABLED, 452 cs4232_mpu_irq[dev], NULL);
453 NULL);
454 if (err < 0) { 453 if (err < 0) {
455 snd_printk (KERN_ERR "can't allocate CS4232 MPU-401 device\n"); 454 snd_printk (KERN_ERR "can't allocate CS4232 MPU-401 device\n");
456 return err; 455 return err;
diff --git a/sound/pci/als4000.c b/sound/pci/als4000.c
index a9c1af33f276..04628696eb08 100644
--- a/sound/pci/als4000.c
+++ b/sound/pci/als4000.c
@@ -931,8 +931,9 @@ static int __devinit snd_card_als4000_probe(struct pci_dev *pci,
931 931
932 if ((err = snd_mpu401_uart_new( card, 0, MPU401_HW_ALS4000, 932 if ((err = snd_mpu401_uart_new( card, 0, MPU401_HW_ALS4000,
933 iobase + ALS4K_IOB_30_MIDI_DATA, 933 iobase + ALS4K_IOB_30_MIDI_DATA,
934 MPU401_INFO_INTEGRATED, 934 MPU401_INFO_INTEGRATED |
935 pci->irq, 0, &chip->rmidi)) < 0) { 935 MPU401_INFO_IRQ_HOOK,
936 -1, &chip->rmidi)) < 0) {
936 printk(KERN_ERR "als4000: no MPU-401 device at 0x%lx?\n", 937 printk(KERN_ERR "als4000: no MPU-401 device at 0x%lx?\n",
937 iobase + ALS4K_IOB_30_MIDI_DATA); 938 iobase + ALS4K_IOB_30_MIDI_DATA);
938 goto out_err; 939 goto out_err;
diff --git a/sound/pci/au88x0/au88x0_mpu401.c b/sound/pci/au88x0/au88x0_mpu401.c
index 0dc8d259d1ed..e6c6a0febb75 100644
--- a/sound/pci/au88x0/au88x0_mpu401.c
+++ b/sound/pci/au88x0/au88x0_mpu401.c
@@ -84,7 +84,7 @@ static int __devinit snd_vortex_midi(vortex_t * vortex)
84#ifdef VORTEX_MPU401_LEGACY 84#ifdef VORTEX_MPU401_LEGACY
85 if ((temp = 85 if ((temp =
86 snd_mpu401_uart_new(vortex->card, 0, MPU401_HW_MPU401, 0x330, 86 snd_mpu401_uart_new(vortex->card, 0, MPU401_HW_MPU401, 0x330,
87 0, 0, 0, &rmidi)) != 0) { 87 MPU401_INFO_IRQ_HOOK, -1, &rmidi)) != 0) {
88 hwwrite(vortex->mmio, VORTEX_CTRL, 88 hwwrite(vortex->mmio, VORTEX_CTRL,
89 (hwread(vortex->mmio, VORTEX_CTRL) & 89 (hwread(vortex->mmio, VORTEX_CTRL) &
90 ~CTRL_MIDI_PORT) & ~CTRL_MIDI_EN); 90 ~CTRL_MIDI_PORT) & ~CTRL_MIDI_EN);
@@ -94,8 +94,8 @@ static int __devinit snd_vortex_midi(vortex_t * vortex)
94 port = (unsigned long)(vortex->mmio + VORTEX_MIDI_DATA); 94 port = (unsigned long)(vortex->mmio + VORTEX_MIDI_DATA);
95 if ((temp = 95 if ((temp =
96 snd_mpu401_uart_new(vortex->card, 0, MPU401_HW_AUREAL, port, 96 snd_mpu401_uart_new(vortex->card, 0, MPU401_HW_AUREAL, port,
97 MPU401_INFO_INTEGRATED | MPU401_INFO_MMIO, 97 MPU401_INFO_INTEGRATED | MPU401_INFO_MMIO |
98 0, 0, &rmidi)) != 0) { 98 MPU401_INFO_IRQ_HOOK, -1, &rmidi)) != 0) {
99 hwwrite(vortex->mmio, VORTEX_CTRL, 99 hwwrite(vortex->mmio, VORTEX_CTRL,
100 (hwread(vortex->mmio, VORTEX_CTRL) & 100 (hwread(vortex->mmio, VORTEX_CTRL) &
101 ~CTRL_MIDI_PORT) & ~CTRL_MIDI_EN); 101 ~CTRL_MIDI_PORT) & ~CTRL_MIDI_EN);
diff --git a/sound/pci/azt3328.c b/sound/pci/azt3328.c
index 579fc0dce128..d24fe425e87f 100644
--- a/sound/pci/azt3328.c
+++ b/sound/pci/azt3328.c
@@ -2652,8 +2652,9 @@ snd_azf3328_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
2652 since our hardware ought to be similar, thus use same ID. */ 2652 since our hardware ought to be similar, thus use same ID. */
2653 err = snd_mpu401_uart_new( 2653 err = snd_mpu401_uart_new(
2654 card, 0, 2654 card, 0,
2655 MPU401_HW_AZT2320, chip->mpu_io, MPU401_INFO_INTEGRATED, 2655 MPU401_HW_AZT2320, chip->mpu_io,
2656 pci->irq, 0, &chip->rmidi 2656 MPU401_INFO_INTEGRATED | MPU401_INFO_IRQ_HOOK,
2657 -1, &chip->rmidi
2657 ); 2658 );
2658 if (err < 0) { 2659 if (err < 0) {
2659 snd_printk(KERN_ERR "azf3328: no MPU-401 device at 0x%lx?\n", 2660 snd_printk(KERN_ERR "azf3328: no MPU-401 device at 0x%lx?\n",
diff --git a/sound/pci/cmipci.c b/sound/pci/cmipci.c
index 9cf99fb7eb9c..da9c73211eca 100644
--- a/sound/pci/cmipci.c
+++ b/sound/pci/cmipci.c
@@ -3228,8 +3228,9 @@ static int __devinit snd_cmipci_create(struct snd_card *card, struct pci_dev *pc
3228 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_CMIPCI, 3228 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_CMIPCI,
3229 iomidi, 3229 iomidi,
3230 (integrated_midi ? 3230 (integrated_midi ?
3231 MPU401_INFO_INTEGRATED : 0), 3231 MPU401_INFO_INTEGRATED : 0) |
3232 cm->irq, 0, &cm->rmidi)) < 0) { 3232 MPU401_INFO_IRQ_HOOK,
3233 -1, &cm->rmidi)) < 0) {
3233 printk(KERN_ERR "cmipci: no UART401 device at 0x%lx\n", iomidi); 3234 printk(KERN_ERR "cmipci: no UART401 device at 0x%lx\n", iomidi);
3234 } 3235 }
3235 } 3236 }
diff --git a/sound/pci/es1938.c b/sound/pci/es1938.c
index 26a5a2f25d4b..718a2643474e 100644
--- a/sound/pci/es1938.c
+++ b/sound/pci/es1938.c
@@ -1854,8 +1854,9 @@ static int __devinit snd_es1938_probe(struct pci_dev *pci,
1854 } 1854 }
1855 } 1855 }
1856 if (snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 1856 if (snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
1857 chip->mpu_port, MPU401_INFO_INTEGRATED, 1857 chip->mpu_port,
1858 chip->irq, 0, &chip->rmidi) < 0) { 1858 MPU401_INFO_INTEGRATED | MPU401_INFO_IRQ_HOOK,
1859 -1, &chip->rmidi) < 0) {
1859 printk(KERN_ERR "es1938: unable to initialize MPU-401\n"); 1860 printk(KERN_ERR "es1938: unable to initialize MPU-401\n");
1860 } else { 1861 } else {
1861 // this line is vital for MIDI interrupt handling on ess-solo1 1862 // this line is vital for MIDI interrupt handling on ess-solo1
diff --git a/sound/pci/es1968.c b/sound/pci/es1968.c
index 99ea9320c6b5..407e4abc4356 100644
--- a/sound/pci/es1968.c
+++ b/sound/pci/es1968.c
@@ -2843,8 +2843,9 @@ static int __devinit snd_es1968_probe(struct pci_dev *pci,
2843 if (enable_mpu[dev]) { 2843 if (enable_mpu[dev]) {
2844 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401, 2844 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_MPU401,
2845 chip->io_port + ESM_MPU401_PORT, 2845 chip->io_port + ESM_MPU401_PORT,
2846 MPU401_INFO_INTEGRATED, 2846 MPU401_INFO_INTEGRATED |
2847 chip->irq, 0, &chip->rmidi)) < 0) { 2847 MPU401_INFO_IRQ_HOOK,
2848 -1, &chip->rmidi)) < 0) {
2848 printk(KERN_WARNING "es1968: skipping MPU-401 MIDI support..\n"); 2849 printk(KERN_WARNING "es1968: skipping MPU-401 MIDI support..\n");
2849 } 2850 }
2850 } 2851 }
diff --git a/sound/pci/fm801.c b/sound/pci/fm801.c
index f9123f09e83e..c55b1b319b74 100644
--- a/sound/pci/fm801.c
+++ b/sound/pci/fm801.c
@@ -1306,8 +1306,9 @@ static int __devinit snd_card_fm801_probe(struct pci_dev *pci,
1306 } 1306 }
1307 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_FM801, 1307 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_FM801,
1308 FM801_REG(chip, MPU401_DATA), 1308 FM801_REG(chip, MPU401_DATA),
1309 MPU401_INFO_INTEGRATED, 1309 MPU401_INFO_INTEGRATED |
1310 chip->irq, 0, &chip->rmidi)) < 0) { 1310 MPU401_INFO_IRQ_HOOK,
1311 -1, &chip->rmidi)) < 0) {
1311 snd_card_free(card); 1312 snd_card_free(card);
1312 return err; 1313 return err;
1313 } 1314 }
diff --git a/sound/pci/ice1712/ice1712.c b/sound/pci/ice1712/ice1712.c
index 0ccc0eb75775..8531b983f3af 100644
--- a/sound/pci/ice1712/ice1712.c
+++ b/sound/pci/ice1712/ice1712.c
@@ -2748,8 +2748,9 @@ static int __devinit snd_ice1712_probe(struct pci_dev *pci,
2748 if (!c->no_mpu401) { 2748 if (!c->no_mpu401) {
2749 err = snd_mpu401_uart_new(card, 0, MPU401_HW_ICE1712, 2749 err = snd_mpu401_uart_new(card, 0, MPU401_HW_ICE1712,
2750 ICEREG(ice, MPU1_CTRL), 2750 ICEREG(ice, MPU1_CTRL),
2751 (c->mpu401_1_info_flags | MPU401_INFO_INTEGRATED), 2751 c->mpu401_1_info_flags |
2752 ice->irq, 0, &ice->rmidi[0]); 2752 MPU401_INFO_INTEGRATED | MPU401_INFO_IRQ_HOOK,
2753 -1, &ice->rmidi[0]);
2753 if (err < 0) { 2754 if (err < 0) {
2754 snd_card_free(card); 2755 snd_card_free(card);
2755 return err; 2756 return err;
@@ -2764,8 +2765,9 @@ static int __devinit snd_ice1712_probe(struct pci_dev *pci,
2764 /* 2nd port used */ 2765 /* 2nd port used */
2765 err = snd_mpu401_uart_new(card, 1, MPU401_HW_ICE1712, 2766 err = snd_mpu401_uart_new(card, 1, MPU401_HW_ICE1712,
2766 ICEREG(ice, MPU2_CTRL), 2767 ICEREG(ice, MPU2_CTRL),
2767 (c->mpu401_2_info_flags | MPU401_INFO_INTEGRATED), 2768 c->mpu401_2_info_flags |
2768 ice->irq, 0, &ice->rmidi[1]); 2769 MPU401_INFO_INTEGRATED | MPU401_INFO_IRQ_HOOK,
2770 -1, &ice->rmidi[1]);
2769 2771
2770 if (err < 0) { 2772 if (err < 0) {
2771 snd_card_free(card); 2773 snd_card_free(card);
diff --git a/sound/pci/maestro3.c b/sound/pci/maestro3.c
index 0378126e6272..2fd4bf2d6653 100644
--- a/sound/pci/maestro3.c
+++ b/sound/pci/maestro3.c
@@ -2820,8 +2820,8 @@ snd_m3_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
2820 /* TODO enable MIDI IRQ and I/O */ 2820 /* TODO enable MIDI IRQ and I/O */
2821 err = snd_mpu401_uart_new(chip->card, 0, MPU401_HW_MPU401, 2821 err = snd_mpu401_uart_new(chip->card, 0, MPU401_HW_MPU401,
2822 chip->iobase + MPU401_DATA_PORT, 2822 chip->iobase + MPU401_DATA_PORT,
2823 MPU401_INFO_INTEGRATED, 2823 MPU401_INFO_INTEGRATED | MPU401_INFO_IRQ_HOOK,
2824 chip->irq, 0, &chip->rmidi); 2824 -1, &chip->rmidi);
2825 if (err < 0) 2825 if (err < 0)
2826 printk(KERN_WARNING "maestro3: no MIDI support.\n"); 2826 printk(KERN_WARNING "maestro3: no MIDI support.\n");
2827#endif 2827#endif
diff --git a/sound/pci/oxygen/oxygen_lib.c b/sound/pci/oxygen/oxygen_lib.c
index 82311fcb86f6..53e5508abcbf 100644
--- a/sound/pci/oxygen/oxygen_lib.c
+++ b/sound/pci/oxygen/oxygen_lib.c
@@ -678,15 +678,15 @@ int oxygen_pci_probe(struct pci_dev *pci, int index, char *id,
678 goto err_card; 678 goto err_card;
679 679
680 if (chip->model.device_config & (MIDI_OUTPUT | MIDI_INPUT)) { 680 if (chip->model.device_config & (MIDI_OUTPUT | MIDI_INPUT)) {
681 unsigned int info_flags = MPU401_INFO_INTEGRATED; 681 unsigned int info_flags =
682 MPU401_INFO_INTEGRATED | MPU401_INFO_IRQ_HOOK;
682 if (chip->model.device_config & MIDI_OUTPUT) 683 if (chip->model.device_config & MIDI_OUTPUT)
683 info_flags |= MPU401_INFO_OUTPUT; 684 info_flags |= MPU401_INFO_OUTPUT;
684 if (chip->model.device_config & MIDI_INPUT) 685 if (chip->model.device_config & MIDI_INPUT)
685 info_flags |= MPU401_INFO_INPUT; 686 info_flags |= MPU401_INFO_INPUT;
686 err = snd_mpu401_uart_new(card, 0, MPU401_HW_CMIPCI, 687 err = snd_mpu401_uart_new(card, 0, MPU401_HW_CMIPCI,
687 chip->addr + OXYGEN_MPU401, 688 chip->addr + OXYGEN_MPU401,
688 info_flags, 0, 0, 689 info_flags, -1, &chip->midi);
689 &chip->midi);
690 if (err < 0) 690 if (err < 0)
691 goto err_card; 691 goto err_card;
692 } 692 }
diff --git a/sound/pci/riptide/riptide.c b/sound/pci/riptide/riptide.c
index e34ae14908b3..88cc776aa38b 100644
--- a/sound/pci/riptide/riptide.c
+++ b/sound/pci/riptide/riptide.c
@@ -2109,7 +2109,7 @@ snd_card_riptide_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
2109 val = mpu_port[dev]; 2109 val = mpu_port[dev];
2110 pci_write_config_word(chip->pci, PCI_EXT_MPU_Base, val); 2110 pci_write_config_word(chip->pci, PCI_EXT_MPU_Base, val);
2111 err = snd_mpu401_uart_new(card, 0, MPU401_HW_RIPTIDE, 2111 err = snd_mpu401_uart_new(card, 0, MPU401_HW_RIPTIDE,
2112 val, 0, chip->irq, 0, 2112 val, MPU401_INFO_IRQ_HOOK, -1,
2113 &chip->rmidi); 2113 &chip->rmidi);
2114 if (err < 0) 2114 if (err < 0)
2115 snd_printk(KERN_WARNING 2115 snd_printk(KERN_WARNING
diff --git a/sound/pci/sonicvibes.c b/sound/pci/sonicvibes.c
index 2571a67b389a..c5008166cf1f 100644
--- a/sound/pci/sonicvibes.c
+++ b/sound/pci/sonicvibes.c
@@ -1493,9 +1493,10 @@ static int __devinit snd_sonic_probe(struct pci_dev *pci,
1493 return err; 1493 return err;
1494 } 1494 }
1495 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_SONICVIBES, 1495 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_SONICVIBES,
1496 sonic->midi_port, MPU401_INFO_INTEGRATED, 1496 sonic->midi_port,
1497 sonic->irq, 0, 1497 MPU401_INFO_INTEGRATED |
1498 &midi_uart)) < 0) { 1498 MPU401_INFO_IRQ_HOOK,
1499 -1, &midi_uart)) < 0) {
1499 snd_card_free(card); 1500 snd_card_free(card);
1500 return err; 1501 return err;
1501 } 1502 }
diff --git a/sound/pci/trident/trident.c b/sound/pci/trident/trident.c
index d8a128f6fc02..5e707effdc7c 100644
--- a/sound/pci/trident/trident.c
+++ b/sound/pci/trident/trident.c
@@ -148,8 +148,9 @@ static int __devinit snd_trident_probe(struct pci_dev *pci,
148 if (trident->device != TRIDENT_DEVICE_ID_SI7018 && 148 if (trident->device != TRIDENT_DEVICE_ID_SI7018 &&
149 (err = snd_mpu401_uart_new(card, 0, MPU401_HW_TRID4DWAVE, 149 (err = snd_mpu401_uart_new(card, 0, MPU401_HW_TRID4DWAVE,
150 trident->midi_port, 150 trident->midi_port,
151 MPU401_INFO_INTEGRATED, 151 MPU401_INFO_INTEGRATED |
152 trident->irq, 0, &trident->rmidi)) < 0) { 152 MPU401_INFO_IRQ_HOOK,
153 -1, &trident->rmidi)) < 0) {
153 snd_card_free(card); 154 snd_card_free(card);
154 return err; 155 return err;
155 } 156 }
diff --git a/sound/pci/via82xx.c b/sound/pci/via82xx.c
index f03fd620a2a0..35d5f4313d99 100644
--- a/sound/pci/via82xx.c
+++ b/sound/pci/via82xx.c
@@ -2068,8 +2068,9 @@ static int __devinit snd_via686_init_misc(struct via82xx *chip)
2068 pci_write_config_byte(chip->pci, VIA_PNP_CONTROL, legacy_cfg); 2068 pci_write_config_byte(chip->pci, VIA_PNP_CONTROL, legacy_cfg);
2069 if (chip->mpu_res) { 2069 if (chip->mpu_res) {
2070 if (snd_mpu401_uart_new(chip->card, 0, MPU401_HW_VIA686A, 2070 if (snd_mpu401_uart_new(chip->card, 0, MPU401_HW_VIA686A,
2071 mpu_port, MPU401_INFO_INTEGRATED, 2071 mpu_port, MPU401_INFO_INTEGRATED |
2072 chip->irq, 0, &chip->rmidi) < 0) { 2072 MPU401_INFO_IRQ_HOOK, -1,
2073 &chip->rmidi) < 0) {
2073 printk(KERN_WARNING "unable to initialize MPU-401" 2074 printk(KERN_WARNING "unable to initialize MPU-401"
2074 " at 0x%lx, skipping\n", mpu_port); 2075 " at 0x%lx, skipping\n", mpu_port);
2075 legacy &= ~VIA_FUNC_ENABLE_MIDI; 2076 legacy &= ~VIA_FUNC_ENABLE_MIDI;
diff --git a/sound/pci/ymfpci/ymfpci.c b/sound/pci/ymfpci/ymfpci.c
index 511d57653124..3253b04da184 100644
--- a/sound/pci/ymfpci/ymfpci.c
+++ b/sound/pci/ymfpci/ymfpci.c
@@ -305,8 +305,9 @@ static int __devinit snd_card_ymfpci_probe(struct pci_dev *pci,
305 if (chip->mpu_res) { 305 if (chip->mpu_res) {
306 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_YMFPCI, 306 if ((err = snd_mpu401_uart_new(card, 0, MPU401_HW_YMFPCI,
307 mpu_port[dev], 307 mpu_port[dev],
308 MPU401_INFO_INTEGRATED, 308 MPU401_INFO_INTEGRATED |
309 pci->irq, 0, &chip->rawmidi)) < 0) { 309 MPU401_INFO_IRQ_HOOK,
310 -1, &chip->rawmidi)) < 0) {
310 printk(KERN_WARNING "ymfpci: cannot initialize MPU401 at 0x%lx, skipping...\n", mpu_port[dev]); 311 printk(KERN_WARNING "ymfpci: cannot initialize MPU401 at 0x%lx, skipping...\n", mpu_port[dev]);
311 legacy_ctrl &= ~YMFPCI_LEGACY_MIEN; /* disable MPU401 irq */ 312 legacy_ctrl &= ~YMFPCI_LEGACY_MIEN; /* disable MPU401 irq */
312 pci_write_config_word(pci, PCIR_DSXG_LEGACY, legacy_ctrl); 313 pci_write_config_word(pci, PCIR_DSXG_LEGACY, legacy_ctrl);