mISDN: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to all timer callbacks, switch to using the new timer_setup() and from_timer() to pass the timer pointer explicitly. Cc: Karsten Keil <isdn@linux-pingi.de> Cc: Geliang Tang <geliangtang@gmail.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Masahiro Yamada <yamada.masahiro@socionext.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Anton Vasilyev <vasilyev@ispras.ru> Cc: Ingo Molnar <mingo@kernel.org> Cc: netdev@vger.kernel.org Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
d99356797a
commit
e313ac12eb
@@ -457,9 +457,9 @@ dsp_tone_hw_message(struct dsp *dsp, u8 *sample, int len)
|
||||
* timer expires *
|
||||
*****************/
|
||||
void
|
||||
dsp_tone_timeout(void *arg)
|
||||
dsp_tone_timeout(struct timer_list *t)
|
||||
{
|
||||
struct dsp *dsp = arg;
|
||||
struct dsp *dsp = from_timer(dsp, t, tone.tl);
|
||||
struct dsp_tone *tone = &dsp->tone;
|
||||
struct pattern *pat = (struct pattern *)tone->pattern;
|
||||
int index = tone->index;
|
||||
@@ -478,7 +478,6 @@ dsp_tone_timeout(void *arg)
|
||||
else
|
||||
dsp_tone_hw_message(dsp, pat->data[index], *(pat->siz[index]));
|
||||
/* set timer */
|
||||
init_timer(&tone->tl);
|
||||
tone->tl.expires = jiffies + (pat->seq[index] * HZ) / 8000;
|
||||
add_timer(&tone->tl);
|
||||
}
|
||||
@@ -541,7 +540,6 @@ dsp_tone(struct dsp *dsp, int tone)
|
||||
/* set timer */
|
||||
if (timer_pending(&tonet->tl))
|
||||
del_timer(&tonet->tl);
|
||||
init_timer(&tonet->tl);
|
||||
tonet->tl.expires = jiffies + (pat->seq[0] * HZ) / 8000;
|
||||
add_timer(&tonet->tl);
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user