[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <YMCP1wJ6+e2E1n4m@mwanda>
Date: Wed, 9 Jun 2021 12:54:31 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Jiri Pirko <jiri@...dia.com>, Dmytro Linkin <dlinkin@...dia.com>
Cc: "David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Vlad Buslov <vladbu@...dia.com>, netdev@...r.kernel.org,
kernel-janitors@...r.kernel.org
Subject: [PATCH net-next] devlink: Fix error message in
devlink_rate_set_ops_supported()
The WARN_ON() macro takes a condition, it doesn't take a message. Use
WARN() instead.
Fixes: 1897db2ec310 ("devlink: Allow setting tx rate for devlink rate leaf objects")
Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
---
net/core/devlink.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/core/devlink.c b/net/core/devlink.c
index 1e953b77a77a..4a5b333c05a0 100644
--- a/net/core/devlink.c
+++ b/net/core/devlink.c
@@ -1732,7 +1732,7 @@ static bool devlink_rate_set_ops_supported(const struct devlink_ops *ops,
return false;
}
} else {
- WARN_ON("Unknown type of rate object");
+ WARN(1, "Unknown type of rate object");
return false;
}
--
2.30.2
Powered by blists - more mailing lists