summaryrefslogtreecommitdiffstats
path: root/sound/pci/ctxfi
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2009-06-08 21:31:50 +0200
committerTakashi Iwai <tiwai@suse.de>2009-06-08 21:32:26 +0200
commit04145f2bfbc3ac4dbb71fa085b82380444d50b4f (patch)
tree28d6bf833d44169a47700795db15b020a8ec13f3 /sound/pci/ctxfi
parent09521d2e3edd0bf02b66e5b8c13f1559f2d6958a (diff)
downloadlinux-04145f2bfbc3ac4dbb71fa085b82380444d50b4f.tar.bz2
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.c9
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 @@
#include <linux/slab.h>
#include <linux/math64.h>
+#include <linux/moduleparam.h>
#include <sound/core.h>
#include <sound/pcm.h>
#include "ctatc.h"
#include "cthardware.h"
#include "cttimer.h"
+static int use_system_timer;
+MODULE_PARM_DESC(use_system_timer, "Foce to use system-timer");
+module_param(use_system_timer, bool, S_IRUGO);
+
struct ct_timer_ops {
void (*init)(struct ct_timer_instance *);
void (*prepare)(struct ct_timer_instance *);
@@ -390,8 +395,6 @@ void ct_timer_instance_free(struct ct_timer_instance *ti)
* timer manager
*/
-#define USE_SYSTEM_TIMER 0
-
static void ct_timer_interrupt(void *data, unsigned int status)
{
struct ct_timer *timer = data;
@@ -415,7 +418,7 @@ struct ct_timer *ct_timer_new(struct ct_atc *atc)
INIT_LIST_HEAD(&atimer->running_head);
atimer->atc = atc;
hw = atc->hw;
- if (!USE_SYSTEM_TIMER && hw->set_timer_irq) {
+ if (!use_system_timer && hw->set_timer_irq) {
snd_printd(KERN_INFO "ctxfi: Use xfi-native timer\n");
atimer->ops = &ct_xfitimer_ops;
hw->irq_callback_data = atimer;