aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/cdrom
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2005-09-09 16:10:40 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-09 17:03:48 -0400
commit8d06afab73a75f40ae2864e6c296356bab1ab473 (patch)
tree1d9c8c24a1024a12a4e8df841fba5809fa914356 /drivers/cdrom
parent7c352bdf048811b8128019ffc1e886161e09c11c (diff)
[PATCH] timer initialization cleanup: DEFINE_TIMER
Clean up timer initialization by introducing DEFINE_TIMER a'la DEFINE_SPINLOCK. Build and boot-tested on x86. A similar patch has been been in the -RT tree for some time. Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/cdrom')
-rw-r--r--drivers/cdrom/aztcd.c2
-rw-r--r--drivers/cdrom/gscd.c2
-rw-r--r--drivers/cdrom/optcd.c2
-rw-r--r--drivers/cdrom/sbpcd.c9
-rw-r--r--drivers/cdrom/sjcd.c2
5 files changed, 7 insertions, 10 deletions
diff --git a/drivers/cdrom/aztcd.c b/drivers/cdrom/aztcd.c
index 43bf1e5dc38a..ce4a1ce59d6a 100644
--- a/drivers/cdrom/aztcd.c
+++ b/drivers/cdrom/aztcd.c
@@ -297,7 +297,7 @@ static char azt_auto_eject = AZT_AUTO_EJECT;
297 297
298static int AztTimeout, AztTries; 298static int AztTimeout, AztTries;
299static DECLARE_WAIT_QUEUE_HEAD(azt_waitq); 299static DECLARE_WAIT_QUEUE_HEAD(azt_waitq);
300static struct timer_list delay_timer = TIMER_INITIALIZER(NULL, 0, 0); 300static DEFINE_TIMER(delay_timer, NULL, 0, 0);
301 301
302static struct azt_DiskInfo DiskInfo; 302static struct azt_DiskInfo DiskInfo;
303static struct azt_Toc Toc[MAX_TRACKS]; 303static struct azt_Toc Toc[MAX_TRACKS];
diff --git a/drivers/cdrom/gscd.c b/drivers/cdrom/gscd.c
index 7eac10e63b23..ad5464ab99bc 100644
--- a/drivers/cdrom/gscd.c
+++ b/drivers/cdrom/gscd.c
@@ -146,7 +146,7 @@ static int AudioStart_f;
146static int AudioEnd_m; 146static int AudioEnd_m;
147static int AudioEnd_f; 147static int AudioEnd_f;
148 148
149static struct timer_list gscd_timer = TIMER_INITIALIZER(NULL, 0, 0); 149static DEFINE_TIMER(gscd_timer, NULL, 0, 0);
150static DEFINE_SPINLOCK(gscd_lock); 150static DEFINE_SPINLOCK(gscd_lock);
151static struct request_queue *gscd_queue; 151static struct request_queue *gscd_queue;
152 152
diff --git a/drivers/cdrom/optcd.c b/drivers/cdrom/optcd.c
index 351a01dd503a..0b0eab4f40fa 100644
--- a/drivers/cdrom/optcd.c
+++ b/drivers/cdrom/optcd.c
@@ -264,7 +264,7 @@ static inline int flag_low(int flag, unsigned long timeout)
264static int sleep_timeout; /* max # of ticks to sleep */ 264static int sleep_timeout; /* max # of ticks to sleep */
265static DECLARE_WAIT_QUEUE_HEAD(waitq); 265static DECLARE_WAIT_QUEUE_HEAD(waitq);
266static void sleep_timer(unsigned long data); 266static void sleep_timer(unsigned long data);
267static struct timer_list delay_timer = TIMER_INITIALIZER(sleep_timer, 0, 0); 267static DEFINE_TIMER(delay_timer, sleep_timer, 0, 0);
268static DEFINE_SPINLOCK(optcd_lock); 268static DEFINE_SPINLOCK(optcd_lock);
269static struct request_queue *opt_queue; 269static struct request_queue *opt_queue;
270 270
diff --git a/drivers/cdrom/sbpcd.c b/drivers/cdrom/sbpcd.c
index 452d34675159..30a897755361 100644
--- a/drivers/cdrom/sbpcd.c
+++ b/drivers/cdrom/sbpcd.c
@@ -742,13 +742,10 @@ static struct sbpcd_drive *current_drive = D_S;
742unsigned long cli_sti; /* for saving the processor flags */ 742unsigned long cli_sti; /* for saving the processor flags */
743#endif 743#endif
744/*==========================================================================*/ 744/*==========================================================================*/
745static struct timer_list delay_timer = 745static DEFINE_TIMER(delay_timer, mark_timeout_delay, 0, 0);
746 TIMER_INITIALIZER(mark_timeout_delay, 0, 0); 746static DEFINE_TIMER(data_timer, mark_timeout_data, 0, 0);
747static struct timer_list data_timer =
748 TIMER_INITIALIZER(mark_timeout_data, 0, 0);
749#if 0 747#if 0
750static struct timer_list audio_timer = 748static DEFINE_TIMER(audio_timer, mark_timeout_audio, 0, 0);
751 TIMER_INITIALIZER(mark_timeout_audio, 0, 0);
752#endif 749#endif
753/*==========================================================================*/ 750/*==========================================================================*/
754/* 751/*
diff --git a/drivers/cdrom/sjcd.c b/drivers/cdrom/sjcd.c
index 4e7a342ec36f..74b1cadbf161 100644
--- a/drivers/cdrom/sjcd.c
+++ b/drivers/cdrom/sjcd.c
@@ -151,7 +151,7 @@ static struct sjcd_stat statistic;
151/* 151/*
152 * Timer. 152 * Timer.
153 */ 153 */
154static struct timer_list sjcd_delay_timer = TIMER_INITIALIZER(NULL, 0, 0); 154static DEFINE_TIMER(sjcd_delay_timer, NULL, 0, 0);
155 155
156#define SJCD_SET_TIMER( func, tmout ) \ 156#define SJCD_SET_TIMER( func, tmout ) \
157 ( sjcd_delay_timer.expires = jiffies+tmout, \ 157 ( sjcd_delay_timer.expires = jiffies+tmout, \