* [PATCH] hdsp ghost midi device fix
@ 2005-01-28 17:17 thomas charbonnel
2005-01-31 13:41 ` Takashi Iwai
0 siblings, 1 reply; 2+ messages in thread
From: thomas charbonnel @ 2005-01-28 17:17 UTC (permalink / raw)
To: alsa-devel
[-- Attachment #1: Type: text/plain, Size: 364 bytes --]
Hi,
The following patch, on top of the patches I submitted yesterday,
prevents a ghost midi device to be created on cards with only one midi
I/O (Multiface and HDSP9632).
It closes the ALSA bug #0000286.
Thomas
ChangeLog:
* Prevents the creation of a second midi device for cards with only
one midi I/O
Signed-off-by: Thomas Charbonnel <thomas@undata.org>
[-- Attachment #2: hdsp_midi_dev_fix.patch --]
[-- Type: text/x-patch, Size: 1198 bytes --]
--- hdsp.c.old 2005-01-28 17:42:27.000000000 +0100
+++ hdsp.c 2005-01-28 18:15:35.000000000 +0100
@@ -3670,7 +3670,7 @@
snd_hdsp_midi_input_read (&hdsp->midi[0]);
}
}
- if (midi1 && midi1status) {
+ if (hdsp->io_type != Multiface && hdsp->io_type != H9632 && midi1 && midi1status) {
if (hdsp->use_midi_tasklet) {
/* we disable interrupts for this input until processing is done */
hdsp->control_register &= ~HDSP_Midi1InterruptEnable;
@@ -4827,10 +4827,11 @@
return err;
}
-
- if ((err = snd_hdsp_create_midi(card, hdsp, 1)) < 0) {
- snd_printk("Hammerfall-DSP: Error creating second midi interface\n");
- return err;
+ if (hdsp->io_type == Digiface || hdsp->io_type == H9652) {
+ if ((err = snd_hdsp_create_midi(card, hdsp, 1)) < 0) {
+ snd_printk("Hammerfall-DSP: Error creating second midi interface\n");
+ return err;
+ }
}
if ((err = snd_hdsp_create_controls(card, hdsp)) < 0) {
@@ -4967,6 +4968,8 @@
hdsp->midi[1].input = NULL;
hdsp->midi[0].output = NULL;
hdsp->midi[1].output = NULL;
+ hdsp->midi[0].pending = 0;
+ hdsp->midi[1].pending = 0;
spin_lock_init(&hdsp->midi[0].lock);
spin_lock_init(&hdsp->midi[1].lock);
hdsp->iobase = NULL;
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] hdsp ghost midi device fix
2005-01-28 17:17 [PATCH] hdsp ghost midi device fix thomas charbonnel
@ 2005-01-31 13:41 ` Takashi Iwai
0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2005-01-31 13:41 UTC (permalink / raw)
To: thomas charbonnel; +Cc: alsa-devel
At Fri, 28 Jan 2005 18:17:39 +0100,
thomas charbonnel wrote:
>
> Hi,
>
> The following patch, on top of the patches I submitted yesterday,
> prevents a ghost midi device to be created on cards with only one midi
> I/O (Multiface and HDSP9632).
> It closes the ALSA bug #0000286.
>
> Thomas
>
> ChangeLog:
> * Prevents the creation of a second midi device for cards with only
> one midi I/O
>
> Signed-off-by: Thomas Charbonnel <thomas@undata.org>
Thanks. Applied to CVS.
Takashi
-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-01-31 13:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-01-28 17:17 [PATCH] hdsp ghost midi device fix thomas charbonnel
2005-01-31 13:41 ` Takashi Iwai
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.