Skip to content

Commit

Permalink
atm: lanai: Remove in_interrupt() usage
Browse files Browse the repository at this point in the history
lanai_shutdown_tx_vci() uses in_interrupt() to issue a warning message
if the function was used in context in which it is not safe to sleep.

The usage of in_interrupt() in driver code is deprecated as it can not always
detect all states where it is not allowed to sleep.

msleep() has debug code which will trigger a warning if used in bad
context.

Remove in_interrupt().

Cc: Chas Williams <3chas3@gmail.com>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  • Loading branch information
Sebastian Andrzej Siewior authored and Jakub Kicinski committed Nov 19, 2020
1 parent f2bcc2f commit 2de680d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/atm/lanai.c
Original file line number Diff line number Diff line change
Expand Up @@ -765,8 +765,7 @@ static void lanai_shutdown_tx_vci(struct lanai_dev *lanai,
struct sk_buff *skb;
unsigned long flags, timeout;
int read, write, lastread = -1;
APRINTK(!in_interrupt(),
"lanai_shutdown_tx_vci called w/o process context!\n");

if (lvcc->vbase == NULL) /* We were never bound to a VCI */
return;
/* 15.2.1 - wait for queue to drain */
Expand Down

0 comments on commit 2de680d

Please sign in to comment.