diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-06-08 15:31:50 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-06-08 15:32:26 -0400 |
commit | 04145f2bfbc3ac4dbb71fa085b82380444d50b4f (patch) | |
tree | 28d6bf833d44169a47700795db15b020a8ec13f3 /sound/pci/ctxfi | |
parent | 09521d2e3edd0bf02b66e5b8c13f1559f2d6958a (diff) |
ALSA: ctxfi - Add use_system_timer module option
Added use_system_timer module option to force to use the system timer
instead of emu20k1 timer irq for debugging.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/ctxfi')
-rw-r--r-- | sound/pci/ctxfi/cttimer.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sound/pci/ctxfi/cttimer.c b/sound/pci/ctxfi/cttimer.c index ec869a4fe2b3..779c6c3591a5 100644 --- a/sound/pci/ctxfi/cttimer.c +++ b/sound/pci/ctxfi/cttimer.c | |||
@@ -8,12 +8,17 @@ | |||
8 | 8 | ||
9 | #include <linux/slab.h> | 9 | #include <linux/slab.h> |
10 | #include <linux/math64.h> | 10 | #include <linux/math64.h> |
11 | #include <linux/moduleparam.h> | ||
11 | #include <sound/core.h> | 12 | #include <sound/core.h> |
12 | #include <sound/pcm.h> | 13 | #include <sound/pcm.h> |
13 | #include "ctatc.h" | 14 | #include "ctatc.h" |
14 | #include "cthardware.h" | 15 | #include "cthardware.h" |
15 | #include "cttimer.h" | 16 | #include "cttimer.h" |
16 | 17 | ||
18 | static int use_system_timer; | ||
19 | MODULE_PARM_DESC(use_system_timer, "Foce to use system-timer"); | ||
20 | module_param(use_system_timer, bool, S_IRUGO); | ||
21 | |||
17 | struct ct_timer_ops { | 22 | struct ct_timer_ops { |
18 | void (*init)(struct ct_timer_instance *); | 23 | void (*init)(struct ct_timer_instance *); |
19 | void (*prepare)(struct ct_timer_instance *); | 24 | void (*prepare)(struct ct_timer_instance *); |
@@ -390,8 +395,6 @@ void ct_timer_instance_free(struct ct_timer_instance *ti) | |||
390 | * timer manager | 395 | * timer manager |
391 | */ | 396 | */ |
392 | 397 | ||
393 | #define USE_SYSTEM_TIMER 0 | ||
394 | |||
395 | static void ct_timer_interrupt(void *data, unsigned int status) | 398 | static void ct_timer_interrupt(void *data, unsigned int status) |
396 | { | 399 | { |
397 | struct ct_timer *timer = data; | 400 | struct ct_timer *timer = data; |
@@ -415,7 +418,7 @@ struct ct_timer *ct_timer_new(struct ct_atc *atc) | |||
415 | INIT_LIST_HEAD(&atimer->running_head); | 418 | INIT_LIST_HEAD(&atimer->running_head); |
416 | atimer->atc = atc; | 419 | atimer->atc = atc; |
417 | hw = atc->hw; | 420 | hw = atc->hw; |
418 | if (!USE_SYSTEM_TIMER && hw->set_timer_irq) { | 421 | if (!use_system_timer && hw->set_timer_irq) { |
419 | snd_printd(KERN_INFO "ctxfi: Use xfi-native timer\n"); | 422 | snd_printd(KERN_INFO "ctxfi: Use xfi-native timer\n"); |
420 | atimer->ops = &ct_xfitimer_ops; | 423 | atimer->ops = &ct_xfitimer_ops; |
421 | hw->irq_callback_data = atimer; | 424 | hw->irq_callback_data = atimer; |