diff options
author | Jeff Garzik <jeff@garzik.org> | 2006-12-07 04:57:19 -0500 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-12-07 04:57:19 -0500 |
commit | 8d1413b28033c49c7f1a4d320e815d7a5531acee (patch) | |
tree | b37281abef014cd60803b81c100388d7a475d49e /sound | |
parent | ed25ffa16434724f5ed825aa48734c7f3aefa203 (diff) | |
parent | 620034c84d1d939717bdfbe02c51a3fee43541c3 (diff) |
Merge branch 'master' into upstream
Conflicts:
drivers/net/netxen/netxen_nic.h
drivers/net/netxen/netxen_nic_main.c
Diffstat (limited to 'sound')
-rw-r--r-- | sound/aoa/aoa-gpio.h | 2 | ||||
-rw-r--r-- | sound/aoa/core/snd-aoa-gpio-feature.c | 16 | ||||
-rw-r--r-- | sound/aoa/core/snd-aoa-gpio-pmf.c | 16 | ||||
-rw-r--r-- | sound/i2c/other/ak4114.c | 8 | ||||
-rw-r--r-- | sound/pci/ac97/ac97_codec.c | 7 | ||||
-rw-r--r-- | sound/pci/hda/hda_codec.c | 10 | ||||
-rw-r--r-- | sound/pci/hda/hda_local.h | 1 | ||||
-rw-r--r-- | sound/pcmcia/pdaudiocf/pdaudiocf.c | 24 | ||||
-rw-r--r-- | sound/pcmcia/vx/vxpocket.c | 26 | ||||
-rw-r--r-- | sound/ppc/tumbler.c | 8 |
10 files changed, 38 insertions, 80 deletions
diff --git a/sound/aoa/aoa-gpio.h b/sound/aoa/aoa-gpio.h index 3a61f3115573..ee64f5de8966 100644 --- a/sound/aoa/aoa-gpio.h +++ b/sound/aoa/aoa-gpio.h | |||
@@ -59,10 +59,10 @@ struct gpio_methods { | |||
59 | }; | 59 | }; |
60 | 60 | ||
61 | struct gpio_notification { | 61 | struct gpio_notification { |
62 | struct delayed_work work; | ||
62 | notify_func_t notify; | 63 | notify_func_t notify; |
63 | void *data; | 64 | void *data; |
64 | void *gpio_private; | 65 | void *gpio_private; |
65 | struct work_struct work; | ||
66 | struct mutex mutex; | 66 | struct mutex mutex; |
67 | }; | 67 | }; |
68 | 68 | ||
diff --git a/sound/aoa/core/snd-aoa-gpio-feature.c b/sound/aoa/core/snd-aoa-gpio-feature.c index 40eb47eccf9a..2b03bc798bcb 100644 --- a/sound/aoa/core/snd-aoa-gpio-feature.c +++ b/sound/aoa/core/snd-aoa-gpio-feature.c | |||
@@ -195,9 +195,10 @@ static void ftr_gpio_all_amps_restore(struct gpio_runtime *rt) | |||
195 | ftr_gpio_set_lineout(rt, (s>>2)&1); | 195 | ftr_gpio_set_lineout(rt, (s>>2)&1); |
196 | } | 196 | } |
197 | 197 | ||
198 | static void ftr_handle_notify(void *data) | 198 | static void ftr_handle_notify(struct work_struct *work) |
199 | { | 199 | { |
200 | struct gpio_notification *notif = data; | 200 | struct gpio_notification *notif = |
201 | container_of(work, struct gpio_notification, work.work); | ||
201 | 202 | ||
202 | mutex_lock(¬if->mutex); | 203 | mutex_lock(¬if->mutex); |
203 | if (notif->notify) | 204 | if (notif->notify) |
@@ -253,12 +254,9 @@ static void ftr_gpio_init(struct gpio_runtime *rt) | |||
253 | 254 | ||
254 | ftr_gpio_all_amps_off(rt); | 255 | ftr_gpio_all_amps_off(rt); |
255 | rt->implementation_private = 0; | 256 | rt->implementation_private = 0; |
256 | INIT_WORK(&rt->headphone_notify.work, ftr_handle_notify, | 257 | INIT_DELAYED_WORK(&rt->headphone_notify.work, ftr_handle_notify); |
257 | &rt->headphone_notify); | 258 | INIT_DELAYED_WORK(&rt->line_in_notify.work, ftr_handle_notify); |
258 | INIT_WORK(&rt->line_in_notify.work, ftr_handle_notify, | 259 | INIT_DELAYED_WORK(&rt->line_out_notify.work, ftr_handle_notify); |
259 | &rt->line_in_notify); | ||
260 | INIT_WORK(&rt->line_out_notify.work, ftr_handle_notify, | ||
261 | &rt->line_out_notify); | ||
262 | mutex_init(&rt->headphone_notify.mutex); | 260 | mutex_init(&rt->headphone_notify.mutex); |
263 | mutex_init(&rt->line_in_notify.mutex); | 261 | mutex_init(&rt->line_in_notify.mutex); |
264 | mutex_init(&rt->line_out_notify.mutex); | 262 | mutex_init(&rt->line_out_notify.mutex); |
@@ -287,7 +285,7 @@ static irqreturn_t ftr_handle_notify_irq(int xx, void *data) | |||
287 | { | 285 | { |
288 | struct gpio_notification *notif = data; | 286 | struct gpio_notification *notif = data; |
289 | 287 | ||
290 | schedule_work(¬if->work); | 288 | schedule_delayed_work(¬if->work, 0); |
291 | 289 | ||
292 | return IRQ_HANDLED; | 290 | return IRQ_HANDLED; |
293 | } | 291 | } |
diff --git a/sound/aoa/core/snd-aoa-gpio-pmf.c b/sound/aoa/core/snd-aoa-gpio-pmf.c index 2836c3218391..5ca2220eac7d 100644 --- a/sound/aoa/core/snd-aoa-gpio-pmf.c +++ b/sound/aoa/core/snd-aoa-gpio-pmf.c | |||
@@ -69,9 +69,10 @@ static void pmf_gpio_all_amps_restore(struct gpio_runtime *rt) | |||
69 | pmf_gpio_set_lineout(rt, (s>>2)&1); | 69 | pmf_gpio_set_lineout(rt, (s>>2)&1); |
70 | } | 70 | } |
71 | 71 | ||
72 | static void pmf_handle_notify(void *data) | 72 | static void pmf_handle_notify(struct work_struct *work) |
73 | { | 73 | { |
74 | struct gpio_notification *notif = data; | 74 | struct gpio_notification *notif = |
75 | container_of(work, struct gpio_notification, work.work); | ||
75 | 76 | ||
76 | mutex_lock(¬if->mutex); | 77 | mutex_lock(¬if->mutex); |
77 | if (notif->notify) | 78 | if (notif->notify) |
@@ -83,12 +84,9 @@ static void pmf_gpio_init(struct gpio_runtime *rt) | |||
83 | { | 84 | { |
84 | pmf_gpio_all_amps_off(rt); | 85 | pmf_gpio_all_amps_off(rt); |
85 | rt->implementation_private = 0; | 86 | rt->implementation_private = 0; |
86 | INIT_WORK(&rt->headphone_notify.work, pmf_handle_notify, | 87 | INIT_DELAYED_WORK(&rt->headphone_notify.work, pmf_handle_notify); |
87 | &rt->headphone_notify); | 88 | INIT_DELAYED_WORK(&rt->line_in_notify.work, pmf_handle_notify); |
88 | INIT_WORK(&rt->line_in_notify.work, pmf_handle_notify, | 89 | INIT_DELAYED_WORK(&rt->line_out_notify.work, pmf_handle_notify); |
89 | &rt->line_in_notify); | ||
90 | INIT_WORK(&rt->line_out_notify.work, pmf_handle_notify, | ||
91 | &rt->line_out_notify); | ||
92 | mutex_init(&rt->headphone_notify.mutex); | 90 | mutex_init(&rt->headphone_notify.mutex); |
93 | mutex_init(&rt->line_in_notify.mutex); | 91 | mutex_init(&rt->line_in_notify.mutex); |
94 | mutex_init(&rt->line_out_notify.mutex); | 92 | mutex_init(&rt->line_out_notify.mutex); |
@@ -129,7 +127,7 @@ static void pmf_handle_notify_irq(void *data) | |||
129 | { | 127 | { |
130 | struct gpio_notification *notif = data; | 128 | struct gpio_notification *notif = data; |
131 | 129 | ||
132 | schedule_work(¬if->work); | 130 | schedule_delayed_work(¬if->work, 0); |
133 | } | 131 | } |
134 | 132 | ||
135 | static int pmf_set_notify(struct gpio_runtime *rt, | 133 | static int pmf_set_notify(struct gpio_runtime *rt, |
diff --git a/sound/i2c/other/ak4114.c b/sound/i2c/other/ak4114.c index 12ffffc9e814..d2f2c5078e65 100644 --- a/sound/i2c/other/ak4114.c +++ b/sound/i2c/other/ak4114.c | |||
@@ -35,7 +35,7 @@ MODULE_LICENSE("GPL"); | |||
35 | 35 | ||
36 | #define AK4114_ADDR 0x00 /* fixed address */ | 36 | #define AK4114_ADDR 0x00 /* fixed address */ |
37 | 37 | ||
38 | static void ak4114_stats(void *); | 38 | static void ak4114_stats(struct work_struct *work); |
39 | 39 | ||
40 | static void reg_write(struct ak4114 *ak4114, unsigned char reg, unsigned char val) | 40 | static void reg_write(struct ak4114 *ak4114, unsigned char reg, unsigned char val) |
41 | { | 41 | { |
@@ -158,7 +158,7 @@ void snd_ak4114_reinit(struct ak4114 *chip) | |||
158 | reg_write(chip, AK4114_REG_PWRDN, old | AK4114_RST | AK4114_PWN); | 158 | reg_write(chip, AK4114_REG_PWRDN, old | AK4114_RST | AK4114_PWN); |
159 | /* bring up statistics / event queing */ | 159 | /* bring up statistics / event queing */ |
160 | chip->init = 0; | 160 | chip->init = 0; |
161 | INIT_WORK(&chip->work, ak4114_stats, chip); | 161 | INIT_DELAYED_WORK(&chip->work, ak4114_stats); |
162 | queue_delayed_work(chip->workqueue, &chip->work, HZ / 10); | 162 | queue_delayed_work(chip->workqueue, &chip->work, HZ / 10); |
163 | } | 163 | } |
164 | 164 | ||
@@ -561,9 +561,9 @@ int snd_ak4114_check_rate_and_errors(struct ak4114 *ak4114, unsigned int flags) | |||
561 | return res; | 561 | return res; |
562 | } | 562 | } |
563 | 563 | ||
564 | static void ak4114_stats(void *data) | 564 | static void ak4114_stats(struct work_struct *work) |
565 | { | 565 | { |
566 | struct ak4114 *chip = (struct ak4114 *)data; | 566 | struct ak4114 *chip = container_of(work, struct ak4114, work.work); |
567 | 567 | ||
568 | if (chip->init) | 568 | if (chip->init) |
569 | return; | 569 | return; |
diff --git a/sound/pci/ac97/ac97_codec.c b/sound/pci/ac97/ac97_codec.c index 6577b2325357..7abcb10b2754 100644 --- a/sound/pci/ac97/ac97_codec.c +++ b/sound/pci/ac97/ac97_codec.c | |||
@@ -1927,9 +1927,10 @@ static int snd_ac97_dev_disconnect(struct snd_device *device) | |||
1927 | static struct snd_ac97_build_ops null_build_ops; | 1927 | static struct snd_ac97_build_ops null_build_ops; |
1928 | 1928 | ||
1929 | #ifdef CONFIG_SND_AC97_POWER_SAVE | 1929 | #ifdef CONFIG_SND_AC97_POWER_SAVE |
1930 | static void do_update_power(void *data) | 1930 | static void do_update_power(struct work_struct *work) |
1931 | { | 1931 | { |
1932 | update_power_regs(data); | 1932 | update_power_regs( |
1933 | container_of(work, struct snd_ac97, power_work.work)); | ||
1933 | } | 1934 | } |
1934 | #endif | 1935 | #endif |
1935 | 1936 | ||
@@ -1989,7 +1990,7 @@ int snd_ac97_mixer(struct snd_ac97_bus *bus, struct snd_ac97_template *template, | |||
1989 | mutex_init(&ac97->page_mutex); | 1990 | mutex_init(&ac97->page_mutex); |
1990 | #ifdef CONFIG_SND_AC97_POWER_SAVE | 1991 | #ifdef CONFIG_SND_AC97_POWER_SAVE |
1991 | ac97->power_workq = create_workqueue("ac97"); | 1992 | ac97->power_workq = create_workqueue("ac97"); |
1992 | INIT_WORK(&ac97->power_work, do_update_power, ac97); | 1993 | INIT_DELAYED_WORK(&ac97->power_work, do_update_power); |
1993 | #endif | 1994 | #endif |
1994 | 1995 | ||
1995 | #ifdef CONFIG_PCI | 1996 | #ifdef CONFIG_PCI |
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c index 9c3d7ac08068..71482c15a852 100644 --- a/sound/pci/hda/hda_codec.c +++ b/sound/pci/hda/hda_codec.c | |||
@@ -272,10 +272,11 @@ EXPORT_SYMBOL(snd_hda_queue_unsol_event); | |||
272 | /* | 272 | /* |
273 | * process queueud unsolicited events | 273 | * process queueud unsolicited events |
274 | */ | 274 | */ |
275 | static void process_unsol_events(void *data) | 275 | static void process_unsol_events(struct work_struct *work) |
276 | { | 276 | { |
277 | struct hda_bus *bus = data; | 277 | struct hda_bus_unsolicited *unsol = |
278 | struct hda_bus_unsolicited *unsol = bus->unsol; | 278 | container_of(work, struct hda_bus_unsolicited, work); |
279 | struct hda_bus *bus = unsol->bus; | ||
279 | struct hda_codec *codec; | 280 | struct hda_codec *codec; |
280 | unsigned int rp, caddr, res; | 281 | unsigned int rp, caddr, res; |
281 | 282 | ||
@@ -314,7 +315,8 @@ static int init_unsol_queue(struct hda_bus *bus) | |||
314 | kfree(unsol); | 315 | kfree(unsol); |
315 | return -ENOMEM; | 316 | return -ENOMEM; |
316 | } | 317 | } |
317 | INIT_WORK(&unsol->work, process_unsol_events, bus); | 318 | INIT_WORK(&unsol->work, process_unsol_events); |
319 | unsol->bus = bus; | ||
318 | bus->unsol = unsol; | 320 | bus->unsol = unsol; |
319 | return 0; | 321 | return 0; |
320 | } | 322 | } |
diff --git a/sound/pci/hda/hda_local.h b/sound/pci/hda/hda_local.h index f9416c36396e..9ca1baf860bd 100644 --- a/sound/pci/hda/hda_local.h +++ b/sound/pci/hda/hda_local.h | |||
@@ -206,6 +206,7 @@ struct hda_bus_unsolicited { | |||
206 | /* workqueue */ | 206 | /* workqueue */ |
207 | struct workqueue_struct *workq; | 207 | struct workqueue_struct *workq; |
208 | struct work_struct work; | 208 | struct work_struct work; |
209 | struct hda_bus *bus; | ||
209 | }; | 210 | }; |
210 | 211 | ||
211 | /* | 212 | /* |
diff --git a/sound/pcmcia/pdaudiocf/pdaudiocf.c b/sound/pcmcia/pdaudiocf/pdaudiocf.c index fd3590fcaedb..2d40cc72f236 100644 --- a/sound/pcmcia/pdaudiocf/pdaudiocf.c +++ b/sound/pcmcia/pdaudiocf/pdaudiocf.c | |||
@@ -219,35 +219,15 @@ do { last_fn = (fn); if ((last_ret = (ret)) != 0) goto cs_failed; } while (0) | |||
219 | static int pdacf_config(struct pcmcia_device *link) | 219 | static int pdacf_config(struct pcmcia_device *link) |
220 | { | 220 | { |
221 | struct snd_pdacf *pdacf = link->priv; | 221 | struct snd_pdacf *pdacf = link->priv; |
222 | tuple_t tuple; | ||
223 | cisparse_t *parse = NULL; | ||
224 | u_short buf[32]; | ||
225 | int last_fn, last_ret; | 222 | int last_fn, last_ret; |
226 | 223 | ||
227 | snd_printdd(KERN_DEBUG "pdacf_config called\n"); | 224 | snd_printdd(KERN_DEBUG "pdacf_config called\n"); |
228 | parse = kmalloc(sizeof(*parse), GFP_KERNEL); | ||
229 | if (! parse) { | ||
230 | snd_printk(KERN_ERR "pdacf_config: cannot allocate\n"); | ||
231 | return -ENOMEM; | ||
232 | } | ||
233 | tuple.DesiredTuple = CISTPL_CFTABLE_ENTRY; | ||
234 | tuple.Attributes = 0; | ||
235 | tuple.TupleData = (cisdata_t *)buf; | ||
236 | tuple.TupleDataMax = sizeof(buf); | ||
237 | tuple.TupleOffset = 0; | ||
238 | tuple.DesiredTuple = CISTPL_CONFIG; | ||
239 | CS_CHECK(GetFirstTuple, pcmcia_get_first_tuple(link, &tuple)); | ||
240 | CS_CHECK(GetTupleData, pcmcia_get_tuple_data(link, &tuple)); | ||
241 | CS_CHECK(ParseTuple, pcmcia_parse_tuple(link, &tuple, parse)); | ||
242 | link->conf.ConfigBase = parse->config.base; | ||
243 | link->conf.ConfigIndex = 0x5; | 225 | link->conf.ConfigIndex = 0x5; |
244 | 226 | ||
245 | CS_CHECK(RequestIO, pcmcia_request_io(link, &link->io)); | 227 | CS_CHECK(RequestIO, pcmcia_request_io(link, &link->io)); |
246 | CS_CHECK(RequestIRQ, pcmcia_request_irq(link, &link->irq)); | 228 | CS_CHECK(RequestIRQ, pcmcia_request_irq(link, &link->irq)); |
247 | CS_CHECK(RequestConfiguration, pcmcia_request_configuration(link, &link->conf)); | 229 | CS_CHECK(RequestConfiguration, pcmcia_request_configuration(link, &link->conf)); |
248 | 230 | ||
249 | kfree(parse); | ||
250 | |||
251 | if (snd_pdacf_assign_resources(pdacf, link->io.BasePort1, link->irq.AssignedIRQ) < 0) | 231 | if (snd_pdacf_assign_resources(pdacf, link->io.BasePort1, link->irq.AssignedIRQ) < 0) |
252 | goto failed; | 232 | goto failed; |
253 | 233 | ||
@@ -255,7 +235,6 @@ static int pdacf_config(struct pcmcia_device *link) | |||
255 | return 0; | 235 | return 0; |
256 | 236 | ||
257 | cs_failed: | 237 | cs_failed: |
258 | kfree(parse); | ||
259 | cs_error(link, last_fn, last_ret); | 238 | cs_error(link, last_fn, last_ret); |
260 | failed: | 239 | failed: |
261 | pcmcia_disable_device(link); | 240 | pcmcia_disable_device(link); |
@@ -299,7 +278,8 @@ static int pdacf_resume(struct pcmcia_device *link) | |||
299 | * Module entry points | 278 | * Module entry points |
300 | */ | 279 | */ |
301 | static struct pcmcia_device_id snd_pdacf_ids[] = { | 280 | static struct pcmcia_device_id snd_pdacf_ids[] = { |
302 | PCMCIA_DEVICE_MANF_CARD(0x015d, 0x4c45), | 281 | /* this is too general PCMCIA_DEVICE_MANF_CARD(0x015d, 0x4c45), */ |
282 | PCMCIA_DEVICE_PROD_ID12("Core Sound","PDAudio-CF",0x396d19d2,0x71717b49), | ||
303 | PCMCIA_DEVICE_NULL | 283 | PCMCIA_DEVICE_NULL |
304 | }; | 284 | }; |
305 | MODULE_DEVICE_TABLE(pcmcia, snd_pdacf_ids); | 285 | MODULE_DEVICE_TABLE(pcmcia, snd_pdacf_ids); |
diff --git a/sound/pcmcia/vx/vxpocket.c b/sound/pcmcia/vx/vxpocket.c index 3089fcca800e..d7df59e9c647 100644 --- a/sound/pcmcia/vx/vxpocket.c +++ b/sound/pcmcia/vx/vxpocket.c | |||
@@ -217,34 +217,12 @@ static int vxpocket_config(struct pcmcia_device *link) | |||
217 | { | 217 | { |
218 | struct vx_core *chip = link->priv; | 218 | struct vx_core *chip = link->priv; |
219 | struct snd_vxpocket *vxp = (struct snd_vxpocket *)chip; | 219 | struct snd_vxpocket *vxp = (struct snd_vxpocket *)chip; |
220 | tuple_t tuple; | ||
221 | cisparse_t *parse; | ||
222 | u_short buf[32]; | ||
223 | int last_fn, last_ret; | 220 | int last_fn, last_ret; |
224 | 221 | ||
225 | snd_printdd(KERN_DEBUG "vxpocket_config called\n"); | 222 | snd_printdd(KERN_DEBUG "vxpocket_config called\n"); |
226 | parse = kmalloc(sizeof(*parse), GFP_KERNEL); | ||
227 | if (! parse) { | ||
228 | snd_printk(KERN_ERR "vx: cannot allocate\n"); | ||
229 | return -ENOMEM; | ||
230 | } | ||
231 | tuple.Attributes = 0; | ||
232 | tuple.TupleData = (cisdata_t *)buf; | ||
233 | tuple.TupleDataMax = sizeof(buf); | ||
234 | tuple.TupleOffset = 0; | ||
235 | tuple.DesiredTuple = CISTPL_CONFIG; | ||
236 | CS_CHECK(GetFirstTuple, pcmcia_get_first_tuple(link, &tuple)); | ||
237 | CS_CHECK(GetTupleData, pcmcia_get_tuple_data(link, &tuple)); | ||
238 | CS_CHECK(ParseTuple, pcmcia_parse_tuple(link, &tuple, parse)); | ||
239 | link->conf.ConfigBase = parse->config.base; | ||
240 | link->conf.Present = parse->config.rmask[0]; | ||
241 | 223 | ||
242 | /* redefine hardware record according to the VERSION1 string */ | 224 | /* redefine hardware record according to the VERSION1 string */ |
243 | tuple.DesiredTuple = CISTPL_VERS_1; | 225 | if (!strcmp(link->prod_id[1], "VX-POCKET")) { |
244 | CS_CHECK(GetFirstTuple, pcmcia_get_first_tuple(link, &tuple)); | ||
245 | CS_CHECK(GetTupleData, pcmcia_get_tuple_data(link, &tuple)); | ||
246 | CS_CHECK(ParseTuple, pcmcia_parse_tuple(link, &tuple, parse)); | ||
247 | if (! strcmp(parse->version_1.str + parse->version_1.ofs[1], "VX-POCKET")) { | ||
248 | snd_printdd("VX-pocket is detected\n"); | 226 | snd_printdd("VX-pocket is detected\n"); |
249 | } else { | 227 | } else { |
250 | snd_printdd("VX-pocket 440 is detected\n"); | 228 | snd_printdd("VX-pocket 440 is detected\n"); |
@@ -265,14 +243,12 @@ static int vxpocket_config(struct pcmcia_device *link) | |||
265 | goto failed; | 243 | goto failed; |
266 | 244 | ||
267 | link->dev_node = &vxp->node; | 245 | link->dev_node = &vxp->node; |
268 | kfree(parse); | ||
269 | return 0; | 246 | return 0; |
270 | 247 | ||
271 | cs_failed: | 248 | cs_failed: |
272 | cs_error(link, last_fn, last_ret); | 249 | cs_error(link, last_fn, last_ret); |
273 | failed: | 250 | failed: |
274 | pcmcia_disable_device(link); | 251 | pcmcia_disable_device(link); |
275 | kfree(parse); | ||
276 | return -ENODEV; | 252 | return -ENODEV; |
277 | } | 253 | } |
278 | 254 | ||
diff --git a/sound/ppc/tumbler.c b/sound/ppc/tumbler.c index 2fbe1d183fce..8f074c7936e6 100644 --- a/sound/ppc/tumbler.c +++ b/sound/ppc/tumbler.c | |||
@@ -942,10 +942,11 @@ static void check_mute(struct snd_pmac *chip, struct pmac_gpio *gp, int val, int | |||
942 | } | 942 | } |
943 | 943 | ||
944 | static struct work_struct device_change; | 944 | static struct work_struct device_change; |
945 | static struct snd_pmac *device_change_chip; | ||
945 | 946 | ||
946 | static void device_change_handler(void *self) | 947 | static void device_change_handler(struct work_struct *work) |
947 | { | 948 | { |
948 | struct snd_pmac *chip = self; | 949 | struct snd_pmac *chip = device_change_chip; |
949 | struct pmac_tumbler *mix; | 950 | struct pmac_tumbler *mix; |
950 | int headphone, lineout; | 951 | int headphone, lineout; |
951 | 952 | ||
@@ -1417,7 +1418,8 @@ int __init snd_pmac_tumbler_init(struct snd_pmac *chip) | |||
1417 | chip->resume = tumbler_resume; | 1418 | chip->resume = tumbler_resume; |
1418 | #endif | 1419 | #endif |
1419 | 1420 | ||
1420 | INIT_WORK(&device_change, device_change_handler, (void *)chip); | 1421 | INIT_WORK(&device_change, device_change_handler); |
1422 | device_change_chip = chip; | ||
1421 | 1423 | ||
1422 | #ifdef PMAC_SUPPORT_AUTOMUTE | 1424 | #ifdef PMAC_SUPPORT_AUTOMUTE |
1423 | if ((mix->headphone_irq >=0 || mix->lineout_irq >= 0) | 1425 | if ((mix->headphone_irq >=0 || mix->lineout_irq >= 0) |