--- hrtimer.c 2009-11-10 01:32:31.000000000 +0100 +++ /tmp/hrtimer.c 2009-12-09 19:10:34.000000000 +0100 @@ -36,12 +36,13 @@ struct snd_hrtimer { struct snd_timer *timer; - struct hrtimer hrt; + struct tasklet_hrtimer thrt; }; static enum hrtimer_restart snd_hrtimer_callback(struct hrtimer *hrt) { - struct snd_hrtimer *stime = container_of(hrt, struct snd_hrtimer, hrt); + struct tasklet_hrtimer *thrt = container_of(hrt, struct tasklet_hrtimer, timer); + struct snd_hrtimer *stime = container_of(thrt, struct snd_hrtimer, thrt); struct snd_timer *t = stime->timer; hrtimer_forward_now(hrt, ns_to_ktime(t->sticks * resolution)); snd_timer_interrupt(stime->timer, t->sticks); @@ -55,9 +56,8 @@ stime = kmalloc(sizeof(*stime), GFP_KERNEL); if (!stime) return -ENOMEM; - hrtimer_init(&stime->hrt, CLOCK_MONOTONIC, HRTIMER_MODE_REL); + tasklet_hrtimer_init(&stime->thrt, snd_hrtimer_callback, CLOCK_MONOTONIC, HRTIMER_MODE_REL); stime->timer = t; - stime->hrt.function = snd_hrtimer_callback; t->private_data = stime; return 0; } @@ -67,7 +67,7 @@ struct snd_hrtimer *stime = t->private_data; if (stime) { - hrtimer_cancel(&stime->hrt); + tasklet_hrtimer_cancel(&stime->thrt); kfree(stime); t->private_data = NULL; } @@ -78,7 +78,7 @@ { struct snd_hrtimer *stime = t->private_data; - hrtimer_start(&stime->hrt, ns_to_ktime(t->sticks * resolution), + tasklet_hrtimer_start(&stime->thrt, ns_to_ktime(t->sticks * resolution), HRTIMER_MODE_REL); return 0; } @@ -87,12 +87,14 @@ { struct snd_hrtimer *stime = t->private_data; - hrtimer_cancel(&stime->hrt); + tasklet_hrtimer_cancel(&stime->thrt); return 0; } static struct snd_timer_hardware hrtimer_hw = { - .flags = SNDRV_TIMER_HW_AUTO, + .flags = SNDRV_TIMER_HW_AUTO |\ + SNDRV_TIMER_HW_FIRST |\ + SNDRV_TIMER_HW_TASKLET, .open = snd_hrtimer_open, .close = snd_hrtimer_close, .start = snd_hrtimer_start,