lkml.org 
[lkml]   [2001]   [Jan]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectRevised patch: Linux 2.4.0 ad1848 mixer ownership
Date
Hi,

This is a revised version of my ad1848 patch; instead of modifying the
static structures, update the "owner" fields in the audio_devs[] and
mixer_devs[] structures instead.

Chris
--- linux-vanilla/drivers/sound/ad1848.c Fri Aug 11 16:26:43 2000
+++ linux-2.4.0-ac3/drivers/sound/ad1848.c Mon Jan 8 14:32:39 2001
@@ -1900,9 +1900,6 @@
if(portc==NULL)
return -1;

- if (owner)
- ad1848_audio_driver.owner = owner;
-
if ((my_dev = sound_install_audiodrv(AUDIO_DRIVER_VERSION,
dev_name,
&ad1848_audio_driver,
@@ -1920,6 +1917,8 @@

audio_devs[my_dev]->portc = portc;
audio_devs[my_dev]->mixer_dev = -1;
+ if (owner)
+ audio_devs[my_dev]->d->owner = owner;
memset((char *) portc, 0, sizeof(*portc));

nr_ad1848_devs++;
@@ -1986,6 +1985,7 @@
if (sound_alloc_dma(dma_capture, devc->name))
printk(KERN_WARNING "ad1848.c: Can't allocate DMA%d\n", dma_capture);
}
+
if ((e = sound_install_mixer(MIXER_DRIVER_VERSION,
dev_name,
&ad1848_mixer_operations,
@@ -1993,6 +1993,8 @@
devc)) >= 0)
{
audio_devs[my_dev]->mixer_dev = e;
+ if (owner)
+ mixer_devs[e]->owner = owner;
}
return my_dev;
}
\
 
 \ /
  Last update: 2005-03-22 12:52    [W:0.022 / U:0.672 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site