From: Weston Andros Adamson Date: Tue, 23 Oct 2012 14:43:35 +0000 (-0400) Subject: SUNRPC: remove BUG_ON from bc_send X-Git-Tag: firefly_0821_release~3680^2~1413^2~79 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4c9c52e479f493ccfc3f513e870912115b49058f;p=firefly-linux-kernel-4.4.55.git SUNRPC: remove BUG_ON from bc_send Replace BUG_ON() with WARN_ON_ONCE(). The error condition is a simple ref counting sanity check and the following code will not free anything until final put. Signed-off-by: Weston Andros Adamson Signed-off-by: Trond Myklebust --- diff --git a/net/sunrpc/bc_svc.c b/net/sunrpc/bc_svc.c index 0b2eb388cbda..15c7a8a1c24f 100644 --- a/net/sunrpc/bc_svc.c +++ b/net/sunrpc/bc_svc.c @@ -53,7 +53,7 @@ int bc_send(struct rpc_rqst *req) if (IS_ERR(task)) ret = PTR_ERR(task); else { - BUG_ON(atomic_read(&task->tk_count) != 1); + WARN_ON_ONCE(atomic_read(&task->tk_count) != 1); ret = task->tk_status; rpc_put_task(task); }