Commit f5fc6e85 authored by Sebastian Andrzej Siewior's avatar Sebastian Andrzej Siewior Committed by David S. Miller

net: ionic: Remove WARN_ON(in_interrupt()).

in_interrupt() is ill defined and does not provide what the name
suggests. The usage especially in driver code is deprecated and a tree wide
effort to clean up and consolidate the (ab)usage of in_interrupt() and
related checks is happening.

In this case the check covers only parts of the contexts in which these
functions cannot be called. It fails to detect preemption or interrupt
disabled invocations.

As the functions which are invoked from ionic_adminq_post() and
ionic_dev_cmd_wait() contain a broad variety of checks (always enabled or
debug option dependent) which cover all invalid conditions already, there
is no point in having inconsistent warnings in those drivers.

Just remove them.
Signed-off-by: default avatarSebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Acked-by: default avatarShannon Nelson <snelson@pensando.io>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1800eee1
...@@ -255,8 +255,6 @@ static int ionic_adminq_post(struct ionic_lif *lif, struct ionic_admin_ctx *ctx) ...@@ -255,8 +255,6 @@ static int ionic_adminq_post(struct ionic_lif *lif, struct ionic_admin_ctx *ctx)
struct ionic_queue *q; struct ionic_queue *q;
int err = 0; int err = 0;
WARN_ON(in_interrupt());
if (!lif->adminqcq) if (!lif->adminqcq)
return -EIO; return -EIO;
...@@ -328,8 +326,6 @@ int ionic_dev_cmd_wait(struct ionic *ionic, unsigned long max_seconds) ...@@ -328,8 +326,6 @@ int ionic_dev_cmd_wait(struct ionic *ionic, unsigned long max_seconds)
int done; int done;
int err; int err;
WARN_ON(in_interrupt());
/* Wait for dev cmd to complete, retrying if we get EAGAIN, /* Wait for dev cmd to complete, retrying if we get EAGAIN,
* but don't wait any longer than max_seconds. * but don't wait any longer than max_seconds.
*/ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment